What is the fastest way to backup and restore website files and its mysql database?

MooseLucifer

Well-known member
Registered
Joined
May 20, 2016
Messages
149
Points
28
I am using cpanel server, I am looking for a way to backup and restore websites including its files and databases only. Website are running on wordpress platform, I don't expect to use a plugin, i like using ways to work on hosting directly to backup files and mysql database in a fastest and easiest way. Can you guys suggest me some?
 

Fusion Arc Hosting

Well-known member
Hosting Provider
Registered
Joined
Oct 25, 2017
Messages
136
Points
18
Hi MooseLucifer,

Thank you so much for your question!

I have done migrations myself and would be happy to explain how this can be done.

WARNING: Make sure you keep a full backup on your local computer while doing migrations. Also keep the remote server and or account active until you know all files have been transferred successfully. This is to make sure the data is not lost.
* Best to be done while having root access to a server.

How to backup all content within a cPanel account:

This includes backup of (All files, pictures, databases, and more)

Step 1: Log into your cPanel account in question. Locate "Backup" click on it.
click-on-backup.PNG

Step 2: Click on the blue button "Download a Full Account Backup"
click-on-download-full-backup.PNG

Step 3: Generate a backup.
NOTICE: Depending on the size of your website and its contents this may take a while. However you will get a notification via email of when it is complete.
generate-backup.PNG

Step 4: When the backup is complete within the same "Backups" page you will now see a new backup under "Backups Available for download" as shown above.
Step 5: Download that and you have successfully made a full backup of your cPanel and its contents.

=================================================================================================

How to restore all content within a cPanel account using a full cPanel backup via Command Line:

Step 1:
If you do not have root access provide your web hosting provider the backup file as they need to restore it for you. However if you do have full root access to your server example (VPS or Dedicated Server) log into your server as root.
Step 2: Upload the file to your server via FTP under /home.
Step 3: Within the command line under /home you can take a full account backup using the script: /scripts/restorepkg filename . The filename will be the name from your backup usually the cPanel log in username.
restore-cpanel-command-line.PNG

Step 4: Run this command an you will get an output from the server within the command line giving you an update on the status of the restoration.

Congratulations the restore is complete go back to cpanel on the new server and check the cPanel for any missing files and data. Let us know of any questions we are happy to help.

Thanks!

Mario Cano

Linux Systems Administrator
 

Attachments

Last edited by a moderator:

Fusion Arc Hosting

Well-known member
Hosting Provider
Registered
Joined
Oct 25, 2017
Messages
136
Points
18
Hello again,

I also wanted to add a few other ways of making backups and restoring. Please see below:

How to Download Backup of Home Directory, MySQL or E-mail Only?
1. Log into your cPanel account.
2. In the "Files" section, click on "Backup Wizard" Icon.

3. Under "Backup or Restore" text, click on the "Backup" button.

4. In the 2nd step "Full or Partial Backup" option, under "Select Partial Backup", you need to click on "Home Directory" to download home directory only or should you wish to download only "MySQL Databases", click on "MySQL Database".


5. Now click on the "Download" link/button.

==================================================================

How to Restore cPanel Backup non root?

1. Log into your cPanel account.
2. In the "Files" section, click on "Backup Wizard" Icon.


3. Under "Backup/Restore" text, click on the "Restore" button.



4. Under "Select Restore Type", choose the appropriate option.


5. Click on "Browse", select your backup file from your PC, and click on the "Upload" button.


===============================================================

How to generate a cPanel backup and sent to FTP Server?

1. Log into your cPanel account.
2. In the "Files" section, click on "Backup" Icon.


3. Under "Full Backup", Click on "Download a Full Website Backup" button.


4. From Dropdown menu, Select Backup destination to "Remote FTP Server", In Email field enter your email address.

Remote Server:
FTP IP address or FTP domain name like ftp.example.com,
Remote User: Your FTP Username
Remote Password: Your FTP Password
Port: 21 or other FTP Port
Remote Dir: Remote Directory like /home/username/backupfolder/


5. Once you fill in the Remote FTP details, click on the "Generate Backup" button.



============================================================


Thanks!

Mario Cano

Linux Systems Administrator
 
Last edited by a moderator:

Mjlivera

