Throughout this knowledge base, we present many articles detailing how to install and configure various Linux software packages and utilities. By taking a closer look at the articles across multiple Linux distributions, you might notice something interesting -- the procedure for installing a package is very similar even between different distros! For this reason, we will not always provide separate instructions for each distribution. The purpose of this article is to aid you in making the adaptations needed to apply a given set of instructions to your Cloud Server.
Package management is an important concept for a novice Linux user to understand. Unlike Windows-based operating systems, in which software packages come with their own installers, most Linux distributions include a centralized package manager. This means that nearly every package on the system can be installed using the same tools!
In addition to a centralized method of installing packages on a given system, Linux package management also features centralized software sources known as repositories. Typically, when a command such as 'yum install iptables' is run, the package manager (in this case, Yum) will download the relevant packages (in this case, iptables) from its repositories and install them on the system.
Every distribution offered by Cloud Servers comes with its own package manager. We've included basic summaries of each of these; however, Linux novices would do well to become familiar with the details by reading the relevant documentation.
aptitude install PACKAGENAME
aptitude reinstall PACKAGENAME
aptitude remove PACKAGENAME
aptitude remove --purge PACKAGENAME
aptitude show PACKAGENAME
aptitude search SEARCHSTRING
yum install PACKAGENAME
yum remove PACKAGENAME
yum update PACKAGENAME
yum list updates
yum list PACKAGENAME
yum search SEARCHSTRING
yum groupinstall 'GROUP NAME'
yum groupupdate 'GROUP NAME'
yum groupremove 'GROUP NAME'
pacman -S PACKAGENAME
pacman -R PACKAGENAME
pacman -Rsn PACKAGENAME
pacman -Qi PACKAGENAME
pacman -Si PACKAGENAME
pacman -Ss SEARCHSTRING
For more information on Pacman, please see the ArchWiki.
emerge --unmerge PACKAGENAME
emerge --update world
emerge --update --deep world
emerge --search SEARCHSTRING
emerge --searchdesc SEARCHSTRING
For more information on Portage and ebuilds, please see the Gentoo Linux Documentation.
There may come occasions when the software you're looking for simply isn't in your package manager's main repositories. There may be many reasons for this; usually, the software isn't considered well-known enough to be included. The best way to locate a single package like this is to search the Internet! The package's website is a good place to start. Rpmfind is another good source for RPM packages. Once you've located and downloaded the package, you can still use your distro's package manager to install it.
In some situations, you may have no choice but to compile and install a package manually. Maybe you need special customizations that weren't enabled by default, or maybe the software you want to install simply doesn't have a pre-compiled version. Either way, it is impossible to provide step-by-step instructions for all of these scenarios -- your best bet in this case is to go directly to the software documentation. However, you will almost certainly need a C/C++ compiler and make utility. These can be installed by running the following commands... on Debian:
apt-get install build-essential
... and on CentOS:
yum groupinstall "Development Tools"
This will install the utilities you would need to install most common packages directly from source. Once this is done, you will be able to follow the package's instructions and tailor the compilation to your needs. Good luck!
© 2011-2013 Rackspace US, Inc.
Except where otherwise noted, content on this site is licensed under a Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License