What is the difference between a .tar.gz file, a .tar.xz file and a .deb file? Are all of them archives? When I download a software from the Internet, I sometimes get a .deb file, but sometimes I also get a .tar.gz file. Do, I treat the installation of a .tar.gz file differently from that of a .deb. I usually install .deb files using the comman line instruction sudo dpkg -i <filepath.deb>. Do, I do the same with the .tar.gz file or something different?


This is for compiled packages

With most tar.* files, just extarct the file, and look for the files README and INSTALL.

This should work - open terminal and run it - it will extract the file, change terminal to the extracted directory, and then open File Manager nautilus in that directory.

tar -xf /PATH/TO/PACKAGE-NAME.tar.*
nautilus .

The README file usually has some usful information, anf the INSTALL file give the installation instructions. Sometimes those are in the README. You can then run the commands given, if they have a ./ you need to run cd PACKAGE-NAME first.

| improve this answer | |
  • Thank you for your answer. I think, I should be able to manage now. But, since I'm an absolute newbie and just migrated to Ubuntu13.10 from windows, I'm asking a little more, just so that I can follow. I'm guessing tar -xf /PATH/TO/PACKAGE-NAME.tar.* will create a directory by the package name in my system, hence the second line cd PACKAGE-NAME, wherein you want me to change my working directory to the newly created one. But, the next line nautilus, what does that mean? What is nautilus? Please correct me if I'm wrong, I have no idea, I'm just using my intuition here. – ubuntu_noob Jan 18 '14 at 23:10
  • You have the file manager, inwhich you edit files and stuff. That is opened by the command nautilus. Normally that command is run by the launcher file which you click on to open it. The . after that means that nautilus will open in the current directory. Try it and see ;-) – Wilf Jan 18 '14 at 23:13
  • Okay. Thanks a lot, will do that and get back to you :) – ubuntu_noob Jan 18 '14 at 23:15
  • 1
    thank you, nautilus working, I understand it now. Lol. I knew it all along but just didnt know it was called Nautilus. I was reading up about LINUX a few days back and I came across the fact that APT is a packaging tool with the apt-get function which extracts data from .deb and places the right files in the right place so that when I go for apt-get remove <filename>, the system does not leave behind any useless trace of the software. Do I put myself at any risk, if I go for a manual install? Can I use apt-get remove <filename> anyways? – ubuntu_noob Jan 19 '14 at 21:26
  • If you were installing is as a .deb, with dpkg -i, yes you could, you could of also do sudo apt-get purge to remove most of the configuration files and stuff. But, most .tar.* installers don't allow for this, although some do contain uninstall scripts that you can run as well. If you want to remove it afterwards, you can usually work out was was installed in the first place by looking at the installer package - like in this answer here, although be careful when deleting stuff... – Wilf Jan 20 '14 at 9:49

Debian packages, .deb, are only to be used in Debian-like distros like Ubuntu. These include precompiled libraries/binaries and files in an easy to install fashion by dpkg, which is the part of the system that ensures that they get installed correctly.

tar's in any of their compressions most of the time are not binaries but sources files. These archives needs to be decompresed, configured, compiled and installed. Hence you always should treat the tar files differently of deb files.

DEB files are ready to install, while tar may not be.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.