Prerequisites
Before restoring from backup, make sure you have:
- SSH access to your VPS
- A valid backup file
- Root or sudo privileges
⚠️ Restoration will overwrite existing data. Always take a fresh backup before restoring.
Step 1: Locate Your Backup Files
Connect to your VPS:
ssh hxroot@YOUR_SERVER_IP -p 22
List available backups:
ls -la /backup/
Step 2: Restore Website Files
If backup is a .tar.gz archive:
sudo tar -xzf /backup/website_20260428.tar.gz -C /
If backup is a directory (rsync style):
sudo rsync -avz /backup/snapshot_20260428/ /var/www/html/
Step 3: Restore MySQL/MariaDB Database
Stop services to prevent writes:
sudo systemctl stop nginx # or apache2
Restore database:
sudo mysql < /backup/mysql_20260428.sql
Restart services:
sudo systemctl start nginx
Step 4: Restore Specific File or Directory
Extract a single file from .tar.gz:
tar -xzf /backup/website_backup.tar.gz var/www/html/wp-config.php
List contents without extracting:
tar -tzf /backup/website_backup.tar.gz | grep wp-config
Step 5: Verify Restoration
ls -la /var/www/html/
Test website or database connectivity.
Restore Using Hostxpeed Portal (If Available)
Some Hostxpeed plans offer one-click snapshot restore:
- Log in to Hostxpeed Client Area
- Go to My Services → Your VPS
- Look for "Snapshots" or "Backups" section
- Select a snapshot and click Restore
Emergency Restore from OS Reinstall
If your server is severely corrupted, you may need to:
- Request OS reinstall via Hostxpeed portal
- After fresh OS, restore from your latest backup
✅ Server has been restored from backup. Test thoroughly to ensure all data is intact.