Gentoo Blog

The ultimate Gentoo Blog
  • Home
  • About

MySQL Dump the table structure only no data

Simon | May 27, 2011

The only option that is different than creating an entire backup is the -d switch, which tells mysqldump not to output the data.

mysqldump -u root -pmypassword -d proftpd > /root/proftp.sql

This should leave you with the table structure without the data. To restore the DB do the following:

mysql -u root -pmypassword proftpd < proftpd.sql

For this to work the database proftpd must exist as an empty database.

Share on Facebook
Comments
No Comments »
Categories
mysql
Comments rss Comments rss
Trackback Trackback

 

May 2011
M T W T F S S
« Apr   Jun »
 1
2345678
9101112131415
16171819202122
23242526272829
3031  

Categories

  • confixx/Plesk
  • fun
  • Gentoo
  • iptables
  • mysql
  • news
  • Raid Controllers
  • Stuff
  • Ubuntu/Debian
  • Xen/Vmware

Links

  • Gentoo
  • http.net
  • iphone software linux
  • michael-fuchs.net
  • Ubuntu
  • webupd8.org

Search Blog

rss Comments rss valid xhtml 1.1 design by jide powered by Wordpress get firefox