Member
Registered
Joined
May 12, 2013
Messages
31
Points
6
@Fusion Arc Hosting I also like this feature in cpanel but how long does it take time to backup successfully a website or emails? does it allow to run under background? and notice when its done?
 

Fusion Arc Hosting

Well-known member
Hosting Provider
Registered
Joined
Oct 25, 2017
Messages
136
Points
18
Fusion Arc Hosting
Hi Mjlivera,

Hope you are doing great!

I wanted to check in with you to see if you still have any questions regarding the backups system and running in the background? I would be happy to help.

Thanks!

Mario Cano | Fusion Arc Hosting

Linux Systems Administrator
 

Fusion Arc Hosting

Well-known member
Hosting Provider
Registered
Joined
Oct 25, 2017
Messages
136
Points
18
@Fusion Arc Hosting I also like this feature in cpanel but how long does it take time to backup successfully a website or emails? does it allow to run under background? and notice when its done?
Hello Mjlivera,

Thank you for your question! Happy to answer that for you.

I also like this feature in cpanel but how long does it take time to backup successfully a website or emails? does it allow to run under background? and notice when its done?
Excellent question. So the time it take for cPanel itself to create a backup depends largely on your cPanel total disk usage and even more on the servers I/O read and write performance. To put it in perspective when I created a backup today for a 20+GB disk usage cPanel it took the server roughly 30 minutes to 1 hour. However we are using SSD based servers which does drastically improve I/O speed.

Commonly for shared web hosting during our migrations I see an average of 5-28 minutes. Again depends on the disk size of the transfer and the remote server hardware and network uplink speeds.

As for running in the background. Yes the backup solution in cPanel will continue to run in the background until completed. In the full backup option you can even specify an email for the system to alert you of when the backup has fully completed.

I hope I was able to adequatly answer your questions. If not please let me know of any further questions at all I am happy to answer them :).

Thanks!

Mario Cano

Linux Systems Administrator
 

fiz

Well-known member
Hosting Provider
Registered
Joined
Aug 6, 2020
Messages
116
Points
16
I am using cpanel server, I am looking for a way to backup and restore websites including its files and databases only. Website are running on wordpress platform, I don't expect to use a plugin, i like using ways to work on hosting directly to backup files and mysql database in a fastest and easiest way. Can you guys suggest me some?
There are too many ways to backup and restore only files and database of a Wordpress site:
1. Softaculous: Backup/Restore Feature (Only if you have it)
2. cPanel Backup: (Home directory and Database separately) You can take a Full backup but will contain everything in that cPanel account
3. WHM: Backup/Restore New bulds of WHM now provides the option to choose what to restore and backup.
4. SSH: tar the desired folder and take a MySQL dump
5. SSH: /scripts/pkgacct <cpanel-user>

Do not hesitate to reach me out in case you have any questions.
 

MooseLucifer

Well-known member
Registered
Joined
May 20, 2016
Messages
149
Points
28
MooseLucifer
2. cPanel Backup: (Home directory and Database separately) You can take a Full backup but will contain everything in that cPanel account
This sometime makes my server full disk, I can target backup file to another hosting?
 

fiz

Well-known member
Hosting Provider
Registered
Joined
Aug 6, 2020
Messages
116
Points
16
fiz
You can have remote location but it will first creat a backup locally and then transfer it. Any ftp account will work that has required space.
 

fiz

Well-known member
Hosting Provider
Registered
Joined
Aug 6, 2020
Messages
116
Points
16
fiz
You can try using rsync if you have root access and have backup server. We always use this approach to sync data to backup server to keep the primary server's space always available to applications and websites.

Let me know if you need any help.
 

etechsupport

Well-known member
Registered
Joined
Jun 25, 2020
Messages
118
Points
16
Restore home directory backup in cPanel
  1. Login to your cPanel.
  2. Under the files section, click on Backup.
  3. Click on Choose File.
  4. The name of your backup should now be displayed, so click on Upload.
  5. You should then see the progress of your files being restored.
 
Latest Threads
Replies
0
Views
130
Replies
0
Views
66
Replies
0
Views
60
Replies
1
Views
89
Recommended Threads
Replies
6
Views
6,805
Replies
5
Views
3,646

Latest postsNew threads

Latest Hosting OffersNew Reviews

Sponsors

Tag Cloud

You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an alternative browser.

Top