So here's the output of the series of commands:
Code: Select all
[root@nagios vmesquita]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/vg_nagios-lv_root
36G 27G 7.6G 78% /
tmpfs 7.8G 0 7.8G 0% /dev/shm
/dev/sdd1 477M 72M 380M 16% /boot
tmpfs 50M 7.1M 43M 15% /var/nagiosramdisk
[root@nagios vmesquita]# service postgresql stop
Stopping postgresql service: [ OK ]
[root@nagios vmesquita]# killall postgresql
postgresql: no process killed
[root@nagios vmesquita]# service postgresql start
Starting postgresql service: [ OK ]
[root@nagios vmesquita]# service postgresql status
postmaster (pid 18959) is running...
[root@nagios vmesquita]# tail /var/lib/pgsql/pgstartup.log
Success. You can now start the database server using:
/usr/bin/postgres -D /var/lib/pgsql/data
or
/usr/bin/pg_ctl -D /var/lib/pgsql/data -l logfile start
LOG: could not create IPv6 socket: Address family not supported by protocol
LOG: could not create IPv6 socket: Address family not supported by protocol
could not write to log file: No space left on device
[root@nagios vmesquita]# ls -lad /var/lib/pgsql
drwx------. 4 postgres postgres 4096 May 2 19:01 /var/lib/pgsql
[root@nagios vmesquita]# ls -la /var/lib/pgsql
total 24
drwx------. 4 postgres postgres 4096 May 2 19:01 .
drwxr-xr-x. 33 root root 4096 May 4 03:37 ..
drwx------. 2 postgres postgres 4096 Mar 30 2015 backups
-rw-r--r-- 1 postgres postgres 85 Mar 30 2015 .bash_profile
drwx------. 12 postgres postgres 4096 May 4 12:38 data
-rw-------. 1 postgres postgres 1359 Apr 26 00:00 pgstartup.log
Now the ls output:
Code: Select all
-rwxrwxr-x. 1 nagios nagios 161 May 4 12:08 /usr/local/nagiosxi/scripts/nagiosql.cookies
-rwxrwxr-x. 1 nagios nagios 271666 Apr 25 18:26 /usr/local/nagiosxi/scripts/nagiosql_defaults.sql
-rwxrwxr-x. 1 nagios nagios 39900 Jan 28 17:17 /usr/local/nagiosxi/scripts/nagiosql.delete.contact
-rwxrwxr-x. 1 nagios nagios 885 Apr 25 18:26 /usr/local/nagiosxi/scripts/nagiosql_delete_contact.php
-rwxrwxr-x. 1 nagios nagios 1927 Apr 25 18:26 /usr/local/nagiosxi/scripts/nagiosql_delete_host.php
-rwxrwxr-x. 1 nagios nagios 446 Apr 25 18:26 /usr/local/nagiosxi/scripts/nagiosql_delete_object.sh
-rwxrwxr-x. 1 nagios nagios 64566 Oct 26 2015 /usr/local/nagiosxi/scripts/nagiosql.delete.service
-rwxrwxr-x. 1 nagios nagios 2756 Apr 25 18:26 /usr/local/nagiosxi/scripts/nagiosql_delete_service.php
-rwxrwxr-x. 1 nagios nagios 41292 Jan 28 17:17 /usr/local/nagiosxi/scripts/nagiosql.delete.timeperiod
-rwxrwxr-x. 1 nagios nagios 886 Apr 25 18:26 /usr/local/nagiosxi/scripts/nagiosql_delete_timeperiod.php
-rwxrwxr-x. 1 nagios nagios 7400 Jul 1 2014 /usr/local/nagiosxi/scripts/nagiosql.export.additional
-rwxrwxr-x. 1 nagios nagios 1272 Apr 25 18:26 /usr/local/nagiosxi/scripts/nagiosql_exportall.php
-rwxrwxr-x. 1 nagios nagios 15847 May 4 12:08 /usr/local/nagiosxi/scripts/nagiosql.export.monitoring
-rwxrwxr-x. 1 nagios nagios 1286 Apr 25 18:26 /usr/local/nagiosxi/scripts/nagiosql_importall.php
-rwxrwxr-x. 1 nagios nagios 81899 May 3 11:50 /usr/local/nagiosxi/scripts/nagiosql.import.monitoring
-rwxrwxr-x. 1 nagios nagios 35807 May 4 12:08 /usr/local/nagiosxi/scripts/nagiosql.login
-rwxrwxr-x. 1 nagios nagios 1791 Apr 25 18:26 /usr/local/nagiosxi/scripts/nagiosql_login.php
-rwxrwxr-x. 1 nagios nagios 2248 Apr 25 18:26 /usr/local/nagiosxi/scripts/nagiosql_snapshot.sh
-rwxrwxr-x. 1 nagios nagios 200 Apr 25 18:26 /usr/local/nagiosxi/scripts/nagiosql_trim_backups.sh
And I didn't try vacuum before, so:
Code: Select all
[root@nagios vmesquita]# echo "vacuum;vacuum analyze;vacuum full;"|psql nagiosxi postgres
VACUUM
VACUUM
VACUUM
It was upgraded from Nagios 2014 and everythingelse is running fine. Sorry I didn't see his questions before.
Apparently after running the commands suggested, the recurrent errors changed to:
Code: Select all
[Wed May 04 12:38:03 2016] [error] [client 172.27.15.207] PHP Notice: Undefined variable: result in /usr/local/nagiosxi/html/includes/db.inc.php on line 249, referer: http://nagios.selic.bc/nagiosxi/includes/components/xicore/status.php?show=hostdetail&host=vx576.selic.bc
[Wed May 04 12:38:16 2016] [error] [client 172.27.143.15] PHP Notice: Undefined variable: service_ids in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 303, referer: http://nagios/nagiosxi/includes/components/nocscreen/noc.php?host=&hostgroup=Producao&servicegroup=&state=&reporttimesubmitbutton=Update
[Wed May 04 12:38:16 2016] [error] [client 172.27.143.15] PHP Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 303, referer: http://nagios/nagiosxi/includes/components/nocscreen/noc.php?host=&hostgroup=Producao&servicegroup=&state=&reporttimesubmitbutton=Update
[Wed May 04 12:38:16 2016] [error] [client 172.27.143.15] PHP Notice: Undefined variable: host_ids_str in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 314, referer: http://nagios/nagiosxi/includes/components/nocscreen/noc.php?host=&hostgroup=Producao&servicegroup=&state=&reporttimesubmitbutton=Update
[Wed May 04 12:38:16 2016] [error] [client 172.27.143.15] PHP Notice: Undefined variable: service_ids_str in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 318, referer: http://nagios/nagiosxi/includes/components/nocscreen/noc.php?host=&hostgroup=Producao&servicegroup=&state=&reporttimesubmitbutton=Update
[Wed May 04 12:38:16 2016] [error] [client 172.27.143.15] PHP Notice: Undefined variable: host_ids_str in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 408, referer: http://nagios/nagiosxi/includes/components/nocscreen/noc.php?host=&hostgroup=Producao&servicegroup=&state=&reporttimesubmitbutton=Update
[Wed May 04 12:38:16 2016] [error] [client 172.27.143.15] PHP Notice: Undefined variable: host_ids_str in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 75, referer: http://nagios/nagiosxi/includes/components/nocscreen/noc.php?host=&hostgroup=Producao&servicegroup=&state=&reporttimesubmitbutton=Update
[Wed May 04 12:38:16 2016] [error] [client 172.27.143.15] PHP Notice: Undefined variable: service_ids in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 132, referer: http://nagios/nagiosxi/includes/components/nocscreen/noc.php?host=&hostgroup=Producao&servicegroup=&state=&reporttimesubmitbutton=Update
[Wed May 04 12:38:16 2016] [error] [client 172.27.143.15] PHP Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 132, referer: http://nagios/nagiosxi/includes/components/nocscreen/noc.php?host=&hostgroup=Producao&servicegroup=&state=&reporttimesubmitbutton=Update
[Wed May 04 12:38:16 2016] [error] [client 172.27.143.15] PHP Notice: Undefined variable: host_ids_str in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 143, referer: http://nagios/nagiosxi/includes/components/nocscreen/noc.php?host=&hostgroup=Producao&servicegroup=&state=&reporttimesubmitbutton=Update
[Wed May 04 12:38:16 2016] [error] [client 172.27.143.15] PHP Notice: Undefined variable: service_ids_str in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 147, referer: http://nagios/nagiosxi/includes/components/nocscreen/noc.php?host=&hostgroup=Producao&servicegroup=&state=&reporttimesubmitbutton=Update
[Wed May 04 12:38:18 2016] [error] [client 172.27.15.145] PHP Notice: Undefined variable: host_ids_str in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 75, referer: http://nagios.selic.bc/nagiosxi/includes/components/nocscreen/noc.php?host=&hostgroup=Producao&servicegroup=&state=&reporttimesubmitbutton=Update
[Wed May 04 12:38:18 2016] [error] [client 172.27.15.145] PHP Notice: Undefined variable: service_ids in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 132, referer: http://nagios.selic.bc/nagiosxi/includes/components/nocscreen/noc.php?host=&hostgroup=Producao&servicegroup=&state=&reporttimesubmitbutton=Update
[Wed May 04 12:38:18 2016] [error] [client 172.27.15.145] PHP Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 132, referer: http://nagios.selic.bc/nagiosxi/includes/components/nocscreen/noc.php?host=&hostgroup=Producao&servicegroup=&state=&reporttimesubmitbutton=Update