Just for kicks, I am
cp /usr/local/nagios/etc/checkcommands.cfg /usr/local/nagios2/etc/checkcommands.cfg
cp /usr/local/nagios/etc/contactgroups.cfg /usr/local/nagios2/etc/contactgroups.cfg
cp /usr/local/nagios/etc/contacts.cfg /usr/local/nagios2/etc/contacts.cfg
cp /usr/local/nagios/etc/dependencies.cfg /usr/local/nagios2/etc/dependencies.cfg
cp /usr/local/nagios/etc/escalations.cfg /usr/local/nagios2/etc/escalations.cfg
cp /usr/local/nagios/etc/hostgroups.cfg /usr/local/nagios2/etc/hostgroups.cfg
cp /usr/local/nagios/etc/hosts.cfg /usr/local/nagios2/etc/hosts.cfg
cp /usr/local/nagios/etc/services.cfg /usr/local/nagios2/etc/services.cfg
cp /usr/local/nagios/etc/timeperiods.cfg /usr/local/nagios2/etc/timeperiods.cfg
cp /usr/local/nagios/etc/hostextinfo.cfg /usr/local/nagios2/etc/hostextinfo.cfg
cp /usr/local/nagios/etc/serviceextinfo.cfg /usr/local/nagios2/etc/serviceextinfo.cfg
cp /usr/local/nagios/etc/resource.cfg /usr/local/nagios2/etc/resource.cfg
I had to edit resource.cfg and take out all the mysql stuff I had in there.
To save some more time, I thought we might be able to just copy the plugins over from the old to the new. Sorry, can't do it.
-./configure --prefix=/usr/local/nagios2 --with-cgiurl=/nagios2/cgi-bin
The libexec directory has now been created for you and the plugins installed. Permissions are WRONG on the directory and files in it.
chown -R nagios.nagios libexec/
chmod -R 775 libexec/
We are now ready to test the configs and see what directives nagios is going to puke on from copiing from 1.2 .cfg's to 2.0 version of nagios.
/usr/local/nagios2/bin/nagios -v /usr/local/nagios2/etc/nagios.cfg
Doesn't like contact_groups in the hostgroups.cfg so remove them.
Doesn't like gd2_image in the hostextinfo.cfg so remove/replace with statusmap_image
hit esc :
to make a global search/replace of gd2_image with statusmap_image
In nagios 1.2 you could have gd2_image blank, but in 2.0 it appears you have to have it defined, so either comment/remove them, or define them.
So, in my case I needed to run this search/replace, since mine where all undefined.
In nagios 2.0 you can't have host_name definitions in serviceextinfo.cfg that are not in hosts.cfg, unlike 1.2 which was forgiving in this error.
For V 2.0 hosts.cfg must have contact_groups defined for each host, max_check_attempts must be defined, check_period also.
services.cfg must have a contact_groups defined, although the verify does not complain about it. Nagios will run without it though. Note: the docs clearly show that this is required. I'm simply pointing out the differences and oddities that I notice.
That's all I have for now. Add anything comments, corrections, etc.