views:

2381

answers:

2
+1  Q: 

Backup MySQL users

How do I backup MySQL users and their privileges?

Anything like mysqldump?

I am looking for something like mysqldump -d -u root -p MyTable > Schema.sql

+2  A: 

So far my experience with MySQL i didn't see anything to backup user and their privileges through a command line.

But i can backup those critical data by backing up mysql

mysqldump -u root -p mysql > mysql.sql
simplyharsh
A: 

The users and privileges are stored in the databased named 'mysql'. You can use mysqldump to backup the tables in the databased named 'mysql'.

Zoredache