Page 1 of 1
SQL Error [nagiosxi] showing on the screen
Posted: Wed Jan 25, 2017 4:32 pm
by dpearceFL
SQL Error [nagiosxi] : ERROR: relation "xi_incidents_id_seq" already exists
SQL Error [nagiosxi] : ERROR: syntax error at or near "NOT"
LINE 2: CREATE TABLE IF NOT EXISTS xi_incidents ...
^
SQL Error [nagiosxi] : ERROR: syntax error at or near "NOT"
LINE 2: CREATE TABLE IF NOT EXISTS xi_incidents ...
Any ideas?
CentOS 6.8
PHP 5.5
Current Nagios, just upgraded from 2012 era
Re: SQL Error [nagiosxi] showing on the screen
Posted: Wed Jan 25, 2017 5:35 pm
by dwhitfield
Please run the fullowing
Code: Select all
cd /usr/local/nagiosxi/scripts/
./repair_databases.sh
If that doesn't fix things for you, take a look at
https://support.nagios.com/kb/article.php?id=24
Please note that you have (or should have, at least) both MySQL and Postgres. This is no longer the default, but we keep Postgres from older versions.
Also, if that doesn't do it, can you upload you upgrade.log? Thanks!
Re: SQL Error [nagiosxi] showing on the screen
Posted: Thu Jan 26, 2017 2:33 pm
by dpearceFL
I seem to have both postgres and mysql running. If I want to start from scratch instead of upgrading, do I just uninstall Nagios and reinstall or can I just nuke a database? The installation has nothing of value in it.
Dave
Re: SQL Error [nagiosxi] showing on the screen
Posted: Thu Jan 26, 2017 2:43 pm
by dwhitfield
If it really has nothing of value, I'd install CentOS 7.3 and Nagios XI 5.4.1:
https://assets.nagios.com/downloads/nag ... 4.1.tar.gz
Even if you stick with CentOS 6.8, I'd do a full install just to clear out all the old log messages and such. It's not strictly necessary, but installs don't take that long.
To be clear, there is no problem with running both Postgres and MySQL. That was just what we did in the past. I take it from your post that the db repair didn't work?