Installing software on Fedora

Adding Applications

© Lead Image © lightwise, 123RF.com

© Lead Image © lightwise, 123RF.com

Author(s):

We provide an introduction to installing and managing RPM packages.

Contrary to what you may have heard, you do not have to compile software yourself on Linux. Although compiling from source code can optimize software for your system, almost all distributions have a much easier way to install software. Fedora is a typical example, offering you a choice between a desktop interface and a command-line process for managing software.

In both cases, you are working with packages – files available online from your distribution that are a collection of software and the scripts needed to install and configure a piece of software for your system. A properly designed package also analyzes dependencies – that is, the other applications and libraries needed to run the software and offers to install them. When you are logged in as root, you can add, remove, or delete software by similar processes.

Fedora uses the RPM package format, whose files are identified by an .rpm extension. RPM packages are not compatible with other package formats, such as the DEB packages used by Ubuntu or Linux Mint, although a utility called alien can sometimes convert other formats.

Packages are stored in online collections called repositories. During installation, Fedora configures your system to use its standard repositories. As you become more experienced, you can enable other repositories, although you should be careful which ones you choose. For your first efforts in package management, you should make your life easy and use only the repositories already enabled on your system.

Managing Software from the Desktop

The latest version of Fedora [1] installs with gnome-software, a basic package manager. If you are using Gnome, you can find this utility by entering "Software" in the search field in the Activities overview and clicking the icon in the search results (Figure 1).

Figure 1: Software is Fedora's default tool for managing packages.

By default, the Software window displays all available packages, whether they are installed or not. However, at the very top of the window, you can filter the view to show only installed packages, or those which have updates in the repositories.

The top part of the Software window is devoted to one featured package and a list of Picks, or popular software. You can ignore this part of the window, unless you feel like browsing random packages for ones that might interest you.

Instead, scroll down and select a category that might include the type of software you are looking for. Alternatively, use the search field at the top of the Software window to look for either a specific package or a general category such as "email" (Figure 2).

Figure 2: Searching Software returns a list of possible results.

Clicking on a category or a search result provides you with a list of search results. Those already installed have a red Remove button to their right, whereas uninstalled ones have a gray Install button. You can either click an Install button or else click a search result in the hopes of reading a more detailed description of the package and find a link to its project website (Figure 3). Often, you get no more than the search result reformatted. After reading the details, click the Install button at the top of the window.

Figure 3: If you want more details, you can sometimes click on a search result to learn more about a package.

Before anything installs, you must login as administrator (root). The Install button grays out, and Software downloads and installs the package (Figure 4). Depending on the size of the package and the speed of your Internet connection, the process can take anywhere from less than a minute to half an hour. However long it takes, Software displays a brief message at the bottom of the screen and remains open for other actions.

Figure 4: Software is designed so you only need to log in as root as you start the actual installation.

Removing a package is similar: Locate it, then click the Remove button next to its descriptions. To update, filter Software to show the available updates and install the updates as you would new packages.

The Software tool is ideal for new desktop users, because it is designed for basic operations and is easy to navigate. All the same, once you have some experience, you might consider installing a more advanced package manager. Software deals mainly with binary packages, which are ready to install on your system; if you want to optimize performance, you might try Package Organizer, which is intended for source code packages that are compiled into binaries during installation.

Another tool for experienced users is Yum Extender (Yumex), which can handle more complicated situations, as well as setting up non-standard repositories (Figure 5).

Figure 5: Yum Extender is a desktop package manager for experienced users.

Once a package is installed, the Fedora updater notifies you when newer versions of it are available for the release you are using. If the package is a vital part of the system, such as the Linux kernel, you should update as soon as possible for security. However, other updates can wait until convenient.

Installing with Yum

Although Software is convenient, many experienced users prefer to manage software from the command line using Yum. Enter the command man yum to read the online help, and you soon see why (Figure 6). Over the years, Yum has grown to include options for handling just about every situation you can imagine.

