How to restore cPanel backup using ssh
cPanel allows you to backup accounts so you can move them between servers. We’ve covered how to backup a cPanel account using ssh so now we’re going to look at how you restore an account using ssh. Usually, you would use the WHM interface and “restore a full backup” link on the left-hand side but sometimes this isn’t the best way to restore a site. As a default, if you place a backup into any of the following folders on a cPanel server the interface will find the backup and add it as an option to restore.
Issue the below command swapping the required fields for the characteristics of the backup. In our example, the backup is called cpmove-first2host.tar.gz and we’re not using any of the arguments available. If you wanted to force the backup to deploy you would add –force to the end of the example below.
/scripts/restorepkg cpmove-first2host.tar.gz --$parameter
File formats and backup locations
The filename of the backup must use one of the following formats:
The restore package script searches for the archive in the following locations:
Restore cPanel backup using arguments
The table below lists the arguments that the /scripts/restorepkg script accepts.
Restore backup using the —ip argument
The –ip argument takes one of the following options;
For example, the following command will restore the cpmove-testaccount.tar.gz file to the IP address: 192.168.20.5
/scripts/restorepkg --ip=192.168.20.5 cpmove-testaccount.tar.gz
How was this article?
More from cPanel
How To Install A Cloudflare Origin SSL Certificate In cPanel
Free SSL Certificates from places like cPanel or Let's Encrypt are great. When Let's Encrypt first introduces free SSL Certificates …
Create a SWAP partition on CentOS, RHEL and AlmaLinux without a reboot
SWAP is a memory type that Linux NVMe VPS Servers use to process requests. Memory will be held in SWAP …
Help fixing Error: last request failed: [AUTH] Authentication failed.
The Error: last request failed: [AUTH] Authentication failed error can be caused by a range of things. It could be …