Linux Introduction
Linux Introduction
Lesson 1 - Introduction
In this tutorial we are going to learn in detail about the most stable and freely available operating system
which is the LINUX operating system.
This tutorial will guide you through various components of this Linux Operating System, and will provide
complete instructions to use the features available within the Linux Operating System. After going
through this tutorial you will be able to appraise the features of Linux Operating system, and would be
able to install, configure and manage the Linux Operating System with ease.
This tutorial, we will be focusing on the RedHat flavor of Linux which is the most common and famous
release of the Linux Operating System. In this tutorial, we will be discussing about the latest edition of
RedHat release which is Version 9. At the end of this tutorial, you would have mastered yourself in the
various features available within the RedHat Linux edition and you would be able to contemplate the
deployment of the Linux operating system in the production environment.
Lesson 2 – The Free Software Foundation
In this section we will be discussing about the Free Software Foundation (FSF) and its role in the
development of the Linux Operating System which is also known as the GNU Linux.
Free Software Foundation (FSF) was found by Richard Stallman in the year 1984.
The objective behind the Free software foundation was to make software freely available, redistributable,
modifiable and can be copied by users. Most of the software are developed in a proprietary fashion, and
we are unable to see the source code of the programs in which we are interested and therefore we are
unable to learn or modify the program. Hence the Free Software Foundation was founded with the
objective of providing software to the society freely, the source code of which can be viewed, modified
and redistributed by the any one. The great achievement and accomplishment of the Free Software
Foundation is that it has made freely available most of the Linux utilities or Packages and these utilities
and packages are able to substitute some or most of the commercially available utilities or packages that
can easily cost thousand dollars.
Lesson 3 – The GNU Project
In this lesson let us learn about the GNU project. The GNU Project was started in 1984 to develop a Unix
like operating system which is the Linux operating system that is freely available. GNU is an acronym for
the 'GNU's not UNIX'. The Free Software Foundation (FSF) is the principal sponsor of the GNU project.
The GNU Project has resulted in the development of the Linux Kernel which is commonly used in most of
the famous Linux distributions. This is the reason that most of the Linux distributions if not all, is properly
or accurately referenced as the GNU Linux. Most of the applications, utilities or packages available within
the Linux Operating System are all developed by the GNU Project. For example, the Most familiar bash
shell or terminal window which we use in the Linux operating system is developed or written by the GNU
Project or the Free Software Foundation.
The GNU Project has the GPL which is known as the General Public License. General Public License is a
covenant document for all free software that it protects. GPL provides the framework for keeping software
freely available to the society and so that the software does not become proprietary. This GPL states that
any one can modify, redistribute or make changes to the software protected within the GPL. The GPL also
states that no software protected by it can be made proprietary by anyone after modification. This is done
with the objective that any software redistributed after modification is made available to the society for
free and does not remain hidden in the hands of a few.
The complete information about the GNU project is available in the website of the GNU and the URL is
http://www.gnu.org. This is the website for the GNU project as well as the Free Software Foundation. In
this page you can get the information about the undergoing or new projects carried on by the Free
Software Foundation and other various information like the GPL.
Lesson 4 – Red Hat Linux Distribution
In this section we will discuss about the most famous distribution which is the RedHat Linux and we
would be working with this distribution throughout this tutorial.
RedHat is the largest distributor of the GNU Linux. RedHat is available through the website
http://www.redhat.com. To make the distribution easier to use and to make it user friendly, RedHat has
developed many Graphical interface tools to perform common tasks, similar to the tools developed by
other distributors. The RedHat provides a setup which is very easier for the users. The latest version of
RedHat Linux is RedHat Linux version 9 and we would be spending most of our time in this tutorial in
learning this version.
Redhat footprint ranges from 475Megabytes to 5 Gigabytes. RedHat Linux is available as a desktop
edition used for home users and as Enterprise Edition used by the Business segment. Redhat provides
packages and applications that serve either of these segments. We can find the Redhat Linux Operating
System, Patches and Updates download available at the RedHat website.
Lesson 5 – Other Linux Flavors
In this section we will learn about the popular Linux distributions that are available.
As we know, Linux was developed as a kernel along with some utilities and packages by the GNU Project
of the Free Software Foundation. As the Linux kernel is protected by the GPL also known as the General
Public License, the Linux Kernel is modified, enhanced and offered to the public freely by many
distributors. These distributors are also called as vendors and these distributions are known as Linux
Flavors. There are many distributors available online from where we can download various bundlings of
the Linux or the GNU Linux operating system.
There are differences notable within each Linux distribution such as Ease of Installation, Security level
and the Footprint which is the space required for the installation.
The first distribution which we will discuss is the Debian distribution of Linux. Debian Linux can be
located from http://www.debian.org/. The Debian Linux download is available in this website and you
can also find instructions on how to create a CD set using the downloaded images and information about
the installation steps. We can also find lot of other information about the Debian flavor in this web site.
Debian is known as the distributor for one of the most secure flavor of the Linux OS. The hard drive space
required for the Debian flavor is very small and this distribution is very secure. The hard drive space that
Linux occupies during installation is referred with the term footprint. The footprint of Debian typically
ranges from 250MegaBytes to 2 GigaBytes. Debian Linux supports many hardware platforms like the
Intel x86, I64, Alpha, ARM, Sun Spark, IBM Power PC etc.
The next one which we will be discussing about is the SUSE distribution. SUSE is another major
distributor of Linux which is widely used. The SUSE distribution is available for the Home segment as
well as the Business segment. SUSE provides packages that suite either segments. SUSE distribution can
be located at their website http://www.suse.com. SUSE provides a setup which is very easy to install. The
latest version available is SUSE Linux 8.2 and this uses the latest available GNU Linux kernel. SUSE
footprint ranges from a minimum of 400 Megabytes to a maximum 6 Gigabytes. Like Debian or
Mandrake distribution, SUSE also supports multiple hardware platforms. The SUSE Linux operating
system and Patches/Updates are available for download from their website http://www.suse.com.
And let's now move on to another major distribution which is Mandrake. http://www.mandrakelinux.com.
Like the SUSE distribution, Mandrake also provides a easy installation setup, which means, it is easy to
install the Mandrake Linux in the system. Another highlight of the Mandrake distribution, is that it
provides lot of Graphical Interface tools to administer the system. Though Graphical administrative tools
are provided in other distributions like RedHat, Mandrake leads the way in developing more Graphical
Administrative tools that can be used in performing common administrative tasks. Mandrake is available
for both the home and clustered business environment. The latest version available is Mandrake Linux 9.1.
Lesson 6 – Open Source Repositories
This lesson will focus on the major open source sites available on the internet.
We will learn about some of the frequently accessed opensource sites available on the internet. It is
important to have this information so as to know from where the Linux applications are available.
The first one to know is the sourceforge website which is http://www.sourceforge.net. This website
contains over 64,000 opensource projects and these projects are categorized into various sections.
Sourceforge claims as a largest repository for opensource projects handled ever. Not all projects available
in the sourceforge website is free, but the majority of the projects are free as they are covered within the
General Public License which is the GPL. Sourceforge website provides a software map link which
categorizes the available applications under various headings like Games, Multimedia, Internet, Desktop
Applications etc., so that it is easier to identify and locate a particular application to download. Under each
major category there are many projects available that pertain to that category. Software developers and
distributors spread out across the world use Sourceforge as a common repository. Thus Sourceforge serves
as a central site for developers, distributors or administrators to share ideas, software etc.
Next open source site is the http://slashdot.org. This is a site that provides news for nerds and this is the
place where we can find technological information related to the open source world. In addition to
technical information on open source this site also provides technical information about the proprietary
world. The documents available in this site are highly technical and beneficial to the those in search of the
same.
Another website to ponder upon is the http://freshmeat.net. Freshmeat.net is another repository or online
library for all types of open source applications and utilities. This site provides a search engine using
which the projects, applications and utilities can be located.
The next and most important repository is the http://gnu.org. GNU.ORG is most important open source
repository available. It is important because, the majority of the applications, utilities built in within most
of the Linux Distributions comes directly from the GNU or the Free Software Foundation. We can find
information about the various ongoing projects in the GNU website.
Another important repository is the http://www.apache.org. This is an important open source repository
because apache offers lot of free software like its famous HTTP server application. Apache provides tons
of other applications and utilities for the Linux operating system and most of these applications cater to
the enterprise needs.
What we have seen in this lesson is not the complete list of repositories, but are only the important online
open source repositories. In addition to these there are other repositories as well and the focus of this
lesson is only to provide an eye opener in this area.
LINUX Operating System – Basics
Lesson 7 – File System Hierarchy - I
In this lesson we will be discussing about the File System hierarchy in Linux. Linux Distributions in
general and Red Hat distribution in specific, ships with its own file system hierarchy. We can find that the
files, utilities and symbolic links are spread over many directories and it is very important to learn this
directory structure of Linux to work efficiently in a Linux environment.
To discuss about the directory structure or file system hierarchy, let me open the file browser from within
the GNOME Desktop. Double-click the Root's Home icon. This launches the new screen and this opens
by default the /ROOT directory, as we can see in the Location field. Removing the ROOT in this field and
hitting enter will take us to the root level of the linux file system. This root level is identified by a forward
slash as we can see in the location field. In this root level we can now see various directories like BIN,
BOOT, DEV, ETC, HOME etc.
Let us talk about some of the important directories. First and foremost one is the BIN directory. This
directory consists of all the common binary files that are accessible by all the users of the system. Binary
is nothing but a file that is necessary to execute a command or run a utility in the Linux environment. In
other words, this directory contains all of the commands that we use in a Red Hat Linux system, and these
commands are accessible by all users. Let us open this directory. Most of the files which you see inside
this directory are executable binary files for commands that we enter inside a terminal window. Some of
the commonly used binary files which we can see here are CAT, CP which is for copying, DATE which is
for displaying system date, GREP, KILL used to kill processes, the LS which is used to list directory
content, the MV which is used to move files. Note that these binaries are executable only from a terminal
window. I will illustrate this. Open a new terminal window, by right-clicking on the GNOME desktop and
choosing New Terminal. This opens the terminal window wherein we can execute various commands that
we looked in the BIN directory. In the new terminal type LS and hit enter. Note that the command
executes and lists the contents of this directory. To close the terminal window type EXIT and hit enter.
Lesson 8 – File System Hierarchy - II
Let us next move on to the next important directory which is the BOOT directory. This directory consist
important files which are related to the kernel.
To explain this in detail, in the terminal window, we will enter the command LS BOOT/. This will list the
content of this directory. Here we can find all the kernel and kernel related files which are necessary for
Linux to function. You can also find a GRUB directory within this directory, and this directory contains
the boot loader files that boots the system and loads the Linux kernel.
Let us do a LS of the root. Let us now move on to the DEV directory which is another important one to
discuss. The DEV directory holds the files related to every physical device attached to the Linux system.
In Linux, devices are stored as special files, which are stored within the DEV directory.
To explain this further, enter the command LS DEV/ and we can see a long list of files available for each
and every physical device that can be connected to the Linux system. There is a device file already
available within this directory that provides support for standard hardware like keyboard, mouse, printer
etc. Some of the hardware vendor provide software along with their device, and when installing the
software, the device file of that hardware device is automatically placed within this directory.
We will do a LS of the root again. Next we will discuss about the ETC directory. The ETC directory
contains the configuration files that are specific to this Linux host system. These files contain the
configuration regarding the DNS, DHCP, IP Address, other network related settings as well as any
application related settings. To discuss further on this, let us enter the command CD ETC/ to change to
this particular directory. Now if we list the content of this folder by entering the LS command, we can see
many .CONF files. These are the files that hold system specific configuration details. To list the CONF
files alone, just enter the command LS .CONF and hit enter. Now we can see all CONF files. Each
CONF file is related to a particular component. For example the dhcpd.conf file contains the DHCP
configuration. The NTP.CONF file contains the Network Time Protocol settings and the RESOLV.CONF
file contains the DNS settings. Let us get back to the root of the directory structure by entering the
command CD /.
Lesson 9 – File System Hierarchy - III
We shall move on next to the HOME directory. This directory serves the same purpose as the Documents
and Settings folder for a Windows user. The user profile information is stored in the Documents and
Settings folder for each folder in a Windows environment and in the case of Linux the user profiles are
stored inside this HOME directory. Within this directory there will be a directory created for every user of
the system. For example if we LS this directory using the command LS HOME/ we can find one directory
which is for the one and only user LINUXUSR created in this Linux installation. If additional user IDs are
created, separate folders will exist in this location for those users as well.
We will now clear the screen using the CLEAR command and will do a LS again. We will now discuss
about the INITRD directory. This is specific only to the Red Hat Linux distribution. This is the INITIAL
RAM DRIVE that is mounted when starting the Red Hat Linux system. This directory is used by Red Hat
Linux to mount certain portions of the system memory to the physical hard drive. This directory does not
contain any file. This directory is occupied only when the system boots.
Let us now move to the next important directory which is the LIB directory. This directory homes the
shared library files for the Linux operating system. Shared Library files are very familiar in a Windows
environment, wherein the common library files that are shared by applications are stored in a common
folder. The LIB directory serves the same purpose by storing all the shared library files in the Linux
environment. We can LS LIB/ and this will list all the shared library files available within this LIB
directory.
Lesson 10 – File System Hierarchy - IV
Let us clear the screen using the CLEAR command and LS the root again by entering the command LS /
to display the directory structure. The next directory which we will be discussing is the Lost & Found
Directory. This directory will contain the information about fragmented files, accidentally or temporarily
deleted files, broken inodes etc. Normally this directory is blank. When there are entries found within this
directory, it means there are fragmented files with the hard drive that may lead to potential disk issues.
Let us clear the screen using the CLEAR command and LS / again to display the directory structure. The
next directory is the MISCELLANEOUS Directory. This directory is not an essential part of the Linux file
system. However Red hat provides this folder so that this directory can be utilized when some applications
require a Miscellaneous space. This directory serves the same purpose as the TEMP directory in
Windows.
Let us move on to the MOUNT directory which is shown as MNT. This is the directory that acts as a
temporary mounting location for the removable devices connected in the system. If we do a LS MNT/ we
can find the removable devices that are temporarily mounted. We can find the two removable devices
namely the CD-ROM and FLOPPY mounted to this directory. When we insert a DVD/CD media or a
floppy disk media in the appropriate drive, the media needs to be mounted first for gaining access. Once
the media is mounted the contents of the media can then be accessed from the CD-ROM or FLOPPY
directories respectively.
Let us clear the screen using the CLEAR command and LS / again to display the directory structure. We
can move on to the OPT directory. This is the directory that is used as a repository for Add-On
Applications. If we install additional applications that is not part of the Linux Installation set, that
application will setup the directory structure within this directory.
Lesson 11 – File System Hierarchy - V
Next is the PROC directory. One important thing to note about this directory is that the PROC directory is
a temporary directory that is created in the virtual memory of the system and is available only when the
system is running. This is not a permanent directory that is available in the hard drive. We can do a LS
PROC/ to see the contents of this directory. This directory is used to store all run-time information like
memory stats, file system stats of the Linux system.
Let's CLEAR the screen and LS the root again. Next we will move on to the ROOT directory. This
directory is the directory space allocated for the ROOT login that is created during Linux installation. This
is the home directory for the user named ROOT. Likewise there is a home folder for every other user
created within a Linux system.
Next we will move on the SBIN directory. This directory contains the system binaries that need to be run
only by the ROOT user or the Super User of the system. If we do a LS SBIN/ we can see the list of system
binaries or utilities that are available within this directory. We can scroll through this long list and these
are the utilities which only the ROOT level user or the Super User have access to and will be able to run.
Let us CLEAR the screen and LS the root again. Next is the TMP directory that serves as a temporary
location for all applications like a Temp directory in Windows. We also have the USR directory that
homes all the applications that needs to be accessed by users like for example, the web browser. The final
directory is the VAR directory that holds all variable data like a log file. Any file that holds variable data,
is stored within this directory.
Lesson 12 – Accessing Linux documentation
In this lesson we will be learning how to access the system manuals available in the Linux system.
To find information about the usage of various commands and tools available in Linux, we need to have
some sort of documentation that can serve as reference for users. This documentation provides
information about the usage of a command as well as serves as a helper in running the command. In the
Red Hat Linux distribution or in any Linux distribution, a package of tools are installed which provides a
mechanism to access or refer these documentation. This package is called the MAN package. Like any
other Linux package this MAN package is also a RPM package that gets installed by default during the
Linux installation. When this package is installed we will be able to access the documentation pertaining
to any command or tool in Linux using the MAN command.
To illustrate this we will open a new terminal window. We will type the command MAN in lower case
followed by space and followed by the command, for example LS and hit enter. This will display the
documentation pertaining to the LS command. You can see in the screen the description of the command,
the synopsis portion followed by the description and arguments that can be used along with this LS
command. Keep in mind that, by entering man followed by the command name, we can access the
documentation of that particular command or tool. Hitting enter will scroll through the subsequent pages
of the documentation. Press the Q key in the keyboard to exit out the manual.
Let us discuss further about this MAN package. Like we said earlier the MAN package is a RPM package
that is included in the Linux installation. In the terminal window, we will do a RPM query by entering the
command rpm -q man and hit enter. This will query and display the result of the MAN rpm package. We
can see that man 1.5k-6 is displayed. This is the default version of the man package which is installed in
Linux. We can also enter the command rpm –qi man to get detailed information about this man package.
Having discussed about the MAN package, let us now discuss about the directory structure within which
the system manuals are stored by default. We will clear the screen and will now run the command
manpath. We can see all the directories within which the manuals are stored. We can see four directory
paths namely;
/Usr/Local/Share/man
/Usr/Share/man
/Usr/X11R6/man
/Usr/Local/man
Of these four paths, most of the manuals are normally located in the second path which is the
/usr/share/man, while some applications choose to install the manuals in the other paths as well. Manuals
relating to the GUI or X Windows environment are installed in the /Usr/X11R6/man path.
To discuss further on this we will change to the /Usr/Share/man directory. To do this enter the command
CD /usr/share/man/ and hit enter. We will do a LS and can find many directories listed. The directories
CS, DE, FR, HU, JA, IT all corresponds to various foreign languages and these directories contain the
manuals for these languages. The directories man1 through man9 which we see here all contains the
english version of the system manuals. MAN1 contains the manual pages for user tools like LS, CP, MV
etc. Documentations relating to system calls that are useful for programmers are stored in MAN2. MAN3
contains the documentation pertaining to C libraries and these are helpful for C programmers. MAN4
contains the documentations relating to the device drivers. MAN5 contains the documentations related to
Configuration files. Documentation relating to games are stored in MAN6 and the documentation
pertaining to packages are stored in MAN7 directory. MAN8 contains system tools documentations and
MAN9 homes the documentation relating to the Linux kernel.
Lesson 13 – Basic shell navigation
In this section we will learn about the Bash shell and some of the important tasks such as setting up
PATH, Variables and Aliases within the Bash Shell.
By default the shell which is available in the Red Hat Linux system is known as the BASH shell that
includes many features that makes navigating the Linux file system very much easier. To open the Bash
shell, right click and choose 'New Terminal' option. This is the BASH shell also known as the terminal
window through which we are able to interface with the Linux file system.
One main feature available within the BASH shell is the PATH variable, which makes shell navigation
much easier. The PATH variable here in Linux does the same function as a PATH variable used in a DOS
or Windows environment. The path variable determines the directory paths that Linux searches for
location binaries or executable commands when a command or tool is run.
For example when we run a command PWD, it just runs fine without asking for the path because the path
variable is already set such that the shell understands where to search for this command and the bash shell
locates this command and runs it automatically. We can enter the command echo $PATH and hit enter.
This will show the paths that are set for the current user who is logged in. Currently we are logged in as
ROOT and the paths which we see here are the one set for this ROOT user. Whenever we run a binary or
command or application, the system by default will check these paths to locate the binary or command or
application file and hence the command is run successfully.
The path variable can be set on a per user basis or on a global basis. We will now see how to set it on a per
user basis. We will do a LS –a to list the directory contents. This will show all files and directories
including the hidden ones. All the files which starts with a dot is a hidden file. In the list we can see the
dot bash_profile file. All the user specific environment settings are stored in this file. To make changes to
the user specific profile, we need to open and edit this file. We will run the VI editor to edit this file using
the command VI .bash_profile. Here we can see the PATH variable defined for the ROOT user. Note that
there is a dollar sign before the PATH string and this indicates that this is a variable. To modify the path
setting just go to the end of this line, press the I button to start insert, then type a colon followed by
$HOME/temp. This will add the path /ROOT/ENV1 to the path list of this user. Having done the
modifications, hit ESC key one, enter SHIFT+Colon followed by WQ to save changes and quit. Now we
need to run the command SOURCE .BASH_PROFILE to carry out the changes done to the profile file.
Now if we run the echo $PATH command notice that the /ROOT/ENV1 path is added to the path list.
Thus, if we run any script or binary or command, the system will now additionally check the /root/env1
directory along with the other directory paths in the list to locate the script, command or utility.
We will do a LS –a again to discuss about some of the other bash related files. We can see the
.bash_history which contains the commands that the user has recently run. We also have the .bash_logout
file that serves as the logout script for the user. We also have the .bashrc where we can place alias settings
for making the shell navigation easier and user friendly.
Apart from the path variable which we have discussed, we can set many other variables in the BASH shell
and to list the variables enter the command env and hit enter. We can also run the echo followed by space
followed by dollar sign and variable name to show the variable. We will now learn setting a new variable.
For example, we will set a value for a new variable named Redhat. In the shell window enter the
command export redhat=bestone and hit enter. Now if we type ENV | grep redhat and hit enter, we can see
that the result displays the value defined for this new variable. To remove this variable enter the command
UNSET redhat and hit enter. This will remove this variable from the system.
Let us know move on to the Alias section. We will learn how the Alias setting becomes useful. Normally,
when running any command that is related to disk size or memory size, the values are displayed in
kilobyte which is hard to decipher. We can set alias in this case so that the values are displayed in human
readable format. For example if we run the DF command, it lists the disk statistics in kilobyte format.
Now we will setup an alias for the DF command. For setting this type ALIAS df='df –h' and hit enter.
Now if we run the DF command again, we can see that the disk statistics are displayed in the human
readable format which is easier for understanding. To make this alias setting permanent so that it is
available in subsequent logon, we need to just add this alias command to the .bashrc file. If we do a CAT
.bashrc, we can see a section under which the aliases are stored. Just add the alias command under this
section using the vi editor, save the file and the added alias becomes available at every user login.
To display all the alias already set in the system type ALIAS and hit enter. This will show the set aliases.
LINUX Basic Tools
Lesson 14 – File and directory tools – Nautilus File Manager
In this lesson we will be discussing about how to manipulate the directory structure using the GUI
interface.
To launch the GUI interface just double-click the Roots Home icon from the GNOME desktop. This will
launch the NAUTILUS file manager which is equivalent to the File Explorer of Windows. As in the case
of the Bash shell, this nautilus file manager also by default opens the /ROOT folder which is the home
folder for this user ROOT as we can see in the location field.
To go up one level of the directory structure, click the UP arrow in this file manager. This takes us to the
root of the directory structure and we can see all the folders available one level down in this root directory.
To go one level down, double click that particular directory for example the HOME directory and within
that we can open the LINUXUSR directory. The current location where we are in the directory structure is
shown in the location bar.
We can adjust the view level by clicking the minus and plus buttons, so that more detail or less detail is
shown in the File Manager window. We can also click the down arrow and choose 'View as List' option to
show additional information about the directory file structure.
Thus it is very easier to access the directory structure using this nautilus file manager than in a Bash shell
environment.
Lesson 15 – File and directory tools – CD and PWD
In this lesson we will be discussing about various tools available that would help us to easily manipulate
the files and directories within Linux.
To learn about these tools, we will first launch a new shell window. As you can see when we open a new
shell window, we are automatically placed in the ROOT directory and this is because the root directory is
the home folder for the currently logged user which is ROOT. If any other user is logged in the user would
be automatically placed inside the /home/user folder. The first command that we would learn is the PWD
command. If we run this command, note that the shell displays the current working directory which is
/ROOT. This command is useful for us to identify exactly where we are when manipulating the directory
structure. Like any other binary the PWD command is located within the /BIN directory. We can run the
WHICH PWD command to ascertain this.
To change or get into a different directory we need to use the CD command. For example if we enter CD /
and hit enter, this will take us to the root level of the Linux file structure. The root level is always denoted
in Linux as the forward slash. When we enter just the CD without any parameters and hit enter, this will
take us back to the home directory of the user, in our case as we are logged in as the user ROOT, this will
take us into the ROOT directory. We will now get back to the root level of directory structure by using CD
/. We will now enter CD followed by a tilde symbol and hit enter. Notice what happens. We are now taken
again into the /ROOT folder as it happened when entering just the CD command. So both the CD and the
CD ~ commands serve the same purpose. The CD .. will take us one level up in the directory tree. We are
now in the /ROOT folder. If we enter CD .. and hit enter, notice that we are taken one level up which is
the root of the directory structure. If we run PWD notice that we are in the top most directory level which
is one level up from the /ROOT directory. To get to one level down than the current working directory, for
example to enter into the ROOT directory which is one level lower, we need to enter CD /ROOT and hit
enter. This takes us down one level. To get into the TEMP directory which is one level further down
within the /ROOT directory, we need to enter CD temp/ or we can enter CD /root/temp the full path and
hit enter. It is also possible to go two levels up the current working directory using the CD command. We
now learn how to do this. Run PWD and notice that we are currently in /ROOT/TEMP directory. If we
enter CD ../../ and hit enter, this will take us to the root of the directory structure which is two levels up the
current level. Each ../ that we add in the CD command takes one directory up the current level. If we add
three ../ in the CD command this will take us three directories up the current working directory. The ../
option of the CD command helps us move few levels up the directory structure when we are very deep in
the directory structure and when we do not want to directly move to the root level.
First we will start with the LS command. LS command is used to list the directory contents. This lists all
files and directories available within the current working directory.
Let us open a new shell window and will do a LS. This will list the contents of the /ROOT directory which
is the current working directory. The items that are shown in black text are all files and those shown in
blue are directories. Linux color codes the text depending on whether an item is a file or folder. Folders
are shown in blue color, files in black and if the file is executable binary, it is shown in green color.
Let us clear the screen and will now learn some additional options of the LS command. If we enter LS –L
and hit enter notice that the directory contents are listed in long format that includes additional details such
as the permissions, the directory owner, the group, the file size, file creation date and time, and the file or
directory name.
Next we will enter LS –A and hit enter. This will display more files and directories than earlier and the
reason is because the A option when used displays the hidden files also. If we see the results notice the file
names that start with a dot. This indicates that the file is hidden. We can also see the blue colored items
that start with dot and these are hidden folders which are available. In Linux every hidden file name starts
with a dot. The hidden files are not displayed unless you add the A option.
We will now enter the LS command with the –i option. This will list the inodes of the files and directories.
These number strings that appear before the file or directory names are known as the Inodes. Inodes
denote the actual location address of the file or directory in the disk. The LS options, which we have seen
so far lists the directory contents in alphabetic order starting from a to z. To list the contents in the reverse
order, enter the LS command with the –R option. Notice that the contents are listed in reverse order.
The LS command can also be used along with the complete directory path to list the content of a different
directory than the current working directory. For example we can enter LS /bin to list content of the BIN
directory. Like this we can enter any complete directory path with the LS command to show content of
that path.
One more important thing to note is the DIR command. This command is supported in Linux. If we enter
DIR and hit enter this will also list the content of the current working directory. The DIR and LS are the
same files and the difference between the two is the DIR command does not colorize the items as a LS
does and the DIR file is located in the /USR/BIN path whereas the LS file is located in the /BIN folder.
We will learn about the Make directory command. To create a new directory, from the bash shell, type
MKDIR and the directory name. Currently we are in the /ROOT directory. We will create a directory
named TEST within this /ROOT directory. Enter the command MKDIR TEST and hit enter. This will
create a new directory named TEST. We can confirm this by running the LS command which shows the
new TEST directory.
Like other command files, the mkdir file is also available within the BIN directory. Run the command
WHICH MKDIR and we can confirm this by seeing the result. We can also identify the package
membership of this file by running the command rpm –qf /bin/mkdir. This will show that the file belongs
to the coreutils package.
Having learnt how to create a new directory, let's learn how to remove the directory. The command to
remove the directory and file are the same. We need to use the RM command. Enter RM followed by –rf
followed by the directory name. Let us remove the test directory. Enter RM –RF TEST. The –rf option is
added to avoid system confirmation before removing the directory or file. If we do not use this option,
then system prompts for confirmation. Hit enter and if we do a LS, notice that the TEST directory has
been removed.
Let's look at the FIND command. This command as the name suggests is used to find files and folders
within the bash shell environment. The command is FIND followed by the directory path where you want
to search, for example /BIN, followed by –name and then the file name, for example CAT. If we hit enter
after entering this command the bash shell returns the path where the CAT file is located. By default the
find command searches all the sub-directories within the directory specified.
Let's now look at the LOCATE command. This command is also used to find or locate commands. The
difference between locate and find is that locate command returns the results by searching from a database
that is saved out of a cron job running daily. Find command does a real time search and hence slower than
the Locate command. Run Locate CAT and hit enter to locate the CAT items. The result displays all files
and folders that has the CAT string in its name. Thus it is preferable to use the find command instead of
the locate command.
Lesson 18 – File and directory tools – Touch, Echo and move
In this lesson we will be discussing about more basic commands such as touch, echo and move.
We will discuss about the TOUCH command. This command is used to create a new file within Linux.
Like other binary commands, the touch file is located in the /BIN directory and forms part of the coreutils
package. The syntax is touch followed by the new file name. We will create a new file to demonstrate this.
Enter the command touch rootusr.test. Now if we do a LS we can see that the new file rootusr.test which
we created is listed. Let us now populate this new file with some content. To do this enter the command
echo "This file created by root user" >> rootusr.test and hit enter. To read the content of this file, enter the
command cat rootusr.test. The shell window displays the content which we saved to this file. We can also
add content or edit the file using the VI editor. To edit the file using VI editor, enter the command VI
followed by rootusr.test. This opens the file within VI editor. Press i to start the insert mode. Move the
pointer to the end of the line and hit Enter to insert a new line. Type the text This line is added using VI
editor. Hit ESC key. Shift colon followed by WQ and hit enter to exit out of vi editor. Now if we do a
CAT rootusr.test we can see the newly added line.
Let's now learn about the copy command. The syntax to copy is CP file name and the destination folder.
We can now copy the new file that we created earlier. Enter CP rootusr.test rootusr.test.copy. This will
create a copy of the rootusr.test file within the same directory and the new file name would be
rootusr.test.copy. Hit enter. Now do a LS and we can see the new rootusr.test.copy file that has been
created.
We will learn about the move command. The syntax to move is mv file name and then the destination
folder. We can move a file to illustrate this. Enter MV rootusr.test rootusr.test1. This will move this file to
rootusr.test1 within the same directory. If do a LS we can find that the rootusr.test file is no longer
available, but the new file rootusr.test1 is available.
Now let's learn how to remove a file. The command to remove the directory and file are the same. We
need to use the RM command. Enter RM followed by –rf followed by the file name. Let us remove the
test file which we have been working with. Enter RM –RF rootusr.test1. The –rf option is added to avoid
system confirmation before removing the directory or file. If we do not use this option, then system
prompts for confirmation. Hit enter and if we do a LS, notice that the TEST file has been removed.
Lesson 19 – File and directory tools –Cat
We will learn in detail about the CAT utility. In the earlier lesson we used the CAT command to display
the file content on the screen. To read the content of the file run the command cat followed by the file
name. For example if we run CAT rootusr.test.copy notice that the file content is displayed in the monitor.
This is the primary usage of the CAT utility.
Apart from this there is yet another usage for the CAT utility which is known as concatenation. This
means that the output from two files can be redirected to a third file. Let us learn how to do this.
First in the Bash shell window, we will create two files. Enter touch testfile1 and hit enter. Enter touch
testfile2 and hit enter. Now we have created two new files. Enter echo content for testfile1 > testfile1 and
hit enter. Again enter echo content for testfile2 > testfile2 and hit enter. Now we have added content to
these two files. If we do a LS –L we can see that these two files are no more 0 bytes and they occupy some
bytes of disk space. Now we will concatenate the content of these two test files and redirect the output to a
third file. Enter cat testfile1 testfile2 > testfile3 and hit enter. If we do a LS –L now we can see a file
testfile3 that is newly created. If we do a CAT testfile3 we can see that the content of this file has the
content of the other two test files testfile1 and testfile2.
Lesson 20 – The VI editor - I
In this lesson we will be learning in detail about the famous VI editor available in Linux.
The VI editor is used to edit files available within Linux. This editor is installed by default when installing
Linux in the system. Though there are other editors, the VI editor is widely used editor in the Unix or
Linux environments. Within Linux, we have two versions of the VI available. First is the basic VI editor
and the other is the enhanced VI editor known as VIM. The enhanced VI or the VIM is available in
normal circumstances and the basic VI is the only available editor in case of disaster situations.
Before proceeding we will try to identify the location of the VI editor and the package to which it belongs.
We will open a new shell window and will type which VI. From the result we can identify that VI is set as
a symbolic link to the VIM which is the enhanced VI editor that is located in the /USR/BIN/ directory. In
normal situations, when we enter VI to launch the VI editor what we see is the enhanced VI editor that is
VIM. The basic VI editor is launched only when the VIM is unavailable and this happens only in disaster
recovery situations. We also have the basic version of VI in the /BIN directory available in the root
directory structure. We can check this by doing a LS /BIN/VI. This will show that there is a VI editor
available within the BIN directory. This is the basic version of the VI editor. As the basic version of VI
editor is the only available editor during disaster situations, most administrators prefer using this editor.
To identify the package membership type RPM –QA | grep vim and hit enter. This will show the three
packages that are necessary for the VI editor. The first package VIM-Minimal is needed for the basic
version of VI, the second package VIM-Enhanced is needed for the enhanced version of VI editor and the
third package, VIM-Common is needed for both the basic and enhanced versions.
Now let's proceed by using the VI editor. In the shell window, let's clear the screen and launch VI editor
by typing vi followed by the file name which we want to edit for example vitest. This is the test file which
we have created earlier for illustration purpose. Hit Enter. This will open the vitest file within the VI
editor. Within the VI editor we can navigate through the content using the four arrow keys. However apart
from these arrow keys we can also use the J key to move down, K key to move upwards, The L key to
move to right and the H key to move cursor to the left. The reason for knowing these navigation keys is
because VI editor is cross platform compatible and even in keyboards without cursor or arrow keys we can
work with the VI editor using the JKLH keys.
Lesson 21 – The VI editor - II
Let's now learn how to get help within VI editor. Anytime we need help, press Shift+colon and this takes
us to a different mode wherein VI editor commands can be entered. Type help in this mode and this will
open the help.txt file wherein you can find the help information pertaining to the VI editor. To exit out of
help screen, do a shift+colon again type Q and hit enter. This will take us back to the VI editor screen.
To search for any string within the file, press the forward slash key in the keyboard and type the string for
example we will search for the string profile and hit enter. The result is now highlighted. Hitting enter will
return to normal mode. To go to the end of the file use the Shift+G key combination. To return to a
particular line, for example the 4th line, enter 4 and this use the shift+G keys. This will move the cursor to
the 4th line within the file.
Now let's learn some editing techniques within the VI editor. To delete any character in the file, place the
cursor over the character and press the X key. This will delete the character. To undo the delete action
press U. To delete a complete word in the file, place cursor in the word and press DW keys. This will
remove the entire word. To delete the content from the place of the cursor to the end of the line, press D
followed by the Dollar sign. This will delete the rest of the line from the cursor location. To delete an
entire line press the d key twice. By specifying a number before the DD command, we can delete such
number of lines. For example if we enter the number 2 followed by DD, the next two lines are deleted.
Hitting U will restore the 2 deleted lines. To replace a particular character place the cursor over the
character which needs to be replaced and press the r key and then type in the new character which you
want. This will replace the character with the new one. To quit the VI editor after saving the changes,
press Shift + Colon and enter WQ and hit enter. This will save changes and enter. To exit without saving
changes, do a Shift+Colon and enter the letter Q followed by the exclamation mark ! and hit enter. This
will quit without saving the changes to the file.
Lesson 22 – The EMAC editor
Let's now learn about the most popular editor that is bundled with all Linux distributions, which is known
as the EMAC editor. The EMAC editor includes a mail reader and a psychiatrist application. This is the
most advanced editor available for the Unix or Linux environment.
Let us open a new shell terminal and let us do a RPM –q emacs. Note that the emac editor belongs to the
package named emacs-21.2. If we run the which emacs command, we can note that the emacs is available
within the /USR/BIN directory.
To launch the EMAC editor, click open the Red Hat start menu, point over Programming item and choose
EMAC. This will launch the Emac editor in GUI interface as we are running in the Gnome windows
environment. However, Emac can also be launched in non-GUI mode, that is in a shell window like the VI
editor. Thus EMAC supports both GUI and Shell interface.
Within the EMAC window, we can see the menu items on the top which are referred as wrappers. If we
click on these items, the command items are dropped down. These area is referred as menu bar in
Windows. The navigation within the EMAC editor is by using the arrow keys. Ctrl+E takes to the end of
the line. Ctrl+A takes to the beginning of the line. We can also point on a particular area using the mouse
and that area becomes the active cursor point. We can also drag and highlight particular area using the
mouse. To insert a blank line, place the cursor where you want the line to be inserted and hit enter. Hitting
enter multiple times will add multiple lines. To cancel a previous action, do a Ctrl+X and then press the U
key. This will undo the previous command. To delete entire line, use the Ctrl+K key combination. The
content that we deleted using the Ctrl+K command can be pasted anywhere in the file by placing the
cursor in the required place and then using the Ctrl+Y keys.
Now we will learn some features about the Emac editor. EMAC by default saves the original file by
appending the file name with a tilde symbol. For example we will open the file emactest.sh from the /root
directory and will check this feature. From the file menu choose 'Open Directory' at the bottom command
panel, type /root and hit enter. In the directory list navigate and highlight on the emactest.sh file and hit
enter. This will open the file within EMAC. Now we will do some modification and after this we will
choose 'Save current buffer' from the file menu. Open a new terminal window and if do a LS –L emactest*
we can find two files. One file ending with tilde is the original file and the modified file is the one that
appears as emactest.sh.
Now let's learn how to search within the emactest file. With the file opened in EMAC editor, press the
Ctrl+S keys. Type any search string for example LDAP and you can see the LDAP entries within the file
are all highlighted.
Lesson 23 – The EMAC editor - II
Having learnt about the basic features of the EMAC editor, let's now learn about some of the other
features available within this editor.
Within the EMAC editor if we click the buffers item in the menu bar or the wrapper bar, we can see all the
open buffers or files. In Windows applications this is similar to the windows menu. Choosing any item
from this buffers menu will change focus to that file or buffer.
If we click on the tools menu we can see the 'Search Files' option which can be used as a search utility. By
choosing the 'Shell Command' option we can run any shell command from within the EMAC editor. Next
we have the 'Debugger' command which is very helpful for the programmers. We can also find commands
to run spell check, compare and merge actions. Down under these options, we also have a Version control
utility. We can also read and send mail using the 'Read mail' and 'Send Mail' options available here. Next
we also have the options for 'directory search', 'display speedbar' and we can also launch the calender
utility by choosing the 'Display calender' option. At the bottom last we have a menu for games that
contains some simple games for entertainment.
Under the file menu, we have some important and commonly used options. Some well known options are
'open file', 'open directory', 'close buffer'. The 'save current buffer' option will save the current working
file. The 'save buffer as' option will save the file in a different name. This is equivalent to the save as
option in Windows applications. The, 'print buffer' option is used to print the file content.
Under the edit menu, we have some common tasks like undo, cut, copy, paste etc., We also have the
option to change the text properties here. We can also set a lot of customization using the commands
available within the options menu. Under the help menu we have options to get help about the EMAC
editor. Down below in the help menu we have a link to launch the EMAC Psychiatrist. If we select this,
the psychiatrist application is launched and if we type some thing, the psychiatrist will start asking
questions.
Thus the EMAC editor is a comprehensive application that is designed to perform multiple tasks within a
single window.
LINUX Advanced Tools
Lesson 24 - Identify Linux utilities / Package membership
In this lesson we will be discussing about the Linux packages in detail. One thing which we need to
remember is in Linux all the utilities, applications, commands and tools are available as RPM packages.
Though some of the third party applications and tools are available in TAR or GZ format, most of the
applications, tools are shipped in RPM package format. The RPM package as the term specifies is packed
with one or more tools or utilities.
In Linux most of the basic tools are available within a package called coreutils. Let us open a shell
window to learn more about how to query a RPM package. In the shell window, we can enter the
command rpm –qi coreutils and hit enter. This will display the query result for the COREUTILS package.
We can see the detailed information about this COREUTILS package. Most of the common utilities like
the LS, CP, MV, CAT, ENV etc., available within the BIN directory are members of this single package.
To identify package membership of a particular tool or command, for example to identify the package to
which the LS command belongs, we can run the command rpm –qf /bin/ls. This will show the result that it
belongs to the Coreutils package.
To identify the package to which the CP command belongs, if we run the command rpm –qf /bin/cp. This
will also show the result that it belongs to the Coreutils package.
Likewise if we run the command rpm –qf /bin/grep to identify membership of the GREP command, we
can notice that this is the member of the grep RPM package.
Thus we need to understand that every command, utility, application forms part of a RPM package and
these commands, utilities or applications are available only when that particular RPM package is installed
in the Linux system.
Lesson 25 – Redirection tools
In this lesson, we will be learning about the redirection options available within the Linux environment.
Before learning about the redirection concept, we need to first be familiar with two terms namely the
standard-in and the standard-out. Standard-in refers to the default input system we use, which is the
keyboard and standard-out refers to the default output device set in the system, which is the monitor. By
default the Linux system is set to receive inputs through the standard-in device which is the keyboard and
output the results to the standard-out device which is the monitor. Linux allows us to change the default
standard-in and standard-out settings and this is where redirection comes into picture.
For example, if we run the LS command by default the result is displayed in the monitor, which is the
standard-out device. It is possible to redirect the output of the LS command to a file or a printer. To do this
enter the command LS followed by the redirect symbol which is the greater than symbol '>' followed by
the file name where we want the results to be saved, for example redir_out and hit enter. Now if we do a
LS –L we can see a new file created with the name REDIR_OUT. To verify the content of this file, just do
a CAT followed by the file name which is redir_out. We can now see that the LS result that we see in the
monitor is saved on to this file.
We can now learn about the redirecting the standard-in. Let us illustrate this using the CAT command. In
the shell prompt if we type CAT and hit enter notice that the shell interface awaits input from the
standard-in which is the keyboard. If we type something using the keyboard for example, if we type
testing standard in and hit enter the cat command just echoes back the same text. If we hit enter to insert a
blank line the CAT utility also returns a blank line. This is the function of the standard-in. Now we will
use the CAT command and redirect the input from a file. When we do this the CAT utility should not
await for keyboard input and instead it should echo back the content of the file which we specify as
standard-in. We will enter CAT followed by the lesser than symbol '<' which is the indicator for
redirecting standard-in followed by the file name, for example the redir_out. Now hit enter. Notice that the
CAT utility just echoes the content of the redir_out file on the screen.
Thus redirection tools help in effectively interfacing with the bash shell environment.
Lesson 26 – System Monitoring tools - I
In this lesson, we will be learning about some of the basic tools that help us in monitoring and
administering the Linux system. The Red Hat Linux is bundled with many such tools that makes the
administration task much easier for the Linux administrator. Let's discuss about these tools one by one.
First we will open a new bash shell window. We will first learn about the UPTIME command. This utility
is used to find the total time the system has been up and running. Type Uptime and hit enter. This will
return the results as we see here. The results will show the current time, the Uptime, number of users
connected to the system and the load average data in three averages, namely one minute, five minute and
fifteen minutes.
Next we will use the CAT command to find some details related to system memory. Type CAT
/PROC/MEMINFO and hit enter. This will return the complete memory details of the system. We can
monitor the total memory installed in the system, memory used, memory that is freely available, buffered
memory and cached memory details. In the second row, we also have the SWAP memory details. As we
must remember the Linux installation creates a SWAP partition that is twice the size of the physical
memory installed in the system. We can see a plenty of memory related static information here though
these details are not dynamic or changing.
We can also use the FREE command to display the memory information of the system. Let's clear the
screen, type FREE and hit enter. Notice that the results were the first two lines of the results that we got
when we ran the CAT /PROC/MEMINFO earlier. The free command displays the physical memory
statistics and Swap memory statistics. This is the utility that is useful to ascertain the memory usage of the
system.
In the same manner, if we type CAT /PROC/CPUINFO and hit enter, we can see that the processor related
information are all returned. From the results returned, we can see the complete information about the
processor, like Vendor ID, CPU Family, Model name, CPU MHZ, cache size etc., using this utility.
Thus we are now familiar with some of the basic tools to monitor the memory and CPU information. We
would be discussing about some more tools in the coming sessions.
Lesson 27 – System Monitoring tools - II
In this lesson, we will be learning about some additional tools and options available for system
monitoring.
We have discussed earlier about the FREE and CAT commands to display the memory and CPU details.
Those results were all static results. By static results, we mean that the data is accurate only at the point
when we ran the command and the results would vary if we run the command again. This means the Free
or Cat command never display dynamic information about the memory or CPU info. There is another
utility which is known as WATCH that can be used along with any other command to return dynamic
information. WATCH utility runs the command recursively every 2 seconds and refreshes the screen with
the latest information, thereby providing real time dynamic data.
Let us check this. Type WATCH FREE and hit enter. You can see that the memory information that is
displayed is no more static and it changes every 2 seconds. This is how the WATCH utility functions. As
this system is not heavily used, we do not see much of the change in the memory utilization.
Another utility which is frequently used by the Unix or Linux administrators is the TOP command. Let's
clear the screen. Type TOP and hit enter and notice the results. This utility returns a combination of
UPTIME data, the memory information, information about the processes etc., You can see from the
results, the total processes, number of processes sleeping and number of processes running, the processes
in zombie state and processes that are stopped. We can also see the physical and swap memory
information. Below the memory information we can see the detailed information about every process in a
tabular format. We can see the PID which is the process ID, the user who is running the process, the size,
CPU and memory utilization of the process, the status of the process, R indicates that the process is
running, S indicates that the process is in sleep status. We also have the name of the process at the end of
the line. We can see that even the TOP command which we are currently running is shown as a process.
One more thing to note is that the TOP command provides dynamic information that keeps changing. To
quit out of the TOP utility, press the Q key and we will return the shell prompt.
The next tool or command which we will be discussing is the VMSTAT. Type vmstat and it enter. Notice
the results shown. This command returns lot of information about the processes, physical memory, swap
memory, IO, System and CPU related information. These details provide sufficient insight for the Linux
administrators. Though these details are not static, it helps to identify the statistics at a given point of time.
If we go through the results, we can see that under processes column we have the R B and W columns. R
indicates the processes run, B indicates the processes that are in uninterruptible sweep stage and W
indicates the processes waiting to be run. We can also see the swap, free, buffered and cache memory
details, details pertaining to IO and system. We also have the CPU information. The last column ID under
CPU section indicates the processor utilization.
Lesson 28 – GNOME System Monitor
Having discussed about some of the text based utilities, we will now start discussing about the GNOME
system monitor utility. This is a graphical User Interface version of the TOP utility.
We can launch this utility from the GNOME desktop environment as this is a GUI utility. Click on the
Red Hat icon and from the menu that opens, point on System Utilities and choose SYSTEM MONITOR.
This will launch the Gnome System monitor GUI utility. As we can see this resembles the Task manager
utility available in Windows. We have two tabs in this utility namely the 'Process Listing' and 'System
Monitor'. The Process Listing tab will show all the process related information such as process name,
User, memory and CPU utilization, as well as the process ID. The details are same as reported by the Top
utility but in a GUI interface. If we click the down arrow next to the View option, we can choose either to
show all processes or user specific processes that are being run. We can also select a particular process
and if we right-click we get options to change priority, end process, kill process or hide process. End or
kill process options would terminate the particular process. If we choose the change priority option, we get
a dialogue box with a slider wherein we can change the priority level of the process. This is the same as
we find in the task manager of Windows.
The next tab is the 'System Monitor' tab and if we select this, on the top we can find the CPU utilization
graph that shows the CPU utilization levels and below that we can see the graphical view of physical and
swap memory utilization. The Red line indicates the physical memory utilization and the green line
indicates the swap memory utilization details. We can click the color palate in the CPU and memory
section and from the window that appears, we can change or fine tune the colors that appear in the
graphical view. Below this section we have the devices section that shows the hard drive partitions.
Thus the Gnome system panel will serve as an all-in-one place for the GUI lovers.
Lesson 29 – File Archival tool - TAR
In this lesson, we will be learning about the file archival and compression tools. There are two tools
available in Linux for these tasks, namely the TAR utility and the GZIP utility. As most of the upgrades
and tools are available in tar and gzip format one must know how to use these utilities to unpack and
decompress these files.
Now, let's move on learning about the TAR utility. This utility is used commonly in Unix or Linux
environment and this is a simple file archival tool. This utility rolls several files and directories into a
single tar archive. For illustrating this feature first we need to create a directory and move some files on to
it. Let us create a new directory named TAR using the command MKDIR TAR. Now we will move the
test files to this directory using the command MV testfile* tar/. Now if we LS –L TAR/ to list the content
of the TAR directory we can see that the three testfiles are moved on to this directory. Now we will create
a tar archive that will contain the TAR directory and its contents. Enter the command TAR followed by
the options –CVF then the file name of the new tar archive which is test.tar and then the source path for
the tar archive which is TAR/. The options C is to create, V is for verbose mode and F is for file mode.
Now hit enter. This will create the tar archive named test.tar within the working directory with the
contents of the TAR/ directory. If we do a LS –L we can see the newly created tar archive. We can see
that the LS command indicates the tar file with a different color. It is also possible to display the content
of the TAR file. This is done by the command TAR –tvf and then the name of the tar file. We will enter
TAR –TVF test.tar and hit enter. This will open the tar and display the contents of this tar archive.
In the next lesson we will learn about compressing the tar ball file in gzip format.
Lesson 30 – File Archival tool - GZIP
We have so far seen the steps to roll several files and directories into a single TAR archive and the TAR
archive so created is not compressed. TAR just rolls these several files and directories into a single TAR
ball file. To compress the TAR archive, we need to use a tool like GZIP. The Gzip utility supports
compression. We can also modify the TAR syntax so that the tar archive will be created and then
compressed using the Gzip utility. To do this enter the command TAR –cvzf test.tar.gz tar/. The additional
option Z is entered to enable compression and the .GZ that is appended to the file name makes the tar
utility to use the Gzip tool to compress the file. When we hit enter, the test.tar.gz file is created in the
working directory. If we do a LS –L we can find two files test.tar which is the uncompressed tar file
created earlier and the test.tar.gz which is the new compressed file we created now. Notice the size
difference between these two files. This is due to the compression feature of the gzip utility.
Most of the Linux utilities and updates are available in the internet in tarred gzip format. This means the
files are compressed and rolled as tarball and the files may end with filename.tar.gz which is the most
common standard or it may end with .tgz or .gz or .z. All these files are readable by the gzip utility.
Now we will learn how to extract the files from the tar and gz files. Before doing this we need to first
remove the TAR/ directory as this will be recreated from the TAR and GZ archives. Enter rm –rf tar/ and
hit enter. This will remove the TAR/ directory. Enter the command TAR –XVF TEST.TAR and hit enter.
If we do a LS –L we can see the TAR/ directory again and if we do a LS –L TAR/ we can see the files
within this directory. We will now remove the TAR/ directory again using the command rm –rf tar/ and
will extract this from the test.tar.gz file. Enter the command TAR –XZVF test.tar.gz and hit enter. Now if
we do a LS –L, we can see the TAR/ directory is again created and this time it is extracted from the gzip
file.
We can also use the gzip utility separately to uncompress the file. We will illustrate this. First let us delete
the test.tar file available in this directory, as this file will be recreated from the gz file. Enter rm –rf test.tar
and hit enter. If we do a LS –L we can see that this file is gone. Now enter gzip –d test.tar.gz. If we do LS
–L again we can see that the test.tar.gz file is removed and the test.tar file is recreated.
Lesson 31 – File System tools
In this lesson we will see about some of the file system tools available within the Linux system.
The first and foremost tool which we will be learning would be the FDISK utility. We shall open a new
shell window. Type FDISK –L and hit enter. We will get the file system related information. We can see
the Capacity of the hard drive which is 32.2 GB. The heads, tracks and cylinders info can be found in the
next line.
Down below in the three rows we can see the hard drive partition information. Every hard drive partition
is referred as /dev/sda1 sda2 and sda3. SDA1 is the boot partition which is 100MB in size, next the SDA2
is the root partition and SDA3 is the swap partition that is normally twice the size of the system physical
memory. When you use a IDE or SATA hard drive in the system, the partitions are referred as HDA1,
HDA2 and HDA3. As we are using a SCSI hard drive, Linux refers the partitions as SDA instead of HDA.
In the partition information we can find a column that refers Partition ID detail. We can see that this ID is
83 for the boot and root partition and it is 82 for the SWAP partition. Always remember that partition with
ID 83 is alone accessible by users. If the ID is 82 then it means that it is not user accessible. Here the
Swap partition ID is 82 and this is used only by the system.
If you wish to make changes to the partition table, just enter FDISK /dev/sda. If you are using a IDE or
EIDE hard disk, then you need to enter FIDSK /dev/hda.
One more details which every Linux user should keep in mind, is that the partitions in Linux are formatted
with the EXT version 3 file system. Version 3 is the latest version available in the EXT file system.
The next tool which can display partition related information is the disk full command. Just enter DF and
hit enter. This will display all partitions except the swap partition. Additionally if there are any CD-ROM
or floppy disk mounted or if there is a SAMBA share connected, the DF utility will show these devices as
well. To display the swap partition you need to enter FDISK –L command as this will not be shown in the
DF command. In the DF results, you can see the partition name, the space utilized, space available,
percentage of utilization and the directory where the partition is mounted. We can see that the boot
partition is mounted to /boot directory the root partition is mounted to the root of the directory structure. If
we enter DF –h and hit enter this will show the details in human readable format, that is the partition size
would be shown in GB and MB instead of Kilobytes, which is easier to understand.
Thus the FDISK and Disk Full utilities are the tools available in Linux to list and modify hard drive
partition information.
Lesson 32 – File types and permissions
In this lesson we will learn about various file types available in Linux and the permissions.
It is very important to know how to identify the type of a particular file before working. Easy method to
identify the file type is using the color coding in the shell terminal window. If we do a LS we can see that
all directories are colored blue, the files are colored black and executable binaries and scripts are colored
in green. We will first LS –l the /root directory. Notice that the emactest.sh is colored as green because it
ends with sh and linux considers this as a shell script file. The other log files are shown in black and the
directories are shown in blue. We shall change to the /bin directory using cd /bin command. Now do a LS
–L and notice that the binaries are shown in green. We can also see some files with acqua blue in color
and these are known as symbolic links. These files are links to other binary or executable files. We can see
that the VIEW is a symbolic link to the VI editor executable file.
Apart from the color coding, we also have a ten bit system using which we can identify the file type and
the permissions assigned to that item either a file or link or a directory. Let us get back to the /root
directory. We will do a LS –L of this directory. We shall learn this using the TEMP directory shown in the
LS result. Notice the ten bit string which appears in the beginning of the line. the first bit of this 10 bit
string denotes the file type. D indicates that this is a directory and the rest 9 bits rwx rwx rwx indicates
permission levels assigned. The first three bits of 9 bits rwx is the permission for the owner of this folder
which is root, the second 3 bits rwx is permission for the group and the last 3 bits rwx is permission for the
everyone group. For this TEMP folder the permissions are set to Read Write Execute for the owner, group
as well as for everyone. For the SAMBA directory, we can see some dashes in the 9 bit string. This
indicates the write permissions are denied for the group and everyone. Thus we can decipher the
permissions for a file or directory.
Coming back to file types, we already know that if D is in the first bit it indicates a directory. If a dash or
hyphen is in the first bit it indicates that it is a file. You can see that for all the log files in the LS result we
have a dash in the first bit, as these are all log files.
Let us get back to the /bin directory and do a LS –L again. Notice that there is a dash for all executable
files. Also Notice that there is L in the first bit of some files that show as acqua blue color. These are
symbolic links which are links to other executable files. So keep in mind that the first bit for a symbolic
link is always a letter L. The symbolic link works in the same way a shortcut works in a windows
environment.
Now we will learn how to modify the permissions to files or directories in Linux. We can minimize the
shell window, and we will open the ROOT's Home from the GNOME desktop. We will select the
SAMBA directory, right-click and choose properties. Here in the properties dialogue, we can see a
permissions tab. Select this tab and we can see the permissions granted in this directory for the owner,
group and others. Notice that the Write permission is denied to Group and Others. We can make the
required permission changes here and click OK to apply the permissions. This is how we can modify
permissions.
Lesson 33 – Mounting devices - I
In this lesson we will learn how to mount volumes and removable devices in Linux.
First thing that we need to remember is that for any device to be accessible in Linux, it must be mounted.
As we have seen earlier even the hard drive partitions are permanently mounted to specific directories and
hence they are accessible. In the same way the floppy diskettes and CD-ROM Media needs to be mounted
for being accessible by users. Primarily we will be learning about the two commands mount and umount.
Let's open a shell window and type mount and hit enter. This will show all mounted devices. Currently we
can see from the results, that this shows only the hard drive partitions as mounted devices. Umount will do
the reverse function, that is this command will unmount the devices specified. If we run a which command
for the mount or umount, we can find from the result, that these tools are available within the /bin
directory as these are essential tools that needs to be accessed by all users. If we do a RPM query using the
command RPM –QF /bin/mount we can find that this belongs to the mount-2.11 RPM package. The
Umount is also part of the same package.
Now if we run the command CD / this will take us to the root of the directory structure. If we do a LS we
can see a MNT directory. If we do a LS /MNT we can see two sub-directories namely CDROM and
FLOPPY. These two directories are the temporary mount locations for the CD-ROM and Floppy drives.
The optical drives such as CD-ROM is mounted to the CD-ROM directory and floppy drives are mounted
to the FLOPPY directory.
Let's now learn about mounting a floppy disk. The requirement is there must be floppy disk drive
physically installed in the Linux box. In the Shell window, type the command MOUNT /DEV/FD0. We
are entering /DEV/FD0 because every physical device is represented as a file within the /DEV directory.
Hitting enter will mount the device. Now if we run the command DF –H this will show that the floppy
disk is mounted to the /MNT/FLOPPY directory. The floppy diskette contents can be accessed from this
directory.
Lesson 34 – Mounting devices - II
Let's now learn some details about the file system format of the floppy diskettes in Linux. The Linux
operating system is capable of reading floppy media that is formatted using the Native EXT2 file system
or the DOS FAT file system. Diskettes formatted in other file systems are not readable. We shall now
learn how to format a floppy media. Before formatting a floppy disk we need to unmount the device if it is
already mounted. When the device is mounted the floppy formatter utility throws an error message. Hence
we need to unmount the device before proceeding with a format. To unmount the device, type UMOUNT
/MNT/FLOPPY/ and hit enter. This will unmount the device. If we do a DF –H, we can see that the floppy
drive is not available. We shall minimize the shell window. Click on the Red Hat start menu, point on
System Tools and select Floppy Formatter item. This will open the floppy formatter GUI tool. This is the
tool available for formatting the floppy diskette within Red Hat Linux. In the File System type field, we
can select from the two available options, either the native file system EXT2 or the DOS FAT file system.
In the Volume name we can enter a name. In the formatting mode section, we have three options, Quick,
Standard and Thorough. Select one option and click the Format button to start the disk format.
Let us move on to the process of mounting a CD-ROM drive. If we insert a CD-ROM disk in Red Hat 9, it
is automatically mounted. For example, I have inserted the first CD of the Red Hat 9 installation kit and
see what happens, the CD is read automatically and we can see a prompt that asks if we wish to run the
autorun utility. We can also see that the Nautilus File manager window opens the contents of the CD-
ROM. We will close the File manager window. If we answer yes for the autorun prompt, this will open the
Package Management utility. We will close the package management window. The auto mount feature
works only when the disk is inserted into the CD-ROM drive. We will open a shell window and to
unmount the CD-ROM media, we will type UMOUNT /DEV/CDROM and hit enter. We will now run a
DF –H and note that the CD-ROM device is unmounted and no longer shown as mounted. For manually
mounting the CD-ROM, enter the command MOUNT /DEV/CDROM and hit enter. If we run a DF –H
again we can see that the optical drive is available mounted again. The contents of the CDROM can be
accessed from the /MNT/CDROM directory.
RedHat LINUX Installation
Lesson 35 – Software/Hardware Requirements
In this lesson we will learn about the software hardware requirements for installing the Red Hat 9 Linux
distribution.
A Pentium class processor is the minimum requirement for Red Hat installation. For the Text mode
operation a 200 Mhz Pentium class processor is recommended and for graphics mode a 400 Mhz Pentium
II is recommended.
As far as the memory requirement, Minimum RAM recommended for text mode is 64MB. For graphical
mode the minimum required RAM is 128MB and the recommended RAM is 192MB.
There are four ways to install the Red Hat Linux 9. We choose either a custom installation, Personal
Desktop installation, Workstation installation or Server based installation. Every installation type has its
own Hard Drive space requirement.
The minimum required HDD space for a Custom Installation of Red Hat is 475MB and it can go up to
5GB if all the components are installed. However, if the Personal Desktop Edition or the Workstation
edition is installed, you need at least 1.7GB of HDD space. The Server based installation needs 850 MB of
hard drive space.
Upgrading from 8 to 9 requires at least 2GBs of disk space because of the included utilities and graphical
tools.
Lesson 36 –Linux Disk Partitioning
In this lesson we will discuss about the partition structure in the Red Hat Linux operating system. We will
be using the Hardware Browser GUI utility of Red Hat Linux to check this.
To launch this utility, click on the Red Hat icon on the left corner of the GNOME desktop. Point on
System Tools and then click on Hardware Browser item. This will launch the Hardware Browser GUI
utility. Select the Hard Drives item in the left pane of the Hardware Browser window. This will reveal the
hard drive partitions in the right side of this window.
The partition structure which we see here is the result of choosing 'Automatic Partition' option during the
Red Hat 9 installation process. We can customize this partitioning structure by choosing the 'Manual
partition' during installation. This will launch the Disk Druid utility using which we would be able to
customize the size of the hard drive partitions that would be created during the installation. Discussion
about the Disk Druid utility is not within the scope of this tutorial. We would only be learning about the
partition structure that is created when using the 'Automatic Partition' option of Red Hat 9 installation and
this is what we are seeing here in this lesson.
We can see that there are three partitions available which are named as SDA1, SDA2 and SDA3 under the
Device column. Red Hat Linux identifies each partition as separate device. We have three partitions and
thus three devices are listed here.
Note that the SDA1 is the boot partition that is of 102MB size. The Red Hat documentation refers this
boot partition size as 100MB, but in actual the boot partition size varies around 100MB. SDA3 is the
SWAP partition that is normally twice the size of the system memory and in our case this partition is of
377MB size. The balance of hard drive space is partitioned as the SDA2 which is the ROOT partition.
This is how the hard drive gets partitioned when choosing Automatic Partition option when installing the
Red Hat Linux 9 system.
Lesson 37 – Types of RedHat Linux Installations
The Personal Desktop type of installation with the default GNOME desktop environment will need hard
drive space of 1.7Gigs. 1.8Gigs would be needed if we choose the KDE environment that includes the
Open Office Suite along with web browsing and other tools. The KDE is required for a productivity user.
The Personal Desktop type is recommended when installing Linux as a stand alone system.
The Workstation type installation will need 2.1 Gigs of hard drive space. This installation type is
recommended when installing the Linux box as a workstation within a networked environment.
The server type installation will need hard drive space between 850MBs to 5GBs depending on the
options selected. This type of installation is recommended when we plan to run the Linux box as a server
that hosts some network services in a networked environment.
The Custom type of installation will need between 450Megabytes all the way up to 5 Gigabytes of hard
drive space. This option can be chosen, when we need to choose features that fall in more than one type,
for example, we may need to install some workstation and personal desktop features, as well as some of
the server based utilities.
Lesson 38 – Upgrading from RedHat 8
In this lesson we will be discussing about the steps to upgrade to Red Hat 9 when you have an earlier
version already installed in the system.
In order to upgrade to RedHat 9, you need to have atleast RedHat version 6.2. This is because RedHat 9
requires RPM support and this RPM support is available only in Linux Kernels that shipped from RedHat
Linux 6.2 and above.
Now we will learn the step to first verify the current version.
To verify the current version:
1. Right-click on the GNOME desktop and choose the new terminal option.
2. This will launch a new Terminal window.
3. Now type the command cat /etc/redhat-release.
4. We can see that the result is displayed in next line as Red Hat Release 9. Currently we have Red
Hat 9 already installed in this system and assuming this to be Release 8 we will be going through
the upgrade process.
During the installation, the installer will search for the /etc/redhat-release file to decide on the currently
installed version.
To start the upgrade process insert the first CD of the Red Hat 9 Installation kit in the CD or DVD-ROM
drive. Then we need to reboot the Linux system by choosing Logout option from the Red Hat menu. In the
Logout window, choose the 'Restart the Computer' option. This will shut down all the daemons or services
that are running and will restart the system.
To ensure that the system boots through the optical drive that has the Red Hat Installation CD, we need to
invoke the boot menu of the BIOS using the Escape key. This hot key used to invoke the BIOS boot menu
may differ according to the BIOS manufacturer. You need to check your system documentation to know
this hot key. Now we will select the optical drive and hit enter. The system will boot through the Red Hat
9 CD and the installer will start the Anaconda installer engine. The initial screen prompts for additional
parameters that is passed on to the anaconda installer. These additional parameters needs to be entered
when we need to install Linux in text mode or when we need to apply updates that we have obtained from
Linux distributors. When you do not enter any additional parameters in this screen, the installer defaults to
the normal installation. In the next process, all the hardware is initialized. The next screen provides
options to perform a media check. Media check provides an opportunity to check the integrity of the
installation media as well as to ensure that the data contained in the installation media is not tampered or
corrupted. This helps us to avoid incomplete or unsuccessful installations. We will not perform a media
check here and this process is discussed in detail in the forthcoming lessons that deal with a clean install
of Red Hat 9. For now we will skip this Media check process by choosing the SKIP option. Now the
installer initializes the Graphic User Interface portion of the installation.
In the introductory screen click Next.
In the next screen, choose the language that will be used during installation.
In the next screen, choose the keyboard layout type.
Choose the Mouse type in the next screen.
The next screen is the Upgrade Examine screen, where we can see two options;
"Perform an upgrade of an existing installation" and
"Perform a new RedHat Linux Installation".
Keep in mind, to perform an upgrade the first option needs to be chosen and this is the option that is
selected by default, when we have an existing Linux installation in the system. We can also see that the
installer has identified and listed the existing version of Red Hat Linux 9. As we already have the 9
release, this is shown here in this screen. To continue with the upgrade, click on the Next button.
The next screen will provide options to update the GRUB boot loader. In this screen we have the choice to
update the bootloader or skip the update or choose a third party boot loader configuration. If you really
upgrade from a older version, it is recommended to choose the first option to upgrade the boot loader
configuration. As we already have a Red Hat Linux 9 version, we will choose the second option to skip
this process. Choosing next in this screen will check and compare all the packages installed in the
previous version to the new version. After this process the next screen "About to Upgrade" appears.
Clicking Next at this stage will start transferring the installation image to the hard drive and will start the
packages installation. The installer will prompt for the next CDs and will continue installing packages
from the other CDs.
The rest of the upgrade procedure is the same as it happens when performing a clean or new installation of
Red Hat Linux 9. Hence we will not be seeing the complete installation process in this lesson. The
complete installation procedure is discussed in the forthcoming lessons that deals with the CD based fresh
installation.
Lesson 39 – RedHat 9 CD based installation - I
In this lesson we will be focussing on the CD based Personal Desktop installation of RedHat Linux 9.
To start the CD based install, we need to ensure that the first CD of the Red Hat 9 Installation kit is
inserted in the CD or DVD-ROM drive. We also need to ensure that this CD/DVD-ROM drive is set as
the first boot device in the boot order of BIOS.
Now restart the system will cause the system to boot through the Red Hat 9 CD and the installer will start
the Anaconda installer engine.
The first screen is the initial boot menu screen which prompts for additional parameters that is passed on
to the anaconda installer. These additional parameters needs to be entered when we need to install Linux
in text mode or when we need to apply updates that we have obtained from Linux distributors. This screen
await user input for a particular time and when you dont enter any additional parameters in this screen, the
installer starts the default installation. Pressing enter without entering additional parameters will also start
the default installation.
In the next process, all the hardware is initialized and some of essential hardware drivers and installed.
The next screen provides options to perform a media check. In the Media check screen we have two
options, OK and SKIP. Choose OK in this screen. This will start the media check process. Choosing the
SKIP option will skip the media check process. Media check provides an opportunity to check the
integrity of the installation media as well as to ensure that the data contained in the installation media is
not tampered or corrupted. This helps us to avoid incomplete or unsuccessful installations. After the media
check process is complete we can either proceed checking the other media or continue the installation by
choosing the Continue option. We will select the continue option.
Now we can see the Anaconda installer status in the bottom lines of the screen. Anaconda at this stage
detects and installs the Video card, Monitor and the Mouse hardware installed in the system. After this
hardware detection process is complete, anaconda starts the Graphical User Interface portion of the Linux
installation.
In the introductory screen, the left portion has the help information that will be useful throughout the
installation process. After reading out this help information, click Next.
In the next screen, we can choose the language that will be used during installation. The default selection
is English. Linux installer supports many other languages as well, as we can see from this list. With the
language option chose, click Next.
In the next screen, we have option to choose the keyboard layout type. Linux supports many of the
standard keyboard layouts used around the world. Choose the keyboard and choose Next.
Choose the Mouse type in the next screen.
Now we can see that the installer checks for any existing previous installations.
The next screen is where we have options to choose the types of installation like Personal Desktop,
Workstation, Server, Custom. Choose the installation type which is Personal Desktop and click Next.
Next is the Disk Partitioning Setup screen. This screen provides two options namely "Automatically
partition" and "Manually partition with Disk Druid". Disk Druid is a partitioning utility like FDISK which
can be used to partition manually instead of choosing the Automatically Partition option.
When the first option "Automatically Partition" is chosen, three primary partitions are created. First
partition is a /BOOT partition of 100MegaBytes in size. Next is the SWAP partition which is twice the
size of the system memory. Third one is the ROOT partition identified by a forward slash and contains all
the sub-directories of the Linux file system. This root partition contains the remainder of the hard drive
space. For example, if we install Linux in a system that has a 40GB hard drive and 512MB of RAM,
100MB is reserved for the BOOT partition, the SWAP partition takes 1Gig of space which is equal to
twice of the 512MB RAM and the rest of the hard drive space is allocated to the ROOT partition. After
selecting the Automatically Partition option, choose Next.
Next we can see the prompt that warns us that the partition needs to initialized and when doing so, the data
in the drive would be erased. We shall click Yes in this prompt.
In the next screen we get some of the very important options to control the Linux partitions. We have
three options here; namely
- Remove All Linux Partitions on this System
- Remove all partitions
- Keep all partitions and use existing free space
The first option Remove All Linux Partitions on this System removes only the existing LINUX partitions
and does not touch any other Windows based partitions like FAT16, FAT32 or NTFS. The second option
Remove all Partitions removes all the existing partitions including the windows partitions if any. The third
partition ignores the existing partitions and makes use of the unpartitioned free space available in the
system.
Review and Modify if needed the partitions Created option which is at the bottom of this screen is another
important option. This option when selected will let us customize or modify the default Linux partitioning
system. In other words, check this option if we want to modify the partitioning structure other than the
default 3 partitioning done by the Linux automatic partitioning system. Choosing this option will initiate
the Disk Druid utility using which we can modify the partitioning system. Here we are not going to use
this option and we will leave this unchecked. Click Next.
Lesson 40 – Red Hat 9 CD based installation - II
Now we can see a warning screen that warns about the partition removal. At this stage, if you want to
back out click NO. Click OK to continue the partition process.
Next we get the boot loader configuration screen. GRUB known as the Grand Unified Boot Loader is the
default boot loader for Red Hat 8 or 9. GRUB is an advanced boot loader and is more customizable than
other boot loaders. Another point to highlight is that we can set a boot loader password using the "Set a
boot loader password" option in this screen. This adds security to the master boot record. GRUB is
capable of booting any operating system and supports multiple boot options. With the default setting
chosen, click Next.
Next screen in the installation is the Network Configuration screen. We can set the configuration for
network devices here. We can choose the IP address, Host name settings either manually or the DHCP
option. We can also choose the DNS settings in this screen. Choose Next.
Next we have the Firewall Configuration screen where we have options to customize or set the firewall
options for the system. Default selection is Medium. We will choose the No Firewall option and click
Next.
The next screen is where we can add support for additional languages like we add in a Windows system.
This will allow us to interface the system using additional languages other than the default language which
is English. After choosing the additional languages that are needed, click Next to proceed with the
installation.
In the next screen we can enter the time zone settings. Here we have two tabs namely, the Location tab
and the UTC offset tab. We can set the location by pointing the mouse over a location in the world map
graphic that is shown above or by selecting the location from the scroll window down here. We can also
set the time in the UTC offset tab. This tab consists of various UTC offset timing values. UTC is nothing
but the Greenwich mean time. All the values we see here are a plus or minus from the GMT. We will
proceed by clicking Next.
In the Next screen we have the Root password setup dialogue. This is where we setup the Password for the
Root. We will enter the password in the two fields to confirm it and click Next.
Next is the Personal Desktop defaults screen. This is the place where we can either accept the installation
of default applications listed above or we can customize the applications that we need. As we can see from
the list, the default applications include the GNOME desktop environment, the Open Office Suite which is
the Office suite for Linux, the Mozilla web browser, the Evolution email application, Instant Messaging
application, Sound/Video Applications and Games. For new users the default option which is "Accept the
current package list" is recommended. One point to note is that even when after installation is done with
this default option, the applications can be removed or added later using the REDHAT-CONFIG-
PACKAGES tool. If you are an advanced user and want to choose the applications that will be installed
during the Linux installation, choose the "Customize the set of packages to be installed" option. Here in
this video we are not going to customize the applications and we will accept the default applications list
and click on Next.
Next screen is the "About to Install" screen and this indicates the end point where the installer has
collected all the necessary information to perform the installation.
Lesson 41 – Red Hat 9 CD based installation - III
When we click Next in this screen, take a look at what happens. The installer formats the partitions and
builds the Linux partition that uses the EXT3 file system. This is the stage wherein the data contained in
the partitions that we chose earlier gets deleted or erased. This format process is the same like formatting a
NTFS partition with a quickformat option. Formatting process is very quick in a Linux environment.
After the Format is complete, the installer copies the CD image to the hard drive. We can see a progress
bar that shows the completion of this task. After the CD image transfer is complete, the installer performs
another process which is setting up the RPM Transactions that are necessary for the installation. Next the
package calculation is done and we can see lot of details about the installation in this screen. On the top
we have the detail about the current package name that is installed. The size of the package and the
summary of the package are listed below the name. Down below that we can see the package progress bar
that shows the progress of each package and then we also have the Total progress bar that shows the
progress of the complete installation.
Down below that we can see a tabular area, wherein we can see the details about the total number of
packages, number of packages that have completed installation, the remaining packages that are to be
installed, Total projected time for the entire installation, completed time and the remaining time. We can
now see that there a total of 518 packages that gets installed in a Personal Desktop type of installation.
We can also see the total projected time for the installation to complete. This time keeps varying
depending on the fluctuation that occurs in the bus speed of the CD-ROM and the hard drive. We can also
note that the total size of installation is shown as 1645M which is equal to 1.7Gigs as we have learnt
earlier and this is known as the footprint of RedHat Linux 9 for a Personal Desktop installation.
The installer is much faster as there are less number of packages that are to be installed in a Personal
Desktop type of installation. The installation is also faster when performing a new installation rather than
when doing an upgrade from the older edition. This is because, when doing a upgrade the installer takes
some time to compare the version of the installed packages with the currently available packages in the
install media and to make the actual upgrade of the packages that are old. In a new installation, the
packages are just installed directly to the new environment and there is no comparison of new to old
version of packages that really happens. This process is not necessary when doing a new installation and
hence the difference in time consumption is notable. This is the reason it is always recommended to go for
a new installation instead of an upgrade from an older version.
It is important to know that Linux is a bundle of packages and this is the basic structure of any Linux
distribution. Every distributor develops or collects and puts together the best set of available packages
together to form a Linux distribution along with the Linux Kernel. These packages are available in a BIN
format or as RPM package. Though we choose a particular type of installation from the installation type
screen, like a Personal Desktop installation, Linux allows us to remove or add packages later to suite our
needs. The Anaconda Installer that is currently installing the Linux operating system and packages is itself
a package that is designed to emulate the graphical user interface that we have been seeing throughout the
installation, to collect the data from the user and other installation options and to actually install all the
packages into the system.
Lesson 42 – Red Hat 9 CD based installation - IV
We see that the installation is still proceeding further. We can see that 72 packages have already been
installed and the remaining packages that needs to be installed shows as 446.
Down below we can see the Release Notes button which when clicked will launch the Release Notes for
the Red Hat Linux 9 edition. You can see a Hardware Requirements section on the top of this window. If
we scroll down we can see the CPU section that details the Minimum and Recommended CPU
requirements for Red Hat Linux Operating System. If we scroll down further we can see the next section
which is the Hard Disk Space Section that details the hard disk space required for various types of
installations. Next is the Memory section that provides information as to minimum and recommended
memory for text and Graphical modes of Red Hat Linux. If we scroll further down through this Release
Notes window, we can find lots and lots of useful information pertaining to the Red Hat Linux 9 release.
This information is very helpful to resolve some of the common issues that may occur during installation.
We can also find other Installation-Related notes in this window. After going through the release-notes
click Close button.
The Installation of packages from the first CD is still progressing and we are now able to see that over 100
packages are already installed. We can see that the installation is pretty fast and the reason is because we
are doing a first time clean install in the system. When doing an upgrade or when overwriting an existing
installation, we can see the installation is bit slow due to the reason that the installer is burdened with
additional process wherein the existing package is compared with the package that is going to be installed.
We will continue with the rest of the installation in the next video.
Lesson 43 – Red Hat 9 CD based installation - V
We see that the installation is still proceeding. We can see that 286 packages have completed installation
and the remaining packages to be installed shows as 232.
As the installation proceeds further, we shall discuss some of the important points of the RedHat Linux
system. We need to remember that the basic structure of the Linux system is the number of packages and
each package is in RPM format. Remember that each utility or feature of Linux is available as a separate
RPM package that is installed in the system. When we need an additional feature or when we do not need
one, we can later install or uninstall that particular RPM package from the Red Hat Linux operating
system. The RPM packages which are currently installed are all in compressed format in the CD image.
The Anaconda installer first decompresses these packages and then puts them in the right location in the
system during the installation.
It is important to look into some of the important packages that is installed from the first CD of the Red
Hat 9 kit. A total of 442 packages gets installed from the first CD. Notice the name of the packages as they
are getting installed one by one.
We will continue with the rest of the installation in the next video.
Lesson 44 – Red Hat 9 CD based installation - VI
After the packages contained in the first CD of the Red Hat 9 installation kit is complete, the installer
prompts for the second CD. Eject the first CD from the optical drive, insert the second CD and then click
OK.
The installation proceeds with the rest of packages that are available in the second CD. If we note it
carefully we can see that a total of 72 packages are installed from the second CD of the Red Hat 9
installation kit.
Some of the important packages that gets installed from the second CD includes;
- OpenOffice Suite which is a comprehensive office application built in with Red Hat.
- X-Free86 package that contains a set of tools needed for the X Windows environment.
- Evolution 1.2.2 which is the GNOME group ware suite for Linux.
- GNOME Game Set package that has some games for the GNOME desktop.
- MRPROJECT package that includes a project management application.
- XPDF package that installs the PDF Viewer for X-Windows environment.
- Packages for GNOME Display Management and GNOME Control Center.
- File-Roller Package which is used for creating archives.
- GEDIT package - a text editor for GNOME desktop.
- GFTP package which is a FTP client for X-Windows system.
Like this we can see a lot of packages that extend features for the GNOME, X-Windows system and KDE
environment of the Red Hat Linux operating system are installed into the system, during the installation.
We will continue with the rest of the installation in the next video.
Lesson 45 – Red Hat 9 CD based installation - VII
After the packages contained in the second CD of the Red Hat 9 installation kit are installed, the installer
prompts for the third CD. We can see that there is only one package that is still yet to be installed and this
is available only in third CD. Eject the second CD from the optical drive, insert the third CD and then
click OK. Note that MUTT1.4 is the only package that is left in the third CD for installation. This is the
package that provides text based mail client feature for Red Hat Linux.
After the packages are installed we can see an additional progress bar that states "performing post install
configuration". This is the stage when the packages are configured for use. Next is the Boot Diskette
Creation screen. This screen provides option to create a boot diskette that can be used for recovering the
operating system in case of crash. The boot diskette can either be created using the first option here or any
time after the installation as the boot image is available in the first CD of the Red Hat installation set.
Next is the Graphics Interface Configuration screen where we choose the video card hardware installed in
the system. In majority of situation, this screen will highlight the video card hardware that the installer
automatically detects. If this setting is wrong, we can choose the right hardware in this screen. Click Next
to proceed to the next screen which is the Monitor configuration screen. This screen like the previous
screen shows the detected monitor that is connected to the system and if this selection is wrong, we can
choose the right monitor hardware. We can also set the horizontal sync and vertical sync values in the
appropriate fields at appear at the bottom. These settings are very important for the Linux X windows
environment. Click Next.
The next screen allows us to customize or change the graphical configuration. This screen provides the
same options that we can see in the Display settings window in a Windows environment. We can set the
Color depth and Screen Resolution settings in this screen by click on the arrows next to these options and
selecting the appropriate values. After choosing the correct values, click Next.
Next screen is the installation complete screen, and clicking Exit will exit the installer and will restart the
system. After the system restarts, we can see that the GRUB boot loader launches and shows the RedHat
Linux operating system. We can also see that it shows the Linux kernel version which is the new 2.4.20-8.
Hitting enter will start the Linux initialization process wherein all the system hardware are checked and
initialized. This is a text based interface where we can see that the file system volumes, devices and
processes are mounted. This also starts many of the deamons or services or dependencies that are needed
for the Linux operating system. The INIT process takes over and this will launch all the processes that are
required for the Linux Operating System to start successfully. As we can see in the screen it loads a
particular Run Level in our case it is Run Level 5 which is the graphic user interface, it starts the ethernet
interface, it loads the loggers, generates SSH host keys, etc.
Now we can see the Graphical Interface welcome screen. Click the Forward button to proceed to the 'User
Account' screen. This screen allows us to create personal user accounts and set password for the same. The
user account that you create in this screen will be used for non-administrative purposes. Type the user
name in the user name field. This will be the user ID. Type the Full Name in the Full Name field. Type in
the password in the password and Confirm Password fields. Click the Forward button to proceed to the
next screen. This screen allows setting up the system date and time. In this screen we also have the option
to enable the Network Time Protocol NTP and to choose the time server. Click Forward button again.
This will proceed to the next screen that provides option to register with the RedHat Network. We will not
be registering with the RedHat network now and hence we will choose the second option and choose
Forward.
The next screen is the Additional CDs screen. This screen provides option to install the documentation CD
or packages from the additional CDs if we have any. To install from additional CDs, insert the CD and
click Install button that is next to the Additional CDs. We would not install any additional CD now and
click Forward.
Now we can see the Finish Setup screen. Click the Forward button to finish the installation. The system
restarts and we can see the Red Hat Linux login screen. We can login now with the User ID which we
have setup earlier and the next screen prompts for the password. After entering the password and hitting
enter, the GNOME desktop environment gets loaded and we are now logged in to the Red Hat Linux
Desktop now.
RedHat LINUX Desktop Environment
Lesson 46 – X Windows system
The GNOME desktop which gives us a feeling of Windows and this works based on the X Windows
concept. In this lesson we will learn about how the X Windows environment that works behind the
GNOME desktop.
The GNOME desktop which is a primary desktop environment works in conjunction with the Window
manager and thus the unified desktop environment is presented to the user. The X Windows system is a
client-server application. It runs both the X Windows client and X Windows Server in the system. By
default the X Server will be running if the X Windows is configured and if the Linux machine is running
in RUNLEVEL 5. We will open a new shell window. If we run the command RUNLEVEL this shows the
current run level which is run level 5. Let us learn the process that happens behind the initialization of the
X Windows system. The first process that starts in a Linux system is the INIT process that reads the
INITTAB file. This INITTAB file is available within the /ETC directory and this file contains the settings
that affect the start process. Let us get into the /ETC directory using CD /ETC. We can open this file to
examine the contents. Type VI INITTAB and hit enter. Here we can see that the file is opened within VI
editor. In the contents of this file, all the lines that start with the pound symbol are all comments and the
other lines contain the environment settings. Here we can see the list of all run levels and this lists 7 run
levels starting from 0 to 6. We can see the explanation for every run level. Note that Run Level 5 is for the
X11 system which is nothing but the X Windows system. The line ID 5 indicates that the init default
setting is set to load run level 5 which is the X Windows environment.
Once the INIT process knows that Run Level 5 is to be loaded, it needs another information as to which
display manager it needs to load. This setting is available in the same INITTAB file. If we scroll down we
can see a section which states 'Run XDM in run level 5'. In this section we can see a setting that states to
run the PREFDM script from the /ETC/X11 directory. The Prefdm is known as Preferred display manager
and this file contains the script to load the appropriate display manager. The Preferred display manger
launches the preferred desktop environment which is the GNOME desktop environment in our case. There
are also other desktop environments like KDE and XDM. The preferred desktop environment starts from
the moment we see the graphical user logon interface during the system startup. The desktop environment
takes over from this point onwards. This is the process behind the X Windows system.
During the Linux installation the option is presented whether or not the X Windows system needs to be
loaded by default. If we answered yes the X Windows system is configured to run by default. If we
answered NO, then the default run level is set to 3 which is a text based console. When we are in run level
3 we can start the X windows by running the command STARTX. This will start the X Windows session.
We will not run this command now as we are already running run level 5. Any application that we run
within the GNOME desktop is a X Windows client. X Windows client is supported in the background by
the X Server that interacts with the display hardware like video card, monitor and mouse.
Lesson 47 – X Windows configuration
In this lesson we will learn some more details about the X Windows system and how to configure it.
As we know both the X server and X client is responsible for the X Windows environment. The X Server
interacts directly with the display hardware installed in the system like the monitor, video card and mouse.
The GNOME desktop which we see is a X client that works in conjunction with the X Server application.
The X Server component is configured based on the display hardware installed in the system. The X
Server component is configured using the Xfree86 application which is bundled with any Linux
distribution. This application is available within the /ETC/X11 directory. Type redhat-config-xfree86 and
hit enter to launch this application from the shell window. We will not launch this from the shell window,
instead we shall launch this from the Red Hat start menu. Open the Red Hat start menu, point on system
settings and choose the item Display. This will start the Xfree86 application that is used to configure the X
Server environment. There are two tabs namely DISPLAY and ADVANCED in this application.
The Display tab has options to set the resolution and color depth. On the top we can find the monitor and
video card driver installed in the system. In our case this is a Samsung monitor with generic vesa driver
installed. Click on the down arrow for the Resolution option to reveal various resolution settings
supported by the system. The current setting is 800 x 600. Clicking on the down arrow for the Color Depth
option will reveal all possible color depth options supported by the system.
If we open the Advanced tab, we have two sections, the Monitor and Video Card. If we click the configure
button in monitor section, we can change the monitor type, horizontal/vertical refresh rates. To set DPI
settings, use the SET DPI button which provides various DPI options. We can use the configure button
under the video card section to configure various options pertaining to the video card hardware.
Lesson 48 – GNOME Desktop - I
The first place which every Linux user should explore is the Start Here. We have an icon for this in the
GNOME desktop. Launch this item and we have this window that lists three items namely Application,
Preferences and System Settings. Double-click on Applications. Here we can see all the major categories
of applications installed in the system. All applications are grouped and placed under the appropriate
category like Accessories, Games, Graphics, Internet, Office suite, Multimedia applications within the
Sound and Video category. The number of applications available within each category is shown below the
category name. For example the Accessories category contains 7 items. If we open any category such as
Games, we can find all the 31 games available within this. Any game can be launched directly from here.
We can go back and if we open the Sound and Video category, we can find all the multimedia related
applications available here.
Let's go back and let us discuss about the second item in the Start Here window, which is Preferences. If
we open this we can find many applications. We have the Accessibility link, where we can set options
helpful for the disabled persons. The background image can be configured using the Background utility.
The CD properties applet can be used to set various preferences for the CD and DVD drives. For data CD
we have options to mount, autorun and to automatically open the Nautilus File Manager. We can also set
commands that can be run when inserting different types of CDs like blank CD, Audio CD and DVD
media. Using the File Types and Programs item, we can set file associations to programs. Using the Fonts
utility, we can add and remove fonts from the system. Here we also have tools to configure handheld
devices, the keyboard and the mouse device. We also have utilities to configure keyboard shortcuts, audio
settings using the Sound applet. There are also applets available for configuring screen saver, themes and
password.
Let us now close and reopen Start Here item. We will explore the third item which is 'System Settings'.
We can open this item and find all applets and tools available to configure or modify the system settings.
The first item Add/Remove Applications is used to Add or Remove applications from the system. If we
launch this item, we get a window, that lists all the applications that are bundled with the Red Hat 9 Linux.
We can see an check box for every application. The check box with the tick mark indicates that the
application is already installed. To add new application, place a tick mark on the check box for that
application. To remove currently installed application, clear the tick mark by clicking on the check box for
the application which you wish to remove. After doing the modification click the Update button. This will
add or remove applications depending on the options chosen. As of now we have not made any
modification and we will click the Quit button to close this applet.
We also have other utilities and applets such as Authentication wherein we can set authentication options,
the Date & Time applet is used to set date and time, the Display applet wherein we can configure the
monitor and video card settings as well as the resolution and color depth. We also have applets to change
login screen options, the root password, the users/groups settings, the printer settings, the language
settings and keyboard options.
Lesson 49 – GNOME Desktop - II
Let us start exploring the GNOME start menu. This menu looks like the Windows start menu. Click on the
Red Hat icon on the bottom left corner to open the GNOME start menu. The first option which we see
here is the Log out option. Selecting this option shows us the log out dialogue, wherein we can see options
to 'Save current settings', Log out, or Shut down the system or 'Restart the system'. Choose the appropriate
option and click on OK.
The next option that we have in the start menu is the Lock Screen item, that is used to lock down the
system when not in use, thereby preventing unauthorized access. Next item is the 'Open Recent' which
works in the same manner like the 'Recent Documents' within windows. Next is the 'Search for Files' item
this will launch the search tool using which we can search for files available within the file system. This
works in the same manner as the search utility within the Windows operating system. Next we have the
Run Program item which opens a dialogue that looks similar like the RUN dialogue in Windows. We can
run any program using this utility.
Next important item is the Help item. This launches the Help documentation for the GNOME desktop.
The help is provided in HTML interface and has links that are categorized under various heads like the
Desktop, Applets, Applications, Utilities and Games. Clicking on any of these links takes us to sub-links.
For example if we click on the Desktop link, it takes us to another page that has various links like
GNOME introduction, Basic skills, Advanced Preferences, Nautilus File Manager etc. If we click on
Nautilus File Manager link this opens the help window for the Nautilus. In this window, all the help topics
are available in the left pane and clicking on the topics will display the content on the right-side pane. This
is how the help documentation works.
Lesson 50 – GNOME Desktop - III
We will explore the options available under the System Tools menu of the Red-Hat start menu. Launch
the start-menu and click on System Logs from the System Tools menu. This will launch the System Logs
applet. Using this utility we can access all the system logs saved by the system. On the left we can see the
various logs available such as boot log, cron log, security log, system log. This applet or tool is the same
as the Event Viewer tool in Windows. However this tool provides additional logs such as X free 86 log,
the the kernel startup log, mail log etc., Clicking on the particular log item displays the log entries in the
right pane. These logs are helpful to administrators to identify causes for problems.
Next item which we need to learn about is the Red Hat Network Alert Icon item within the System Tools
sub-menu of the Red hat start menu. If we launch this item, this will start the Network Alert Icon which
you can see on the bottom right corner of the screen. This is already running. The function of this icon is
to provide alerts regarding the Red Hat updates. When the color is red, it means the system is not up to
date. If it is green or blue, the system is already installed with all the updates.
Let us open the Red Hat start menu again, point on system tools and will explore other tools available
within this sub-menu. We have the 'Red Hat Network' tool using which we can configure the manner in
which the packages will be downloaded and updated from the Red Hat network. If we launch this item, we
have three tabs, the General tab wherein we can configure the proxy and authentication settings, the
Retrieval/Installation tab, where we can choose settings for retrieval, verification and installation tasks and
we have the exceptions tab wherein we can define or exclude the packages that will not be updated. Thus
this tool helps to automate the package update process in the Linux system.
Lesson 51 – GNOME Desktop - IV
Let us open the Red Hat start menu again, point on system tools and will explore other tools available
within this sub-menu. We can configure the Printer settings using the Print Manager utility. We can
launch this utility and this will check for available printers. When no printer is detected this will prompt to
start the printer configuration. Click Yes and here we can see the Printer configuration wizard. Using this
wizard we can add and configure the printers connected to the Linux box. If we click on Action we can
see there are options available to manage the print queue and to enable print sharing.
Next item in the System Tools sub menu which is important is the Print Notification Icon. This when
launched will add the print notification icon on the right bottom of the screen which will provide alert
about the status of the printer and print jobs.
Next important item which we need to learn is the Internet Configuration Wizard. This will launch a
wizard, that will guide us to setup the internet connection for the Linux system. This works the same way
like the internet wizard in Windows environment.
Next is the Hardware Browser tool, which is used to manage hardware devices installed in the system. We
also have the Floppy formatter utility that is used to format floppy diskettes using the EXT2 or DOS FAT
file system. The Disk management utility available here is used to manage disk drives and removable
drives. We can format partitions using this utility as well as mount and unmount devices using this tool.
We can also point on the 'More System tools' link to reveal additional system tools like CD Writing
application, Configuration editor that can be used to edit various configuration files pertaining to the
Linux system, the Kernel tuning tool etc.
Lesson 52 – GNOME Desktop - V
In this lesson we will be discussing in detail about the GNOME panel items. The rectangular grey bar that
we see at the bottom portion of the screen is the GNOME panel. The first icon here is the Red Hat start
menu icon. The second icon launches the Mozilla web browser. The next icon launches the Evolution mail
client application. The next three items available form part of the OpenOffice suite. They are the Writer
which is the powerful word processing application like MSWord, then the Impress Presentation maker and
the Open Office Calc which is a powerful spreadsheet application like MS Excel. These icons are known
as launchers, and this term is equivalent to the term shortcut used in Windows. Clicking on these
launchers will launch the corresponding application. The next icon which we see is the printer icon that
will launch the Print Manager. We have seen about this tool in the previous lesson.
The grey window icon which we see at last is the Workspace switcher icon. By default Red Hat Linux
allows us to work in four different workspaces. These workspace switcher is used to switch between these
different workspaces. We can switch to other workspace by clicking on the appropriate area on this icon,
as you can see this icon has four areas. Let us illustrate this. Let us select the first workspace which is the
top left square. Now we will open a terminal window in this. Without closing this terminal window, we
can start working on the next workspace by choosing the second workspace which is the right-top portion
of the workspace switcher icon. Now you can see that this is a completely fresh desktop workspace
independent of the previous one where we launched the terminal window. Here we can launch the mozilla
browser. We can now switch back to the first workspace and work with any other tool. Thus we can work
on four separate instances running multiple tasks in multiple workspaces without interrupting or stopping
the tasks that are run in other workspaces. This is how the workspace switcher functions.
Lesson 53 – GNOME Desktop - VI
Right-click on the Gnome panel and choose the Help item. This will launch the help window for the
GNOME Panel. This help contains all the information which can guide anyone in managing or
customizing the GNOME panel. The help categories are listed on the left pane, and click on these links
will display sub-categories which can be highlighted to display the help information on the right pane.
This is the place which we recommend you to go through if you need help on the gnome panels.
We will close this. Right-click again on the panel and point over the 'Add to Panel' item. This reveals
various sub-menus such as Accessories, Amusements, Internet, Multimedia etc., These are all application
groups and if we click on any of these group, this will reveal applications that can be chosen to be added
to the GNOME panel. For example if we choose clock from within the Accessories group, notice that the
clock item is added within the GNOME panel. To remove this from the panel, right-click over the item
and choose 'Remove from Panel' option.
Apart from applications it is also possible to add launchers to other programs. Launchers are nothing but
the shortcuts to applications and programs. For example, the Mozilla icon which you see next to the red
hat icon is a launcher. Like this we can add launchers to other applications, by right-clicking on the panel
and choosing the 'Launcher' option.
In addition if we right-click on the panel we also have the Utilities sub menu, using which we can add
some additional utilities on to the panel, such as the System monitor, the battery charge monitor which
would be very handy for laptop users, the disk mounter which would be very helpful when working with
removable drives, the keyboard layout switcher that comes handy when working with multiple keyboard
layouts.
Thus it is possible to customize or fine-tune the GNOME panel according to our needs.
Lesson 54 – Open Office Suite
In this lesson we will explore using the applications available within the Open Office suite available
within the Red Hat Linux.
The Open Office suite is a set of applications like the MS Office Suite and is very much helpful in an
enterprise environment. The Open Office suite is installed by default during the Red hat installation and is
available for free.
Launch the Red Hat Start menu, point on office sub menu and this will reveal all the applications available
within the Open Office Suite. The first application which we will discuss is about the Open Office Writer
which is a powerful word processing application like MS Word that comes in the MS Office suite. We
will launch this application to have a feel about the look of the interface. As you can see the Open Office
Suite version is 1.0. The application has now launched and we can see that the interface looks similar to
the Word application. We have a menu bar on top, below that we have the tool bar and below that we have
a formatting bar that contains the text formatting options. In addition we have some tools available in a
vertical bar present on the left side. We will close this window.
Browse to the Office sub-menu in start menu again and the next application which we will be seeing is the
Impress application, which is equivalent to the PowerPoint application of MS Office. Impress is the
application for presentation designing. Next we have the Calc application which is equivalent to the MS
Excel of MS Office. This is a neat spreadsheet application and ships with lot of options. We also have the
Math application which is used to work with mathematical formulas and functions. The Draw application
is a vector graphic editing application using which we can create or edit vector graphics and these graphics
can be inserted in other Office applications. We also have the Project management application, which is
similar to the MS Project application.
Next is the Dia Diagrams application that is used to create various types of diagrams. We will launch this
application. Now if we click on the diagram type drop down menu, we have lot of options like
Chronograph, Circuit, Civil, Electric, Flowchart, Pneumatic, etc. Choosing any of these diagram type will
open the appropriate picture library using which any kind of diagram can be drawn easily. We will close
this window and will go back to the Office sub-menu.
Here we have the More Office Applications sub-menu under which the OpenOffice repair item is
available. When we find that the Office Suite is corrupted, we can launch this item to detect and repair the
OpenOffice suite installation. This save some time by avoiding a complete reinstall of the suite.
Thus we have learnt about the functionality of every application bundled within the Open Office Suite.
Lesson 55 – KDE Installation
Let us learn how to install the KDE desktop environment in this lesson.
Launch the RedHat start menu, point on System Settings and click the Add/Remove Applications item.
This will launch the package management tool. This tool is also automatically launched when you insert
the first CD of the Red Hat installation set. We can now see the KDE Desktop Environment item shown at
the top. KDE is yet another desktop environment like the GNOME desktop which we have so far been
using.
Click on the check box for the KDE item, to place a tick mark and then click on Update button. We can
see the dialogue that says 'Preparing System Update' and this process checks for package dependencies.
This runs for a few seconds and the 'Completed System Preparation' dialogue appears with the statistics
about the number of applications queued to be installed. Clicking on the 'Show details' button will reveal
all the packages that are to be installed. All these packages are essential for the KDE environment. Click
on Hide Details and click the continue button. Now the installer starts installing the packages one by one.
After a few seconds, the installer prompts for the 2nd CD of the installation set. Insert this 2nd CD and click
OK. The installer will proceed the installation of packages related to KDE. After the packages available in
2nd CD are installed, the installer prompts for the 3rd CD of the installation set. Insert this CD and click
OK to proceed with the installation. After the installation is complete, click OK to close the installer.
In the next lesson we will learn how to switch to the KDE desktop environment from the GNOME
environment.
Lesson 56 –Multiple Desktop environments
We already had the GNOME desktop environment in which we had been working with and we also have
now installed the KDE environment. Let us first learn how to switch between other desktop environments.
This is done using the Desktop switching tool that is available in Red Hat.
To start this tool, launch the Red Hat start menu, point on System Tools and click on 'More System tools'
and choose the 'Desktop Switching tool' item. This launches the Desktop Switcher utility. We can see that
GNOME is desktop selected already. We can also see other desktop environment options available for the
KDE and the TWM which is called the Toms Windows Manager. To change to the KDE environment,
select the KDE option and click OK. The changes would take effect only after a system restart as the X
Windows system will load the KDE desktop environment during the system startup by reading the
INITTAB settings. As of now we will not click OK as we do not want to change the desktop environment
from the GNOME. We will click Cancel to exit out of the application.
Red Hat LINUX – Browsers/Plugins
Lesson 57 – Netscape Installation
In this lesson we will learn about Installing the Netscape Browser within Red Hat Linux.
We have already downloaded the installer file on to the /ROOT/TEMP location. This installer is for
Netscape Version 7.2 which is the latest one available for the Linux operating system. If we browse
through this path using the GNOME browser, we can see this downloaded file which is named as
netscape-i686-pc-linux-gnu-sea.tar.gz.
We will now discuss the steps involved in installing this flash plugin:
1. From the GNOME desktop, right-click and choose New Terminal.
2. Change to the temp directory by running command CD TEMP
3. If we execute a LS command inside the /root/temp directory we can find the downloaded file
named netscape-i686-pc-linux-gnu-sea.tar.gz. This is a compressed archive file that contains the
Netscape installer files.
4. Decompress the archive with the following command: tar -xzvf netscape-i686-pc-linux-gnu-
sea.tar.gz and hit Enter.
5. This command decompresses and places the installer files in a subdirectory named /netscape-
installer.
6. Change to the installer directory by executing CD netscape-isntaller/.
7. Enter the command LS –ALI and hit enter. This will show the netscape-installer file available
within this directory.
8. To run the installer enter ./netscape-installer command and hit enter.
9. This will start the graphical based installer.
The first screen will display the Readme file content. Click next to proceed through the installation.
Next screen displays the Netscape End-User License Agreement. After reading through the licence details,
click Accept to proceed.
Next screen allows us to choose setup types. For our illustration we will choose the Recommended
option, which will install the most common options of Netscape. Click Next.
Netscape installer reports that the /usr/local/netscape directory does not exist and prompts to create this
path. Click Yes.
In the next screen click Install to start the actual installation. Now we can see the progress bar showing
the installation process.
After the installation is complete, the Installation is Complete dialogue appears. Click OK. This closes
the installer window.
The next window launches the Netscape Profile manager. The Default profile is highlighted. Click Start
Netscape button to launch the browser.
To verify the browser version, go to Help menu and choose About Netscape. Now we can see that this is
version 7.2.
Thus we have successfully downloaded and installed Netscape browser within Red Hat Linux
environment.
Lesson 58 – Mozilla browser upgrade
In this lesson we will be discussing about the Mozilla browser upgrade. By default the RedHat Linux 9
installation ships with Version 1.2.1 of the Mozilla Browser.
From the GNOME panel the icon that you see next to the Red Hat icon is the Mozilla web browser icon.
Clicking this will launch the Mozilla browser. This is the version that gets installed by default during the
Red Hat Workstation installation. We can identify the current version of Mozilla by choosing About
Mozilla option from the Help menu. Note that the version states as 1.2.1.
We will now upgrade this browser to the latest version that is available for download. To upgrade the
Mozilla browser, we need to download the package and run the installer from the appropriate directory.
The Mozilla version which we have downloaded is 1.7.12 which is the latest one available. This upgrade
version is downloaded and saved to the /ROOT/TEMP directory. We will now discuss the steps involved
in installing this upgrade:
1. From the GNOME desktop, right-click and choose New Terminal.
2. Change to the temp directory by running command CD TEMP
3. If we execute a LS command inside the /root/temp directory we can find the downloaded file
named mozilla-i686-pc-linux-gnu-1.7.12-installer.tar.gz. This is a compressed archive file that
contains the installer files.
4. Decompress the archive with the following command: gunzip -dc moz*.tar.gz | tar -xvf –
5. This command decompresses and places the installer in a subdirectory named MOZILLA-
INSTALLER.
6. Change to the mozilla-installer directory by executing CD mozilla-installer.
7. Enter the command LS –ALI and hit enter. This will show the MOZILLA-INSTALLER file
available within this directory. We can also see the README file, and it is recommended always
to read through this file before installing any package.
8. Now run the installer with the ./mozilla-installer command.
Another task that we need to perform is to map the new version of Mozilla to the Mozilla icon on the
GNOME Panel. Even after the upgrade, if we click this icon, this will only launch the older version of
Mozilla 1.2.1.
Having completed the Mozilla upgrade in the previous lesson, in this lesson we will be learning about the
steps to install Macromedia Flash plugin for the Mozilla browser. The Macromedia Flash is an important
plugin that is needed for the Mozilla browser in order to view flash content present in most of the
websites.
To check what are the plugins currently installed with the Mozilla browser, from the Help menu choose
About Plugins option. This will open the web page that will show the plugins if any installed. From this
screen we can know that currently there are no plugins available.
We have downloaded the latest flash plugin version 7 from Macromedia web site
(http://www.macromedia.com) on to the /ROOT/TEMP directory. If we browse through this path using
the GNOME browser, we can see this downloaded plugin which is named as
INSTALL_FLASH_PLAYER_7_LINUX.TAR.GZ.
We will now discuss the steps involved in installing this flash plugin:
10. From the GNOME desktop, right-click and choose New Terminal.
11. Change to the temp directory by running command CD TEMP
12. If we execute a LS command inside the /root/temp directory we can find the downloaded file
named INSTALL_FLASH_PLAYER_7_LINUX.TAR.GZ. This is a compressed archive file
that contains the flash plugin installer files.
13. Decompress the archive with the following command: tar -xzvf
INSTALL_FLASH_PLAYER_7_LINUX.TAR.GZ and hit Enter.
14. This command decompresses and places the installer files in a subdirectory named
INSTALL_FLASH_PLAYER_7_LINUX.
15. Change to the installer directory by executing CD INSTALL_FLASH_PLAYER_7_LINUX.
16. Enter the command LS –ALI and hit enter. This will show the FLASHPLAYER-INSTALLER
file available within this directory.
17. To run the installer enter ./flashplayer-installer command and hit enter.
18. This will start the text based plugin installer. Hit Enter to continue.
19. Hit Enter again to accept the font installation.
20. Now the installer warns to close any open browsers. After ensuring that all browser windows are
closed, hit Enter.
21. Next we are prompted to enter the location or path where the browser is installed. Type in the path
/USR/LOCAL/MOZILLA and hit Enter.
22. The installer provides the Install Action Summary and again prompts for confirmation. Press Y to
proceed with the installation.
23. The installation is now complete. For the Perform another installation prompt enter N.
We can now launch the Mozilla browser by clicking the icon in GNOME Panel. From the Help menu
choose About Plugins option. Notice that the Flash Player plugin is now shown in the Installed Plug-ins
screen.
Thus we have enabled Flash support within the Mozilla browser.
Lesson 60 – Java Runtime Environment for Mozilla
We have learnt how to implement Flash support within Mozilla in the previous lesson. In this lesson we
will move to add Java Runtime Environment within the Mozilla browser. The Java Runtime Environment
also known as the JRE component is not by default available within the Mozilla browser. We need to
download and install this component separately. The JRE component can be downloaded from
http://java.sun.com. We have already downloaded this JRE Version 1.5 in the /ROOT/TEMP location.
We will now proceed with the installing the Java 2 Runtime Environment (J2RE):
1. From the GNOME desktop, right-click and choose New Terminal.
2. Change to the temp directory by running command CD TEMP
3. If we execute a LS –ALI command inside the /root/temp directory we can find the downloaded
file named JRE-1_5_0_06-LINUX-i586-RPM.BIN.
4. As we know this is a executable bin file. To start the installation enter the command ./ JRE-
1_5_0_06-LINUX-i586-RPM.BIN.
5. The installer displays the License Agreement. Type Yes and hit Enter. This will start unpacking
the files.
6. If we execute a LS –ALI command again, we can see a new RPM file which has been extracted
from the BIN file.
7. To start the installation from this RPM file, type the command RPM –IVH JRE and then tab it to
get the full RPM file name, and hit Enter. We can now notice that this RPM package is getting
installed.
8. This J2RE RPM package allows us to run JAVA based applications. It allows us to run JAVA
Applets and provides us a plugin to execute Java codes from within a web browser. Thus we get
three functionality bundled in a single package. The J2RE component is a system requirement for
the purpose of either running a JAVA based application or a small Java applet or for running a
Java plugin within a browser.
9. This J2RE RPM installation only installs the package within the Linux environment. After this
RPM installation is complete we need to manually map the plugin with the Mozilla browser.
10. Change to the Mozilla directory by executing CD /USR/LOCAL/MOZILLA/.
11. Get into the Plugins folder by entering CD PLUGINS/ and hitting enter.
12. Enter the command
LN –S /usr/java/j2re1.5.0_06/plugin/i386/ns610/libjavaplugin_oji.so . and hit enter. This
command will create a soft symbolic link within the mozilla plugin folder with the J2RE
component.
13. We can now launch the Mozilla browser, choose About Plugins option from Help and if we scroll
down, we can verify that the Java Plugin 1.5.0 is successfully installed.
Thus we have added support within the Mozilla browser, so that we will be able to visit any web sites that
require Java Plugin support.