Installing software from tarball in Ubuntu server part 1
Today, many Linux software are available in binary format like .deb, rpm. With the binary format, we can easily install the software by double clicking on it and Ubuntu will automatically install the software and its dependencies. Or we can easily search, select and install software from repository channel using apt-get.
Sometimes, however, you’ll encounter software in other formats, such as source files that are delivered in the .tar.gz format. These packages have been archived with the tar utility and then compressed with gzip, and so they’re known as tarballs. Extraction will reveal that the tarball contains one of two types of files: source files and binary files. If the tarball contains binary files, it’s normally enough to run the installation program and install them. Just look at the name of the files in the tarball, and you’ll probably
immediately see what you have to run to perform the installation. If the tarball contains source files, you first have to compile them. Before starting to install software by compiling its source files, you need to be aware of something. Although you’ll probably end up with perfectly working software, all of the software that you install in this way is unmanaged. This means that it will not be updated when you update everything else on your server, simply because the software is not in the databases maintained by software management programs such as apt-get.
1. Before starting to compile the source files, you need to make sure that the required compiler is installed on your server. The command dpkg -l | grep gcc would be an
excellent choice to do that. If you don’t see the gcc compiler, use apt-get install gcc to install if before you proceed.
Note: The procedure described here works in many cases, but it doesn’t work all the time for the simple reason that it is all dependent on the person who created the package. I always recommend that you read the readme file that comes with most source files to see if the software installation has any specific instructions or requirements.
2. Once you have downloaded the software you want to install into your home directory, check how the file is compressed. If the file has the .bz2 extension, it has been compressed with the bzip2 utility. To uncompress it, you need the tar command-line switch -j. If the file has the .gz extension, it has been compressed with the gzip utility, and the tar utility needs the -z switch to extract it. For example file is compressed with bzip2, so run the tar -jxvf nmap* command to extract the archive. In this command,
the option x is used to extract the tar archive, the option v does that in a verbose way so that you’ll see what happens, and the option f nmap* specifies that the
name of the file you want to extract is anything that starts with “nmap.” This creates a subdirectory in your current directory in which all source files are installed.
3. From the directory that was created while extracting the tarball, run the ./configure command. This command will verify that everything required to install the selected
software is present on your server. If the utility fails, it is usually because some required software component was not installed. If this is the case, you’ll see an error message
stating what exactly is missing. Read what software component that is, and install it before you proceed. When ./configure runs without errors, continue with the next step.
4. Next, the make utility is available to make the compiling process easier. This utility reads a file with the name Makefile that has to be present in the directory with the source files; based on the instructions in that file, it compiles the software. Depending on the software that you want to install, the compiling process can take a long time. Once it’s finished, though, continue with the next step.
5. You should now have all the program files that you need. But you’re not quite done, because you still have to make sure that these files are copied to the appropriate paths
on your server. To do this, you must run the make install command as root. Type sudo make install and press Enter. This completes the installation of the source files for
your machine, and they’re ready for use.
Source: Beginning Ubuntu Server Administration from novice to professional
Incoming search terms for the article:
- untar selected tarball
- selected tarball
- tarball ubuntu
- untar ubuntu
- ubuntu tarball
- untar in ubuntu server
- untar your selected tarball
- untar your tarball
- ubuntu installing programs from tarball
- ubuntu installing software from source
Related posts:
- Problems Installing Software in Linux I not a Linux expert, I am just a user....
- Install and configure Apache web server in Ubuntu Server Apache is a modular web server, which means that the...
- How to install DeVeDe on Ubuntu from source DeVeDe is a powerful software for Linux to create CD...
- How to install Sodipodi SVG Vector Editor in Ubuntu Sodipodi is a free and open source SVG Vector editor...
- Restore Ubuntu grub after installing Windows 7 Last time, my computer was using dual boot Ubuntu and...
Related posts brought to you by Yet Another Related Posts Plugin.








