How to restore an oversized backup

If you have a backup file that is too large for the DirectAdmin restore process to handle, then the tar.gz can be adjusted to remove some components so that the restore can be done normally, and those removed components would be restored manually after.

The way we'll do that is to remove the domains directory from the backup file (on the assumption that this directory is cause of the large usage).

cd /home/admin/admin_backups
mv user.admin.username.tar.gz user.admin.username.backup.tar.gz
mkdir temp
cd temp
tar xvzf ../user.admin.username.backup.tar.gz backup
tar cvzf ../user.admin.username.tar.gz backup
chown admin:admin ../user.admin.username.tar.gz

This will remove the domains directory from the backup.
If you get an error during the extraction of "backup", then either the file is corrupted or too large for the OS it's on to handle.

Restore the file normally in DA.
Once finished, the data from /home/username/domains will be missing, so now extract that manually:

cd /home/username
tar xvzf /home/admin/admin_backups/user.admin.username.backup.tar.gz domains
chown username:username domains


Double check that everything is functioning correctly, and you should be done.


Was this article helpful?

mood_bad Dislike 2
mood Like 0
visibility Views: 11495