Installing new software
Installing new software is usually rather easy on Linux. When you received the Software-in-a-box most software was installed and in a working condition. But sometimes a small bit is missing or your software needs to be updated.
The Yellowdog Update Modified
The Centos uses the yum (Yellow-dog Update Modifier) to control the software. yum is a command-line tool. But luckily a bright Dane wrote a graphical tool the gives a somewhat more intuitive interface to yum, the yumex Yum Extender. So everything yumex can do yum also can do and often a bit quicker because there is no graphics to update.
You'll find yumex in the menu. It should be intuitive to use, so no more explanation here.
Most of the software you'll need is stored in repositories controlled by e.g. the Centos organisation, but also others contributes with important repositories. In general Centos is built using free software without any kind of patent rights or closed source, but some software is often necessary to circumvent the free and open mind. Hence someone sets up these alternative repositories.
Add a new repository
Sometimes you're asked to install software from a repository that you don't know. Take a careful look at the site and search the net for references to the site. Most of the sites I've come across are fine, but one can never know.
For instance you want to install dia, but when executing the yum tool you wont find it. I've came across the li.nux.ro site who keeps a repository for RHEL (including Centos) and Fedora.
Over on the li.nux.ro site I've found that one, as root, could execute
]$ yum -y install epel-release && rpm -Uvh http://li.nux.ro/download/nux/dextop/el7/x86_64/nux-dextop-release-0-5.el7.nux.noarch.rpm
to load the repository on my Centos. From there I can install dia.
As told yum is a command-line tool. So you'll have to find a console in order to work with yum. yum requires root access in order to perform install, update and erase of packages. To learn more about yum type in
]$ man yum
If you want to see the active list of repo's (repositories) type in
]$ yum repolist
and you'll get something like this
From here we can see that we are pulling software packages from the base, extras, updates and epel repo's. The first three is directly from the source of Centos whereas the last is from a group of people, that felt that something is missing and therefore keep a quite large base of other applications, that are usually needed in a Centos (and RHEL, Oracle, Scientific Linux etc, who all are based on the Red Hat Enterprise Linux (RHEL)) installation.
If you need to install software that you cannot find in these repositories first try to locate if somebody have made a repository containing the needed software. E.g. Google Chrome is installed by adding a repository from Google and from that repository you can pull the Chrome browser. In this way you'll always have the latest.
Linux software as all other software is updated regularly. The updates contains both important security patches, bugfixes and new functionality.
Therefore you should regularly, say every other week, execute this command
]$ sudo yum update
in order to keep your system up to date.
Often you'll just get something like this
but other times you'll get a long list of packages to update. Just let the update run and you can perform other work while the system is being updated. It will not restart or do any other annoying things while updating. If you get a new kernel I recommend you to restart your system first time convenient. Otherwise just keep on working. Server installations does these updates every night and just keep on serving what ever they are set up to serve.
Install new software
Sometimes you'll find instructions on the Internet that this or that package must be installed in order to perform some function that you need.
For example lets say that you need the GNU debugger, gdb. First search for the package by executing
]$ yum search gdb
We see that there are a lot of packages that includes the gdb word in the name or in the description. We can see that the package we're instrested in could be gdb.x86_64 : A GNU source-level debugger for C, C++, Fortran, Go and other languages
Let's see what's installed
]$ yum list gbd.x86_64
so gdb was installed and originally it came from the base repo.
In case that the gdb package was not installed you can issue this command:
]$ sudo yum install gdb
Notice: no need to specify the CPU architecture (.x86_64). Yum will just pick the correct version for you.
You'll get something like this:
We can see that in order to install the gdb package yum has found out that gdb is not dependant on other packages. If it were, yum will suggests to install the dependant packages also.
Just hit y in order to let the installation begin.
In the following picture you see an example of install several packages in one time. Just list the packages after the yum install command.