How to Restore a cPanel Full Backup to a Dedicated Server (WHM & SSH Guide)

Step-by-step tutorial to restore a cPanel full backup (cpmove or tar.gz) to a new dedicated server using WHM or SSH. Includes prerequisites, post-restoration checklist, and troubleshooting tips for smooth website migration.

Introduction

Migrating your website to a more powerful environment is a common step as your business grows. Whether you're moving from shared hosting or another server, restoring a cPanel full backup to a dedicated server ensures all your files, databases, email accounts, and settings transfer reliably.

cPanel and WHM provide user-friendly tools for this process, while experienced administrators often prefer the speed and control of SSH and command-line methods. This comprehensive guide walks you through both approaches, so you can choose the one that best fits your comfort level.

At Leo Servers, we specialize in helping clients complete seamless website migrations to high-performance infrastructure. If you're ready for better speed, resources, and reliability, consider upgrading to a high-performance dedicated server.

What You'll Learn

Prerequisites

Before starting the restoration, ensure you have the following:

πŸ”
Root Access

Root access to the target dedicated server with cPanel & WHM installed.

πŸ“¦
Full Backup File

A full cPanel backup file from the source server (typically named cpmove-username.tar.gz or backup-date_username.tar.gz).

πŸ“‚
File Placement

The backup file transferred to the new server's /home directory (recommended location).

πŸ’Ύ
Disk Space

Sufficient disk space on the target server (at least 1.5–2x the size of the backup to account for extraction).

πŸ–₯️
Basic Knowledge

Basic familiarity with WHM or SSH (we'll cover both).

🌐
Domain Control

Note of your old server's IP address and access to your domain registrar for eventual DNS changes.

Important: Do not manually create the cPanel account on the new server before restoration. The restore process will create it automatically.
Pro Tip: Verify the integrity of your backup file before transfer using md5sum or sha256sum on both source and destination.

Method 1: Restoring via WHM (Graphical Interface)

This method is ideal for users who prefer a visual interface and is the most straightforward for most webmasters.

1. Upload or Place the Backup File

Log in to your new server via WHM (usually https://your-server-ip:2087). Use WHM's File Manager or SSH/SCP to place the full backup (cpmove or .tar.gz) in the /home directory.

2. Access the Restore Interface

In WHM, search for "Transfer or Restore a cPanel Account" or navigate to:
Home β†’ Transfers β†’ Transfer or Restore a cPanel Account.

3. Select Restore Option

Choose Restore from a local cpmove file.
In the Select a File menu, browse or enter the name of your backup file located in /home.

4. Configure Restore Options

  • Check Overwrite if the cPanel user already exists (if applicable).
  • Under A records, select:
    • Replace All Matching A Records (recommended for full migration), or
    • Replace only basic cPanel-provided A records.
  • Review any other available options based on your WHM version.

5. Start the Restoration

Click Restore. Monitor progress in the Account Restore interface. The process can take several minutes to hours depending on the size of your site.

WHM will handle account creation, file restoration, database import, and permission settings automatically.

Method 2: Restoring via SSH (Command Line)

For faster restoration or when managing multiple accounts, the command-line method using the restorepkg script is powerful.

1. Access the Server via SSH

Connect as the root user using your preferred terminal or SSH client.

2. Place the Backup File

Ensure your cpmove-username.tar.gz or full backup .tar.gz file is in the /home directory:

BASH
mv /path/to/your-backup.tar.gz /home/

3. Restore Using the Script

Run one of the following commands:

By username (if the backup follows standard naming):

BASH
/scripts/restorepkg username

By full path to the backup file (more reliable):

BASH
/scripts/restorepkg /home/cpmove-username.tar.gz

Or for a generic backup name:

BASH
/scripts/restorepkg /home/backup-date_username.tar.gz

4. Monitor the Process

The script will output progress in real-time. You can also check logs later in WHM under Transfers β†’ Review Transfers and Restores.

Advanced Option: Add the --force flag if you need to overwrite an existing account:

/scripts/restorepkg --force /home/cpmove-username.tar.gz

This method is efficient on dedicated servers where you have full root access and want minimal overhead.

Post-Restoration Checklist

After the restore completes, verify everything works correctly:

  • Login to cPanel β€” Confirm you can access the restored account.
  • Website Functionality β€” Browse your site and test key pages, forms, and dynamic content.
  • Databases β€” Check phpMyAdmin or MySQL for imported databases and update any hard-coded connections if needed.
  • Email Accounts β€” Test sending and receiving emails.
  • Permissions β€” Ensure files and folders have correct permissions (typically 644 for files, 755 for directories).
  • DNS/IP Updates β€” Update your domain's A record to point to the new server's IP.
  • SSL Certificates β€” Reinstall or reissue SSLs if they don't auto-renew.
  • Cron Jobs & Custom Settings β€” Verify any scheduled tasks or custom configurations.
  • Clear Caches β€” Clear any website, opcode, or CDN caches.

Run a full site audit and monitor error logs (/usr/local/cpanel/logs and your application's logs) for the first 24–48 hours.

Troubleshooting Tips

  • "File not found" or backup not detected β€” Ensure the file is in /home and has not been renamed. Standard names like cpmove-username.tar.gz work best.
  • Permission or ownership errors β€” The restore process usually fixes these, but you can manually correct with:
    BASH
    chown -R username:username /home/username
    chmod -R 755 /home/username/public_html
  • Database connection issues β€” Update wp-config.php or equivalent files with the new database credentials if they differ.
  • Partial restore or stalled process β€” Check disk space and server resources. On dedicated servers, this is rarely an issue, but large sites may need increased PHP/memory limits temporarily.
  • IP-related problems β€” Use the "Replace All Matching A Records" option during WHM restore.
  • Large backup hangs β€” Consider restoring via SSH in a screen or tmux session to prevent disconnection.

If issues persist, review restoration logs in WHM or contact your server provider's support with specific error messages.

Conclusion

Restoring a cPanel full backup to a dedicated server is a reliable way to complete a website migration with minimal downtime. Whether you use the intuitive WHM graphical interface or the efficient SSH command-line approach with restorepkg, following these steps ensures your files, databases, and configurations transfer successfully.

A smooth migration sets the foundation for better performance and scalability. Once restored, enjoy the power and control that comes with dedicated resources.

Need a robust, high-performance dedicated server for your growing website? Explore Leo Servers' offerings and get expert assistance with your migration.

Have questions about this process or need help with a specific step? Feel free to leave a comment below β€” we're here to help webmasters and developers succeed.

Discover Leo Servers Dedicated Server Locations

Leo Servers servers are available around the world, providing diverse options for hosting high-performance environments. Each region offers unique advantages, making it easier to choose a location that best suits your specific hosting needs.