Page 1 of 2
Nagios xi install.
Posted: Wed Feb 10, 2010 6:09 pm
by jladd
I have been trying to do the manual install of nagios xi on centos5 Following your guide online i run into problems on the 3rd step. the ./3-dbservers I have erros on line #13 line #17 line #23 line #3. Which all have to do with postgresql. I didnt have any errors running the 1-prereqs script. Am i doing something wrong here? is there a different version of postgresql i need to install. I am at a loss at this point. Please any help or suggestion would be appreciated.
Re: Nagios xi install.
Posted: Wed Feb 10, 2010 6:16 pm
What exactly are the errors you're getting? I just did a centOS 5 install and had no problems..
Re: Nagios xi install.
Posted: Wed Feb 10, 2010 11:30 pm
by admin
There are some error/warning messages that get printed when this command is run to load the database structure. They can be safely ignored. Just continue with step 4 and onwards and see if things come up okay when you're finished.
Re: Nagios xi install.
Posted: Thu Feb 11, 2010 10:46 am
by jladd
[root@localhost xi]# ./3-dbservers
Initializing PostgresQL...
Usage: /etc/init.d/postgresql {start|stop|status|restart|condrestart|condstop|reload|force-reload}
Starting PostgresQL...
Initializing database: mkdir: cannot create directory `/var/lib/pgsql/data/pg_log': File exists
[FAILED]
Starting postgresql service: [FAILED]
Restarting PostgresQL...
Stopping postgresql service: [FAILED]
Initializing database: mkdir: cannot create directory `/var/lib/pgsql/data/pg_log': File exists
[FAILED]
Starting postgresql service: [FAILED]
Starting MySQL...
Starting MySQL: [ OK ]
Setting MySQL root password...
mysqladmin: connect to server at 'localhost' failed
error: 'Access denied for user 'root'@'localhost' (using password: NO)'
MySQL root password set to: nagiosxi
that is the output when i run the script.
[root@localhost xi]# ./9-dbbackups
mkdir: cannot create directory `/store': File exists
mkdir: cannot create directory `/store/backups': File exists
mkdir: cannot create directory `/store/backups/mysql': File exists
mkdir: cannot create directory `/store/backups/postgresql': File exists
mkdir: cannot create directory `/root/scripts': File exists
I get that on the 9-dbbackups script. i assume that because it already ran once and ran fine.
Now everything seemed like it was working untill i got to the B-installxi script then i was getting this output which i believe to be related to the 3-dbservers script.
[root@localhost xi]# ./B-installxi
Creating product directory...
Adding password for user nagiosadmin
psql: could not connect to server: No such file or directory
Is the server running locally and accepting
connections on Unix domain socket "/tmp/.s.PGSQL.5432"?
psql: could not connect to server: No such file or directory
Is the server running locally and accepting
connections on Unix domain socket "/tmp/.s.PGSQL.5432"?
Stopping postgresql service: [FAILED]
Initializing database: mkdir: cannot create directory `/var/lib/pgsql/data/pg_log': File exists
[FAILED]
Starting postgresql service: [FAILED]
psql: could not connect to server: No such file or directory
Is the server running locally and accepting
connections on Unix domain socket "/tmp/.s.PGSQL.5432"?
psql: could not connect to server: No such file or directory
Is the server running locally and accepting
connections on Unix domain socket "/tmp/.s.PGSQL.5432"?
chown: cannot access `/usr/local/nagios/etc/hosts/*.cfg': No such file or directory
chown: cannot access `/usr/local/nagios/etc/services/*.cfg': No such file or directory
Thanks a lot in advance for your help.
Re: Nagios xi install.
Posted: Thu Feb 11, 2010 3:22 pm
by admin
It looks like the MySQL and PostgresQL servers didn't get installed. Are you by chance trying to install XI on a 64-bit system? We ran into an issue yesterday with a 64-bit version of CentOS that failed because not all the required packages were available for 64-bit platforms.
Re: Nagios xi install.
Posted: Thu Feb 11, 2010 3:40 pm
by jladd
Re: Nagios xi install.
Posted: Thu Feb 11, 2010 5:00 pm
by jladd
Ok i believe i have this figured out. I went into /var/lib/pgsql/ and deleted the data folder. At that point i re-ran the 3-dbservers script and it re created the db and now it appears to be working fine. I am going to be check this out more and make sure everything is running fine.
Re: Nagios xi install.
Posted: Wed Mar 10, 2010 4:21 pm
by systems
I am trying to install Nagios XI on Red Hat EL 5.4. I think i am stuck at ./1-prereqs, it complained about no package available.
Code: Select all
No package perl-CPAN available.
No package php-mcrypt available.
No package php-mssql available.
No package package-cleanup available.
I believe those are the ones causing the following problem when i run ./3-dbservers
Code: Select all
Starting PostgresQL...
Initializing database: [FAILED]
Starting postgresql service: [FAILED]
Restarting PostgresQL...
Stopping postgresql service: [FAILED]
Initializing database: mkdir: cannot create directory `/var/lib/pgsql/data/pg_log': File exists
[FAILED]
Starting postgresql service: [FAILED]
Starting MySQL...
Starting MySQL: [ OK ]
Setting MySQL root password...
mysqladmin: connect to server at 'localhost' failed
error: 'Access denied for user 'root'@'localhost' (using password: NO)'
I did look online to search for those rpm packages, but I can't find anything. Anyone experienced the same issue? Is this the missing package issue or postgresql issue? I have checked for postgresql, they're all installed.
# yum list | grep postgresql
postgresql.i386 8.1.18-2.el5_4.1 installed
postgresql-devel.i386 8.1.18-2.el5_4.1 installed
postgresql-libs.i386 8.1.18-2.el5_4.1 installed
postgresql-server.i386 8.1.18-2.el5_4.1 installed
Any help would be appreciated. Thanks!
Re: Nagios xi install.
Posted: Wed Mar 10, 2010 4:38 pm
by jladd
You look like your having the exact same issue i was having. Have you tried going to /var/lib/pgsql/ and deleting the data folder and re-running ./3-dbservers. I did that and re-ran all of the setup scripts from ./3-dbservers up and after that process it worked for me.
Re: Nagios xi install.
Posted: Thu Mar 11, 2010 3:18 pm
by systems
Yes, after removing the /var/lib/pgsql/data folder seems to correct the problem somehow. It did complained about "connect to server at 'localhost' failed, error: access denied for user root@localhost. Is that normal? See the output below:
Code: Select all
# ./3-dbservers
Initializing PostgresQL...
Usage: /etc/init.d/postgresql {start|stop|status|restart|condrestart|condstop|reload|force-reload}
Starting PostgresQL...
Initializing database: [ OK ]
Starting postgresql service: [ OK ]
Restarting PostgresQL...
Stopping postgresql service: [ OK ]
Starting postgresql service: [ OK ]
Starting MySQL...
Starting MySQL: [ OK ]
Setting MySQL root password...
mysqladmin: connect to server at 'localhost' failed
error: 'Access denied for user 'root'@'localhost' (using password: NO)'