cannot restore backups during server migration

Hi all, Have been following the server migration instructions at http://www.virtualmin.com/documentation/system/migrate - however when I reach the point of restoring the bz2 backups I get the following output (from both console and web gui)

Starting restore.. Extracting backup archive files .. .. extraction of /root/backups//xxxxxxxxxx.com.tar.bz2 failed : sh: 1: -d: not found /bin/tar: This does not look like a tar archive /bin/tar: Exiting with failure status due to previous errors

This is going from an ubuntu 12.04 server to a fresh install of ubuntu 12.04 - any other details desired let me know :)

Status: 
Closed (fixed)

Comments

Are you able to extract that archive manually from the command line?

For example, if you run the command "tar tjvf /root/backups//xxxxxxxxxx.com.tar.bz2", do you see a list of all the files, and no errors?

Also, you may want to verify that bzip2 is installed on your system, which you can do with the command "apt-get install bzip2".

Hey Andreychek,

Yes bzip2 is definitely installed, and extracting manually works fine (tar -xvjf )

The errror seems to relate specifically to the -d flag.

I've also tried with a number of other backups (the restore is running against 63 backups) however they all return with the same failure

After digging through the backups-lib.pl file, the only reference to -d I could find alongside bzip commands was for the check against pbzip2 vs bzip2 - after this I installed parrallel bzip (pbzip2) and the files are now extracting correctly - still seems a bug but may have been an issue with my config as well

I had a look at this, and the underlying problem is that Virtualmin expected to find pbzip2 but it wasn't installed. However, the error message in this case wasn't very useful - I will fix that in the next release.

Automatically closed -- issue fixed for 2 weeks with no activity.