About the author

Photo of sanduhrs
sanduhrs

Backup and restore with mysqlhotcopy

Backup
/usr/bin/mysqlhotcopy -u USERNAME -password=PASSWORD DATABSE /PATH/TO/DIRECTORY

Restore
/init.d/mysql stop
cp -R /PATH/TO/DIRECTORY /var/lib/mysql
/init.d/mysql start

NOTE: mysqlhotcopy works with MyIsam tables only!

If you stop the MYSQL server,

If you stop the MYSQL server, that will lead to database down time...that should not be recommended in some cases.

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd> <img>
  • Lines and paragraphs break automatically.
  • You may post code using <code>...</code> (generic) or <?php ... ?> (highlighted PHP) tags.

More information about formatting options

Website powered by lovely Drupal · Microformats · XML Feed · Valid XHTML, CSS · No www.