Updating the installation and enhancing the minimal install with additional administration and development tools
In this recipe we will learn how to enhance the minimal install with additional tools that will give you a variety of administrative and development options that will prove vital during the lifetime of your server.
The minimal install is probably the most efficient way you can install a server, but having said that, a minimal install does require some additional features in order to make it a more compelling model. We are all aware that a server will require a variety of administration and development tools and with this in mind, this recipe will show you how to install the extra packages that will not only prove useful throughout the reading of this book, but they will endeavor to improve your workflow and your overall enjoyment of CentOS.
Getting ready
To complete this recipe, you will require a minimal installation of the CentOS 6 operating system with root privileges with a connection to the Internet in order to facilitate the download of additional packages.
How to do it...
We will begin this recipe by updating the system.
- To do this, log in as root and type:
yum –y update
- CentOS will now search for the relevant updates and, if available, they will be installed. On completion and depending on what was updated (that is, kernel and new security features to name but a few), you can decide to reboot your computer. To do this type:
reboot
- Your server will now reboot and having returned to the login screen, we will now complete the main recipe and enhance our current installation with a series of package groups that will prove to be very useful in the future. To do this, log in as root and type:
yum –y groupinstall "Base" "Development Libraries" "Development Tools"
- When the installation process is complete, simply reboot your server by typing the following command:
reboot
How it works...
The purpose of this recipe is to enhance a minimal installation of the CentOS 6 operating system and by doing this you have not only introduced yourself to the Yum Package Manager (something to which we will return to later on in this book), but you now have a system that is capable of running a vast amount of applications right out of the box.
So what have we learned from this experience?
We started the recipe by updating the system in order to ensure that our system was up to date:
yum –y update
At this stage it is often a good idea to reboot the system. The reason behind this is typically based on the desire to take advantage of a new kernel or revised security updates (that is, SELinux or IPTables). It is not expected that we will do this very often, but rebooting the server was simply a matter of using the following command:
reboot
In the next phase the recipe showed you how to add a series of package groups that may prove to be more than useful in the future. To save time we wrapped the instruction to install three main package groups in a single command like so:
yum –y groupinstall "Base" "Development Libraries" "Development Tools"
The preceding action alone installs over 200 individual packages thereby giving your server the ability to compile code and run a vast array of applications out of the box. This list includes Perl, Python, GCC, Make, nslookup, ping, and a vast array of other necessary and important packages you may need over the life time of your server.
For example, you can run nslookup
as follows:
nslookup www.packtpub.com
Moreover, instead of using the Vi text editor, you now have the opportunity to use the Nano text editor and many more. Which, given its lack of complexity, usually makes the process of managing your server that much simpler.
For example, if you are ever asked to edit or create a new a file. Instead of typing the following:
vi /path/to/some_file_name
You could type:
nano /path/to/some_file_name
You will be happy to know that this form of text editor replacement will work for all the examples shown throughout this book.
On top of this, you will also have the chance to use vim-enhanced , another fantastic text editor that supports scripts and color coding, but as a tutorial on this subject is beyond the purpose of this recipe I have included some links at the end of this section that will get you started.
The final part of this recipe was to action another reboot by typing:
reboot
Again this is not always required, but given the number of new packages you have just installed, it is often advisable in order for you to enjoy the benefits of your new server.
See also
- GNU Nano project's home page: http://www.nano-editor.org
- GNU Nano Guide: http://mintaka.sdsu.edu/reu/nano.html
- The Vi Lovers home page: http://thomer.com/vi/vi.html
- Vim project home page: http://www.vim.org/
- Vim documentation and help: http://vimdoc.sourceforge.net/htmldoc/help.html