|
|
Sometimes a MySQL database is simply too large to backup on a web based interface. In the event of this occurring, it is fairly easy to backup a database via SSH; all it takes is one command. This tutorial will show you how.
First of all, login to SSH either as root or elevate yourself to root status.
mysqldump -u user -p password -h host dbname > outputfile
The terms highlighted in bold need to be filled out by you. A brief overview of what they are:
- user: The user that has access to the database you want to backup
- password: The password of that user
- host: Your database host; usually setting this to localhost works fine
- dbname: The name of the database you want to backup
- outputfile: The name of the file you want to backup the database to.
Here is an example:
mysqldump -u john -p johnpass -h localhost john_db > /home/john/backup.sql
This will backup the database john_db to /home/john/backup.sql. Keep in mind for very large files, this will take some time, so be patient. Once it is finished, you will be returned to the command line.
For more information regarding mysqldump and for tips about advanced usage, take a look at this article:
dev.mysql.com/doc/refman/5.0/en/mysqldump.html
- Articles In This Category
- More from this CategoryTutorials > LinuxThis tutorial will give you an introduction to the free open source Linux tool, Screen....Tutorials > LinuxOne of the most important tasks a system administrator should undertake is keeping the server up to date. Updates are frequently released for Linux, i...Tutorials > LinuxSometimes you will have a database backup that is too big to restore over a web interface. The best way to restore large SQL backups is through SSH, a...Tutorials > LinuxThis is a collection of useful tools and websites which can help you maintain your server, and optimise it for specific scenarios....Tutorials > LinuxThe following is a list of UNIX commands that you might find helpful when modifying your web sites on the server. Most UNIX commands have many option...
- Related Articles
- Related ArticlesPlesk Tutorials > Plesk 10 - TutorialsThe following video tutorial will guide you through creating a database in Plesk10...Plesk Tutorials > Plesk 10 - TutorialsThe following video tutorial will guide you through managing your Databases with WebAdmin in Plesk10...cPanel-WHM > cPanel Sever ManagementTo change the SSH port number login as root, and edit /etc/ssh/sshd_config Find the line that says Port 22 and change 22 to any number between 1024-&...Plesk Tutorials > Windows Plesk ASP.NET tutorialsWindows Plesk ASP.NET - Backing Up Your MSSQL Database Using MyLittleAdmin There are two methods of MSSQL database backups offered on our Windows Pl...Virtual Server Tutorials > VPS Hosting TutorialsThis is a video on how to connect to your VPS using SSH....
- Latest Articles
- Latest ArticlesTutorials > Domain NamesWhat are glue records? If the nameserver (NS) is a subdomain of the domain you want to configure, e.g. you want to set ns1.yourdomain.com and ns2.y...Tutorials > Email Tutorial : FAQ for Email setupThis guide will help you configure your AUSWEB hosted email address with Outlook 2010....Tutorials > Email Tutorial : FAQ for Email setupThis guide will help you setup and configure your AUSWEB hosted email address with Windows Live Mail (Outlook 2011)....Tutorials > Partner (Affiliate) Guide1. Visit http://partner.ausweb.com.au and click “Join Now” from the top navigation bar (or click the shiny green “Sign Up Now” button....Tutorials > Website Security/Upgrade IssuesAfter installing an SSL, a commmon subsequent issue (in most modern browsers) is the the dreaded "Connection Partially Encrypted" warning. The er...
- Most Read Articles
- Most Read ArticlesTutorials > Joomla FAQA vulnerable extension is one that has been found to contain, or contribute to, a security vulnerability. Vulnerable extensions are not necessarily p...Bad karma: we can't find that page! You asked for {%sh404SEF_404_URL%}, but despite our computers looking very hard, we could not find it. What happe...Tutorials > phpBB Forum HostingFinally, after a long wait, phpBB3 has been released, and its relatively easy to upgrade your existing phpBB installation. phpBB3 introduces hundreds...Tutorials > phpBB Forum HostingThis video tutorial will show you how to create a new topic in phpBB3....Tutorials > Email Tutorial : FAQ for Email setupConfiguring your new iPhone or iPad to receive mail from your Ausweb hosted email accounts is a very easy process. This tutorial will give you a si...
| < Prev |
|---|

