Cpanel/WHM FAQs

Home | Webstats | Frontpage | Disk Quota | FTP Problems | MySql | Exim Notes | Basic Commands | TCP Wrappers | Kernel Compilation| Nagios| Harddisk Restoration| Cpanel Scripts| IPTables| Forums
Search Query

RSS site feed|Webmaster Stuff|International Calling Cards|Linux Recovery|Server Recovery|Hard Drive Recovery|Raid Recovery unique designer cufflinks

Nagios is an open source host, service and network monitoring program. It watches hosts and services that you specify, alerting you when things go bad and when they get better". This is the same tool that used to be called NetSaint until recently. Although the NetSaint site is still up, all future development will be done on Nagios. Here I try to explain the nagios installation and configuration done within 2 hours (max). Please note that you need root access to install nagios.


Nagios - how to install and configure?

1)Download the tarball of nagios (Here I use nagios-1.0b5 version)
#wget http://heanet.dl.sourceforge.net/sourceforge/nagios/nagios-1.0b5.tar.gz

2)Extract the tarball
# tar zxvf nagios-1.0b5.tar.gz

3) Create a folder named nagios under /usr/local
# mkdir /usr/local/nagios

4)Create a user and group named nagios. In many of the linux flavours, a corresponding group will be created for evry user.
#useradd nagios
#groupadd nagios

5) Enter the extracted folder. # cd nagios-1.0b5

6) Type the following script on a single line without line breaks: # ./configure --prefix=/usr/local/nagios --with-cgiurl=/nagios/cgi-bin --with-htmurl=/nagios/ --with-nagios-user=nagios --with-nagios-grp=nagios

7)# make all

8)# make install

9)#make install-init

10)#make install-commandmode

11) If you take a look into the /usr/local/nagios directory right now, you will see that there are four directories.
     bin      sbin      share     var    

12) # make install-config


Congrats, the nagios installation is completed!!! But to function properly, we need to install nagios plugin also. Come on, lets run to the next stage...

Install the nagios Plugin


1)Download the plugin. I used nagios-plugins-1.3.0 without any much problems. You can download it usng wget http:sumith.net/nagios-plugins-1.3.0.tar.gz

2)#tar zxvf nagios-plugins-1.3.0.tar.gz

3)Type the following script on a single line without line breaks: # ./configure --prefix=/usr/local/nagios --with-nagios-user=nagios --with-nagios-grp=nagios

4)#make all

5)#make install

6)#cd /usr/local/nagios/libexec/

7) To test the working, run the command ./check_ssh www.example.com
SSH ok - protocol version 1.99- - server version

8)#cd /usr/local/nagios/etc

9)# mkdir sample

10)# cp *.cfg-sample sample/

11)Rename each file manually, or use the following command to take care of them all at once.

for i in *cfg-sample; do mv $i `echo $i | sed -e s/cfg-sample/cfg/`; done;

12)../bin/nagios -v nagios.cfg

Run this command will show a lot of errors with the nagios configuration. Lets have to clear all the errors one-by-one.

13)#rm -f hosts.cfg services.cfg contacts.cfg contactgroups.cfg hostgroups.cfg dependencies.cfg escalations.cfg

14)#touch dependencies.cfg escalations.cfg contacts.cfg services.cfg

The nagios installation in completed. Now we have to configure the files related to nagios. This is a very easy step once you go through the steps.


Can I see a demo of Cpanel and WHM?

Yes, click here if you like to see a Cpanel Demo and click here if you like to see a demo of WHM. A pop up window will appear asking for username and password. Enter the username and password as cpdemo and cpdemo respectively.


Please send comments on these web pages to sumith at sumith.net

copyright (c) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 Sumith Sreedhar
Verbatim copying and redistribution of this entire page are permitted provided this notice is preserved.


Valid HTML 4.01!