Quantcast
Channel: Backup and restore
Viewing all articles
Browse latest Browse all 6664

msqldump from commandline

$
0
0

by Bente Olsen.  

I hope someone can help me with a useful command to do a mysqldump.

I have tried the method described in moodle docs:

mysqldump -h example.com -u myusername --password=mypassword -C -Q -e --create-options mydatabasename > moodle-database.sql

it returns

mysqldump: unknown option '--'

Then I tried the method mentioned here:

mysqldump -u root -p (pw) moodledb > moodleSQL.sql

which returns

mysqldump: Got error: 1044: Access denied for user 'moodleuser'@'localhost' to database '(pw)' when selecting the database
mysqldump -u root -p moodledb > moodleSQL.sql

returns

mysqldump: Got error: 1044: Access denied for user 'moodleuser'@'localhost' to database 'moodle' when using LOCK TABLES

 

Thanks in advance

 


Viewing all articles
Browse latest Browse all 6664

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>