How to install software on linux ubuntu

Linux Ubuntu is a well known operating system linux ubuntu which has gained popularity in the recent years.Install software on linux(ubuntu)has been a hot topic among computer geeks who use various kind of operating systems but due to its rising popularity it has also become quite a hit for those who want to try something new. In this article we will learn how to install software on linux ubuntu.

When I set out to write this, I wanted to give small simple steps on how to install software on a Linux based operating system. One of the first things that came to mind was, “How do I install software on a Linux system?” This is a simple question but can be answered in many ways.

Installing software on Linux is a relatively straightforward process, but it does involve some steps that are not available in a typical Windows installation.

This guide will walk you through the process of installing and running software on Ubuntu Linux. This guide assumes you have already installed Ubuntu and have logged in.

Note: If you are unfamiliar with Linux or the terminal, please read our guide to getting started before continuing with this article.

Step 1 – Update your packages

The first step is to update any packages that need updating before installing new ones. To do this, open up the terminal (Ctrl + Alt + T) and run the following command:

sudo apt-get update

When prompted, enter your password and press [Enter] to continue. You can now move on to installing new software!

Installing software on Linux is not difficult, but it may take some time to find the right tools. You can use a number of different methods to install software on your Linux system.

The simplest method is to use the built-in package manager (apt). You can also use the terminal (command line) to install programs from source code, or you can even download a binary and execute it directly.

The most common method of installing software on Ubuntu is through the apt command line tool. The apt command searches for new packages and installs them automatically.

You can search for packages by typing apt-cache search . For example, if you want to search for Python 3, type apt-cache search python3.

1. Ubuntu software center

For a long time, people believed that the Linux operating system is only for geeks that are glued to the terminal, churning out commands at the speed of light. Not anymore.

Linux has come a long way, and if you are a GUI person, then do not worry. Ubuntu software center is a great option for installing and generally managing software packages.

The Ubuntu software center GUI typically looks as below. At the top bar, you have four main buttons: On the far left is an option to search for software packages. The three buttons in the center of the screen are used to explore new software, list installed software, or check for software updates.

Installing software in the Ubuntu software center is simple. Select the package you wish to install then click the install button.

The installing page gives you details of the software package that you are about to install.

2. APT

APT is short for Advanced Package Tool, it is not just a package installer, it is a fully-fledged package manager. You can use APT to install, update, remove and even search for software packages, etc.

The most common and simplest way to install packages via apt is to run the following command: apt install package_name. For example, to install the famous nano editor, simply run.

$ sudo apt install nano

3. Synaptic Package Manager

Synaptic another powerful GUI-based software package manager. If you do not have synaptic installed on your PC, you can install it by running the following command.

$ sudo apt install synaptic

Once Synaptic is installed, you can start it from the GUI. Then select the software you wish to install by checking the installation box and then click apply. The installation GUI should look as below.

Note: Synaptic does not apply changes immediately. You must click the apply button for the marked changes to take effect.

4. Downloadable packages

One of the most common ways to install software on Ubuntu is via .deb packages. You first download the package from a software source and then install it using any of the methods below.

There are three main ways of installing .deb software packages.

Installing with APT

If you have a .deb package on your local computer you can simply install it via the APT command-line tool. For example, to install the Virtual Box software that is located in your Downloads folder. First cd into the Downloads folder.

$ cd ~/Downloads

Once in the package location folder, you can use the following command format sudo apt install ./package_name.deb. For example, to install virtual-box, you can run.

$ sudo apt install ./virtualbox-6.1_6.1.18-142142~Ubuntu~eoan_amd64.deb

Also, the command above will install all the required software dependencies for the package that you are installing.

Installing with dpkg

Dpkg is the core software package tool on Debian-based Linux distros. Installing packages via dpkg is very simple and follows the following format.

$ sudo dpkg -i ./package_name.deb

After the command above, you need to resolve software dependency issues by running the following command. Unlike installing the .deb package via apt, the dpkg tool will not automatically resolve dependencies.

The command below informs the apt package manager to fix broken dependencies for all the currently installed packages on the system.

$ sudo apt install -f

Installing via the GUI

Last but not least, you can install .deb software packages, simply by double-clicking the .deb file. Doing so will open the file in the Ubuntu software center and then you just click install from the GUI menu.

5. Compiling from source code

The final option we will cover is to install software from source code. That is, you download the software source code and compile it yourself.

Unlike the other installing methods that we have looked at so far, this is probably the most demanding, but it is worthwhile.

Since most Linux packages are free and open-source, you have the ability to modify the source code of any piece of software and change it to your own liking. Additionally, you might just be interested in learning good architecture and coding patterns from huge software projects.

We will go through the main steps of compiling your own software with an example of compiling git, the famous version control system.

  • First, install software packages that are useful for compiling source code e.g make and GCC, etc. Besides, we will also install curl, which we will use to download the software source code.
$ sudo apt install libz-dev libssl-dev libcurl4-gnutls-dev libexpat1-dev gettext cmake gcc curl
  • Download the source code files using the curl command-line tool. An alternative is to use the wget tool or the GUI.

We want to place the software source code in the Downloads folder, but you can use any other location, cd into your Downloads folder using the following.

$ cd ~/Downloads

Once in the download folder, you can download the git source code using curl as follows.

$ curl ./-o git.tar.gz
  • The source code is usually packaged in a compressed folder. You can extract it using tar with the following command
$ tar -zxf git.tar.gz

Then cdinto the extracted folder, in this case, it is git-2.26.2. Usually, you can get more information about the installation of the package by opening and reading the file located in the root folder of the source code.

$ cd git-2.26.2
  • Configure and prepare your source code using the following command. The command will create make files and configuration for the software that we are about to install
$ ./configure
  • Now that everything is configured, we can compile the software using the following command in the root folder of the source code.
$ make

The compilation process will take some, but once it is done, we are all set to install our freshly compiled software.

  • Finally, install the compiled software using the following command.
$ sudo make install

You can test if git was successfully installed as follows.

$ git --version

Final thoughts

In this guide we have looked at how to install software using five different methods in Ubuntu Linux, these methods should work on other Debian-based distros except for the Ubuntu software center which is specific to the Ubuntu distro.

Leave a Comment