Backup and Restore for big joomla databases PDF Print E-mail
Written by Administrator   
Thursday, 30 July 2009 13:55
Here is a simple way to backup your joomla website databases using Telnet/SSH. Why using telnet? You can backup large  joomladatabases using telnet which is not possible from Phpmyadmin interface where memory is an issue.

BACKING UP MYSQL DATABASE USING TELNET

STEP 1:

FTP into your web site where you want to backup the database. Create a folder named ‘backup’ (or any name you want) in your public_html directory. Chmod it to 777. (Note: If your server API is CGI, you will get ‘Internal server error’ with 777. So if this is your case, chmod it back to 755.)

STEP 2:

Telnet into your web site using Putty.

STEP 3:

At the command prompt type the backup query like this - (single line)

mysqldump -u mysite_User -ptest123 mysite_database 
> /home/path/to/backup_folder_name/backup.sql

Press ENTER.

  • Website - mywebsite.com
  • Database name - user_database
  • Database Username - user_User
  • Password - test123

If everything is OK, you will go to the command prompt again. Check your ‘backup’ folder. You will see backup.sql file.

Note: There is no space between -p and your password.

Tip: Copy the above command on a notepad and modify it with your details. Then copy and paste at command prompt.

STEP 4:

Download it to your computer in ASCII mode of your ftp software. (Not in AUTO mode.)

 

RESTORING YOUR DATABASE

You need to restore the data into the database if you lost your data or if your database is corrupted.

STEP 1:

Create a folder ‘restore’ (or whatever you like) on your site. Upload the ‘backup.sql’ that is saved on your computer to this folder in ASCII mode.

STEP 2:

Login into your web host panel and go to Phpmyadmin. Select the database into which you want the data restored to. Delete ALL Tables. Remember, you need to restore data into the SAME database. So your database should be empty with no tables and no data.

STEP 3:

Now telnet into your web site as you did during database backup process above.

Run this command at command prompt - (single line)

mysql -u mysite_User -ptest123 mysite_database 
< /home/path/to/restore_folder_name/backup.sql

Press ENTER.

  • Website - mysite.com
  • Database name - mysite_database
  • Database Username - mysite_User
  • Password - test123

If everything is OK, you will go to the command prompt again. Check your phpmyadmin interface. All data will be restored into the database again.

Note: There is no space between -p and your password.

Tip: Copy the above command on a notepad and modify it with your details. Then copy and paste at command prompt..

Do a test practice on a test database first. Create a test database and import some data and try following above instructions

resourse : Joomlapanel.com



Administrator Written on Thursday, 30 July 2009 13:55 by Administrator

Viewed 1502 times so far.

Rate this article

(0 votes)


Newer news items:
Older news items:

Comments (1)Add Comment
0
...
written by Joomla Template, August 05, 2009
Nice tips, i'll try this on my joomla templateproject.. thanks

Write comment

security code
Write the displayed characters


busy
Last Updated on Thursday, 30 July 2009 13:56
 

Extensions

Tools
+Backup
+Mini tools

+
Advertise
+
SEO &SEF

Media
+
Gallery
+
Video
Styles
+Tab & Slide
+Sharing
+
Tags Cloud
+Visitors
Shop
+
Update
+Update

Articles
+Blogger
+News
+Comments
+Auto post
Social
+
Forums
+ShoutBox

Special
+
Holidays
+Editors

+Files

Manage
+
Download
+Update

+Update

Most downloads in 10 days

calendar.gifAug.01

Today Joomlapanel are pleased to announce the release of  Free JP Dreamland Template, the 5th Te...

calendar.gifMay.20

a free Joomla template for travel

calendar.gifMay.20

A nice templates for Joomla 1.5

calendar.gifMar.16

MyPortfolio Joomla 1.5 template is very first template I ever made for Joomla Community when Port...

calendar.gifApr.06

Free Joomla templates from Templatemonster. It's nice

Extensions stats

The download archive contains currently 139 downloads in 24 categories. To date, these have been downloaded 45267 times.

Blog Tips

Blog News
SEO Tips

Online

We have 50 guests online

Newest Files

calendar.gifMar.01

Latest Free Template From Joomvision

calendar.gifMar.01

Today Joomvision are pleased to announce the release of Free JV 9BodyTemplate

calendar.gifSep.11

The Fastest Joomla! Admin Template AdminPraise Lite is a super lightweight Joomla! administrator ...

calendar.gifAug.15

Hi! JoomPlaza members,today, I received anouncement from Rockettheme. A new free Joomla template ...

calendar.gifAug.01

Today Joomlapanel are pleased to announce the release of  Free JP Dreamland Template, the 5th Te...

SocialTwist Tell-a-Friend