Figure 6: The yum command lets you track the progress of package installation.

Another advantage of using Yum is that you can see exactly where it is in an operation, watching it update the list of repository contents, find the requested updates, and calculate the dependencies before giving you a summary and a choice of whether to continue installation.

In direct contrast to Software, Yum assumes that you want as much information as possible about what you are doing. Yet the basic commands are not very difficult:

yum install [PACKAGE]
yum search [STRING]
yum remove [PACKAGE].

Other advantages of Yum include:

  • yum install [PACKAGE] – Work with a space-separated list of packages, instead of one at a time.
  • yum groups [GROUP] – Work with groups of related packages, install them all in a single operation.
  • yum localinstall [PATH] – Install from packages downloaded to your computer.
  • yum downgrade [PACKAGE] – Downgrade packages to solve problems.
  • yum updateto [PACKAGE] – Select the version of a package to install.

Other commands for Yum provide utilities for repairing problems and displaying detailed information about packages, including their dependencies. Typically, Yum commands are regular in structure, making them easy to learn.

Yum also has several related commands. For example, if installation was interrupted before it was complete, you may have trouble installing anything else. Using the command yum-complete-transaction or yum history redo last, you can complete the interrupted action, leaving Yum unimpeded.

Managing Package Repositories

Fedora installs with three repositories enabled: fedora, updates, and updates-testing. These repositories contain only free-licensed software packages, and much of the work of producing a new Fedora release involves making sure that these packages install properly and do not conflict with one another.

These repositories are enough for most needs. However, some users want proprietary packages, such as Flash or hardware-accelerated video drivers, and turn to other packages instead. The most popular and reliable of these third-party repositories are RPM Fusion [2] and rpm.livna.org [3]. You can also find other repositories online [4].

However, using these non-official repositories can be dangerous – not because they are actively malicious, but because they may not be as well-tested as the official repositories and may conflict with the official repositories or one another. Similarly, not all nightly builds of Rawhide, Fedora's repository for packages being readied and tested for the next release, may be trouble-free.

All these problems can leave you unable to install software or with a system that cannot boot – condemning you to endless hours of exploring the more obscure options in Yum. For this reason, you should be careful about adding or removing repositories. However, if you decide to add another repository, go to its site and search for instructions on how to enable it. These instructions generally involve installing the repository's package list.

In the case of Rawhide [5], this involves installing the package fedora-release-rawhide. In the case of third-party repositories, enabling involves downloading the package that lists the repositories and installing it using yum localinstall [PACKAGE]. You can then use

yum-config-manager --enable [REPOSITORY]

(or disable [REPOSITORY]) as needed. You may prefer to browse third-party repositories and download individual packages to minimize the chances of getting into trouble.

Buy this article as PDF

Express-Checkout as PDF
Price $2.95
(incl. VAT)

Buy Linux Magazine

SINGLE ISSUES
 
SUBSCRIPTIONS
 
TABLET & SMARTPHONE APPS
Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

  • Smart Package Manager

    The package manager is one of the central components on any Linux system. If you have a system with unreliable package management – such as Suse Linux 10.1 – you may want to consider the Smart alternative.

  • A Taste of Yum

    Install and manage packages from the command line with the powerful yum package manager.

  • SmartPM

    The Smart Package Manager makes everyday tasks of handling RPM and DEB packages simple but has a full set of controls for experts.

  • Manjaro and Antergos

    Manjaro and Antergos put the power of Arch Linux in a beginner-friendly form.

  • Yum

    The RPM package manager Yum has its own advantages over other tools.

comments powered by Disqus

Direct Download

Read full article as PDF:

Price $2.95

News

njobs Europe
What:
Where:
Country:
Njobs Netherlands Njobs Deutschland Njobs United Kingdom Njobs Italia Njobs France Njobs Espana Njobs Poland
Njobs Austria Njobs Denmark Njobs Belgium Njobs Czech Republic Njobs Mexico Njobs India Njobs Colombia