Downloading software from the Internet is the Windows way of installing software. Using this method, a user would download software packages from the Internet and then install those packages. It's important to choose the correct software package for our version of Linux. Linux software is distributed in a software package. A package includes binary programs, data files, metadata, and installation scripts.
- [Instructor] Let's talk about downloading software from the internet. I call this the Windows way of installing software. It entails browsing to a website and downloading a Linux software package and installing it. I've browsed to plex.tv/downloads This particular piece of software is called Plex Media Server and I use it for serving up video and audio files to set-top boxes in my home. If you wanted to install it this way we'd scroll down a bit and click on download. Make sure that Linux is selected in the list and then click on download again.
Now it's prompting me to choose which Linux I'm using. This particular project has provided six different packages for three different distributions. Ubuntu, Fedora, and CentOS. There are six choices because they provide both 32 bit and 64 bit packages. Most Linux software is distributed in the form of a package. A Linux software package is an archive of sorts that includes the binary software programs themselves, data files like documentation and example configuration files, metadata about the software including where it should be installed, file sizes and version numbers, and lastly scripts that run before installation or uninstallation.
There are a couple things that we need be aware of before downloading software packages from the internet. You must have the right type of software package. There are several different types of packages for Linux. Different distributions use different package formats. For instance Debian based distributions use Debian package format and Red Hat based distributions use the rpm format. You also must have the right version number of the software package. You may or may not be able to install version two of an application if it's not compatible with the OS. You must have a package compiled for the correct processor architecture.
You cannot install 64 bit software on a 32 bit system. This is a lot of stuff to be aware of. The way we identify the correct package is by looking at the name. In this case the name of the program is zip. As we can see from the beginning of the package File Name. After the hyphen we have the Major Version Number. In our case this is zip version three. After the decimal we have the Minor Version Number which in our case is zero. Following the hyphen is our Package Release Number. This is how many times this package has been built.
The version of the software inside remains the same, but other attributes of the package have changed. For instance they may have added more documentation or changed the metadata information such as the description. After the next decimal is the OS Distribution Type. This says el7 or Enterprise Linux seven which includes Red Hat Enterprise Linux seven and CentOS seven which I'm currently using. The next section after the decimal point is the CPU Architecture which in my case is x86_64.
This means I'm using a 64 bit processor. You may also see this written as AMD64 as well. Especially on Debian based distributions. Other architectures may be i386 or i686 for 32 bit processors. These are getting rare these days and CentOS doesn't officially come in a 32 bit version although one is available from a third party. The last bit of the package name is the extension. In our case it's rpm which stands for Red Hat package manager. There are several different package types, but most systems either use rpm or deb which is the Debian package format.
Now that we are sure that this package is the right version, it's made for our particular distribution, compiled for our processor and the package format is correct, we could download it by right-clicking and selecting save link as. However this is not usually the way software's installed in Linux and let me explain why. When we download a software from the internet we have to take extra steps to verify that the software doesn't contain any malware including viruses. Sometimes this can be difficult. There are facilities in place to make this process easier for Linux software packages.
Packages can be cryptographically signed with a key by the software developer. The corresponding public key is distributed and made accessible to the client. The software installer verifies the signature of the package using the corresponding key. If the software can be verified it is then installed. For every unique signature, a user has to import a public key. To make installing stand alone packages simple the developer may forgo the trouble of signing them. If the package is not signed, there's no easy way of telling if it has been altered or corrupted since the developer created it and should be avoided if possible.
Unsigned packages may contain malware. Also when trying to install a single stand alone package we may run into package dependency problems. A software package is designed to take advantage of other software components such as libraries that are already available. This means in the name of efficiency, it will rely on and need other software packages to be installed. For instance if the developers of a word processor want to include spellcheck ability, they would not include the spelling dictionaries in the package. They would just list the spellcheck package as a dependency.
This allows for smaller package sizes. This dependency would need to be installed before the word processor package was. Earlier we looked at the file name of the zip package. Here's a brief list of the dependencies that this package requires to install. If you try to install zip without first installing its dependencies, we'll get an error message and the installation will abort. It is possible to install software by downloading it from a website, but not without problems. I highly recommend considering the other options that we covered in this course.
- List the factors that must be checked before downloading a Linux software package from the internet.
- Cite what must be done before installing software from source.
- State the key difference between a local package manager and a repository-based manager.
- Write what you would specify on the command line to change the rpm query format.
- Explain how a Yum client knows what software can be installed.
- Identify which directory Yum repository configure files are stored.