Jump to content
xisto Community
Shadow X

Backing Up MySQL?

Recommended Posts

Do you have cPanel for your webhost? If you are using Xisto, you have cPanel. It would probably be easier and faster if you just went into the Backups section and download the database file there.But if you still want to use phpMyAdmin for this, then go into phpMyAdmin and click on the Export link on the right window. Then select the database(s) you want to export and press the Go button at the bottom. If you want the database compressed (zipped or gzipped) you may select those options before hitting Go. That should start the download.

Share this post


Link to post
Share on other sites

I expect it to do the export on the host where your database is. The export will tell you the name of the exported file. Then you probably will have to use ftp to get the file on your pc, if you want to put it on a CD-rom in order to protect it from a general failure.I did not do that part personnally yet, but I expect it do work that way.By the way, performing the backup is not at all a risky operation, you can test it without problem. Only restoring a bad backup could be risky.Regards Yordan

Share this post


Link to post
Share on other sites

Try this

I can back up my database using this command:

Mysqldump -u [username] -p [password] [db_name] > [backupfile.sql] on linux of course

1064326077[/snapback]

of course, you can do this only on your home linux system. You can't to that on Xisto because you don't have directly access to linux with root permissions.

Share this post


Link to post
Share on other sites

Not really - first on all, this command isn't restricted to Linux ONLY. mysqldump is available for Windows MySQL too and the usage syntax is the exact same as that of it's Linux counterpart.

 

Secondly - you don't need root access to carry this out. As long as you have SHELL access to your Xisto account (obtainable through separate request alongwith the reasons why you need it), you can back up your own databases using this command without a hitch. :)

 

As far as I know there's a slight mistake in the syntax stated here. You either add the suffix --all-databases to the command or specify individual databases using --databases suffix. Also the command doesn't start with a capitalized "M" (not that it would matter on windows, but on Linux, it surely will) An ideal command would be:

CONSOLE

shell> mysqldump -u YourUsername -pYourPassword --all-databases > myfile.sql

 

OR

 

shell> mysqldump -u YourUsername -pYourPassword --databases mydb1 mydb2 > myfile.sql

 

 

NOTE: There's a SPACE between the option -u] and YourUsername but NONE between -p and YourPassword.

 

In case you seek to back up ONLY YOUR TABLE STRUCTURE AND NOT THE DATA,

CONSOLE

shell> mysqldump -u YourUsername -pYourPassword --no-data --databases mydb1 mydb2 > myfile.sql

 

Hope thid helps :)

Regards,

m^e

Share this post


Link to post
Share on other sites

SHELL access to your Xisto account (obtainable through separate request alongwith the reasons why you need it)

Do you think that "I want to backup my databases usign shell commands" is an accreptable reason for asking for shell access to Xisto ?Yordan

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.