can't untar a complete directory using tar -cvpzf
Solution 1
Your tar can't find gzip. If you don't have gzip, you can't make a .gz file. You should look for a gzip executable on your system. What kind of system is it?
In the meantime, you could leave off the "z" and just transfer a .tar file. It will be bigger, but at least you'll be able to move your data to the other server.
Solution 2
Install gzip, for example ubuntu-
apt-get install gzip
Then untar it -
tar -xzf file.tar.gz
Solution 3
Gzip was not installed on this server (VPS). I should have check this part first instead of relying on assumption.
Lessons learn
Solution 4
install bzip2 and then it should be working. for example in debian/ubuntu
sudo apt-get install bzip2
or in gentoo
emerge bzip2
Bernard Sfez
Project Manager oriented IT and websolution. Website construction, Tiki Wiki specialist CMS/CRM/ERP at Shocksite. Working mainly as external consultant and CTO for dynamic startup projects.
Updated on June 14, 2022Comments
-
Bernard Sfez almost 2 years
Banging my head on this one...
I used
tar -cvpzf file.tar.gz
to compress a complete directory.I move the file to another server and i try to decompress the directory where i have copied the archive. Can't make it work.
bash-3.2$ tar -xvpzf news.tar.gz . tar: gzip: Cannot exec: No such file or directory tar: Error is not recoverable: exiting now tar: Child returned status 2 tar: .: Not found in archive tar: Error exit delayed from previous errors
Anyone ?