Page 1 of 2

Nagios XI upgradation issue

Posted: Wed Nov 25, 2015 1:33 pm
by raamardhani7
Hi Team,

I tried upgrading Nagios XI to the latest version and I am facing the below errors.

Code: Select all

---- Starting Nagios XI Backup ----
No entry for terminal type "unknown";
using dumb terminal settings.
Backing up Core Config Manager (NagiosQL)...
tar: Removing leading `/' from member names
tar: Removing leading `/' from member names
Backing up Nagios Core...
tar: Removing leading `/' from member names
Backing up Nagios XI...
tar: Removing leading `/' from member names
Backing up MRTG...
tar: Removing leading `/' from member names
Backing up NRDP...
tar: Removing leading `/' from member names
Backing up Nagvis...
tar: Removing leading `/' from member names
Backing up MySQL databases...
mysqldump: Got error: 130: Incorrect file format 'nagios_logentries' when using LOCK TABLES
Error backing up MySQL database 'nagios' - check the password in this script!
mysqldump: Got error: 130: Incorrect file format 'nagios_logentries' when using LOCK TABLES
Error backing up MySQL database 'nagios' - check the password in this script!

Please help me with this.. thanks.. :)

Re: Nagios XI upgradation issue

Posted: Wed Nov 25, 2015 1:36 pm
by hsmith
Are you trying to upgrade from the web GUI or the command line?

Can you post the full output of the upgrade log?

Re: Nagios XI upgradation issue

Posted: Wed Nov 25, 2015 4:07 pm
by raamardhani7
hsmith wrote:Are you trying to upgrade from the web GUI or the command line?

Can you post the full output of the upgrade log?
I tried both the ways and I could see the same output.

Code: Select all

/usr/local/nagiosxi/scripts/backup_xi.sh
tar: Removing leading `/' from member names
tar: Removing leading `/' from member names
tar: Removing leading `/' from member names
tar: /usr/local/nagios/var/spool/perfdata: file changed as we read it
tar: /usr/local/nagios/var/npcd.log: file changed as we read it
tar: /usr/local/nagios/var/nagios.log: file changed as we read it
tar: /usr/local/nagios/var/rw/nagios.qh: socket ignored
tar: /usr/local/nagios/var/ndo.sock: socket ignored
tar: /usr/local/nagios/var: file changed as we read it
tar: /usr/local/nagios/share/perfdata/uusrcptime00.fossil: file changed as we read it
tar: Removing leading `/' from member names
tar: Removing leading `/' from member names
tar: Removing leading `/' from member names
tar: Removing leading `/' from member names
mysqldump: Got error: 130: Incorrect file format 'nagios_logentries' when using LOCK TABLES

Code: Select all

The below is another error I am facing with from few days.
Error backing up MySQL database 'nagios' - check the password in this script!

Code: Select all

more upgrade.log
Backing up Core Config Manager (NagiosQL)...
Backing up Nagios Core...
Backing up Nagios XI...
Backing up MRTG...
Backing up NRDP...
Backing up Nagvis...
Backing up MySQL databases...
Error backing up MySQL database 'nagios' - check the password in this script!

Re: Nagios XI upgradation issue

Posted: Wed Nov 25, 2015 11:00 pm
by Box293
Run this command

Code: Select all

tail /var/log/mysqld.log -n 100 > /tmp/mysqld_log.txt
Send us this file:
/tmp/mysqld_log.txt

Re: Nagios XI upgradation issue

Posted: Thu Nov 26, 2015 11:12 am
by raamardhani7
Box293 wrote:Run this command

Code: Select all

tail /var/log/mysqld.log -n 100 > /tmp/mysqld_log.txt
Send us this file:
/tmp/mysqld_log.txt

Code: Select all

[root@lussvpnagiosxi00 nagios]# cat /tmp/mysqld_log.txt
151125 22:29:28 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:28 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:28 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:28 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:29 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:29 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:29 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:29 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:29 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:29 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:29 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:29 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:29 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:29 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:29 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:29 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:29 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:29 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:30 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:30 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:30 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:30 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:30 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:30 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:30 [ERROR] /usr/libexec/mysqld: Table './nagios/nagios_statehistory' is marked as crashed and last (automatic?) repair failed
151125 22:29:30 [Note] /usr/libexec/mysqld: Normal shutdown

151125 22:29:30 [Note] Event Scheduler: Purging the queue. 0 events
151125 22:29:31  InnoDB: Starting shutdown...
151125 22:29:33  InnoDB: Shutdown completed; log sequence number 0 128325
151125 22:29:33 [Note] /usr/libexec/mysqld: Shutdown complete

151125 22:29:33 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
151125 22:38:31 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
151125 22:38:31  InnoDB: Initializing buffer pool, size = 8.0M
151125 22:38:31  InnoDB: Completed initialization of buffer pool
151125 22:38:31  InnoDB: Started; log sequence number 0 128325
151125 22:38:31 [Note] Event Scheduler: Loaded 0 events
151125 22:38:31 [Note] /usr/libexec/mysqld: ready for connections.
Version: '5.1.73'  socket: '/var/lib/mysql/mysql.sock'  port: 3306  Source distribution
151125 22:39:32 [Note] /usr/libexec/mysqld: Normal shutdown

151125 22:39:32 [Note] Event Scheduler: Purging the queue. 0 events
151125 22:39:34  InnoDB: Starting shutdown...
151125 22:39:37  InnoDB: Shutdown completed; log sequence number 0 128325
151125 22:39:37 [Note] /usr/libexec/mysqld: Shutdown complete

151125 22:39:37 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
151125 22:46:03 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
151125 22:46:04  InnoDB: Initializing buffer pool, size = 8.0M
151125 22:46:04  InnoDB: Completed initialization of buffer pool
151125 22:46:04  InnoDB: Started; log sequence number 0 128325
151125 22:46:04 [Note] Event Scheduler: Loaded 0 events
151125 22:46:04 [Note] /usr/libexec/mysqld: ready for connections.
Version: '5.1.73'  socket: '/var/lib/mysql/mysql.sock'  port: 3306  Source distribution
151125 22:47:23 [Note] /usr/libexec/mysqld: Normal shutdown

151125 22:47:23 [Note] Event Scheduler: Purging the queue. 0 events
151125 22:47:25  InnoDB: Starting shutdown...
151125 22:47:29  InnoDB: Shutdown completed; log sequence number 0 128325
151125 22:47:29 [Note] /usr/libexec/mysqld: Shutdown complete

151125 22:47:29 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
151125 22:47:34 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
151125 22:47:34  InnoDB: Initializing buffer pool, size = 8.0M
151125 22:47:34  InnoDB: Completed initialization of buffer pool
151125 22:47:34  InnoDB: Started; log sequence number 0 128325
151125 22:47:34 [Note] Event Scheduler: Loaded 0 events
151125 22:47:34 [Note] /usr/libexec/mysqld: ready for connections.
Version: '5.1.73'  socket: '/var/lib/mysql/mysql.sock'  port: 3306  Source distribution
151126  9:58:04 [Note] /usr/libexec/mysqld: Normal shutdown

151126  9:58:04 [Note] Event Scheduler: Purging the queue. 0 events
151126  9:58:04  InnoDB: Starting shutdown...
151126  9:58:10  InnoDB: Shutdown completed; log sequence number 0 128325
151126  9:58:10 [Note] /usr/libexec/mysqld: Shutdown complete

151126 09:58:10 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
151126 10:00:06 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
151126 10:00:06  InnoDB: Initializing buffer pool, size = 8.0M
151126 10:00:06  InnoDB: Completed initialization of buffer pool
151126 10:00:07  InnoDB: Started; log sequence number 0 128325
151126 10:00:07 [Note] Event Scheduler: Loaded 0 events
151126 10:00:07 [Note] /usr/libexec/mysqld: ready for connections.
Version: '5.1.73'  socket: '/var/lib/mysql/mysql.sock'  port: 3306  Source distribution
151126 10:00:54 [Note] /usr/libexec/mysqld: Normal shutdown

151126 10:00:54 [Note] Event Scheduler: Purging the queue. 0 events
151126 10:00:54  InnoDB: Starting shutdown...
151126 10:00:57  InnoDB: Shutdown completed; log sequence number 0 128325
151126 10:00:57 [Note] /usr/libexec/mysqld: Shutdown complete

151126 10:00:57 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
151126 10:01:15 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
151126 10:01:15  InnoDB: Initializing buffer pool, size = 8.0M
151126 10:01:15  InnoDB: Completed initialization of buffer pool
151126 10:01:15  InnoDB: Started; log sequence number 0 128325
151126 10:01:15 [Note] Event Scheduler: Loaded 0 events
151126 10:01:15 [Note] /usr/libexec/mysqld: ready for connections.
Version: '5.1.73'  socket: '/var/lib/mysql/mysql.sock'  port: 3306  Source distribution

Code: Select all

[root@lussvpnagiosxi00 tmp]# echo "USE nagios;select instance_id, status_update_time,program_start_time,is_currently_running from nagios_programstatus" |mysql -pnagiosxi
instance_id     status_update_time      program_start_time      is_currently_running
1       2015-11-26 03:01:40     2015-11-25 09:25:59     1
[root@lussvpnagiosxi00 tmp]# mysqlcheck --auto-repair -A -pnagiosxi
mysql.columns_priv                                 OK
mysql.db                                           OK
mysql.event                                        OK
mysql.func                                         OK
mysql.general_log
Error    : You can't use locks with log tables.
status   : OK
mysql.help_category                                OK
mysql.help_keyword                                 OK
mysql.help_relation                                OK
mysql.help_topic                                   OK
mysql.host                                         OK
mysql.ndb_binlog_index                             OK
mysql.plugin                                       OK
mysql.proc                                         OK
mysql.procs_priv                                   OK
mysql.servers                                      OK
mysql.slow_log
Error    : You can't use locks with log tables.
status   : OK
mysql.tables_priv                                  OK
mysql.time_zone                                    OK
mysql.time_zone_leap_second                        OK
mysql.time_zone_name                               OK
mysql.time_zone_transition                         OK
mysql.time_zone_transition_type                    OK
mysql.user                                         OK
nagios.nagios_acknowledgements                     OK
nagios.nagios_commands                             OK
nagios.nagios_commenthistory                       OK
nagios.nagios_comments                             OK
nagios.nagios_configfiles                          OK
nagios.nagios_configfilevariables                  OK
nagios.nagios_conninfo                             OK
nagios.nagios_contact_addresses                    OK
nagios.nagios_contact_notificationcommands         OK
nagios.nagios_contactgroup_members                 OK
nagios.nagios_contactgroups                        OK
nagios.nagios_contactnotificationmethods           OK
nagios.nagios_contactnotifications                 OK
nagios.nagios_contacts                             OK
nagios.nagios_contactstatus                        OK
nagios.nagios_customvariables                      OK
nagios.nagios_customvariablestatus                 OK
nagios.nagios_dbversion                            OK
nagios.nagios_downtimehistory                      OK
nagios.nagios_eventhandlers                        OK
nagios.nagios_externalcommands                     OK
nagios.nagios_flappinghistory                      OK
nagios.nagios_host_contactgroups                   OK
nagios.nagios_host_contacts                        OK
nagios.nagios_host_parenthosts                     OK
nagios.nagios_hostchecks                           OK
nagios.nagios_hostdependencies                     OK
nagios.nagios_hostescalation_contactgroups         OK
nagios.nagios_hostescalation_contacts              OK
nagios.nagios_hostescalations                      OK
nagios.nagios_hostgroup_members                    OK
nagios.nagios_hostgroups                           OK
nagios.nagios_hosts                                OK
nagios.nagios_hoststatus                           OK
nagios.nagios_instances                            OK
nagios.nagios_logentries
Error    : Incorrect file format 'nagios_logentries'
error    : Corrupt
nagios.nagios_notifications                        OK
nagios.nagios_objects                              OK
nagios.nagios_processevents                        OK
nagios.nagios_programstatus                        OK
nagios.nagios_runtimevariables                     OK
nagios.nagios_scheduleddowntime                    OK
nagios.nagios_service_contactgroups                OK
nagios.nagios_service_contacts                     OK
nagios.nagios_service_parentservices               OK
nagios.nagios_servicechecks                        OK
nagios.nagios_servicedependencies                  OK
nagios.nagios_serviceescalation_contactgroups      OK
nagios.nagios_serviceescalation_contacts           OK
nagios.nagios_serviceescalations                   OK
nagios.nagios_servicegroup_members                 OK
nagios.nagios_servicegroups                        OK
nagios.nagios_services                             OK
nagios.nagios_servicestatus                        OK
nagios.nagios_statehistory                         OK
nagios.nagios_systemcommands                       OK
nagios.nagios_timedeventqueue                      OK
nagios.nagios_timedevents                          OK
nagios.nagios_timeperiod_timeranges                OK
nagios.nagios_timeperiods                          OK
nagiosql.tbl_command                               OK
nagiosql.tbl_contact                               OK
nagiosql.tbl_contactgroup                          OK
nagiosql.tbl_contacttemplate                       OK
nagiosql.tbl_domain                                OK
nagiosql.tbl_host                                  OK
nagiosql.tbl_hostdependency                        OK
nagiosql.tbl_hostescalation                        OK
nagiosql.tbl_hostextinfo                           OK
nagiosql.tbl_hostgroup                             OK
nagiosql.tbl_hosttemplate                          OK
nagiosql.tbl_info                                  OK
nagiosql.tbl_lnkContactToCommandHost               OK
nagiosql.tbl_lnkContactToCommandService            OK
nagiosql.tbl_lnkContactToContactgroup              OK
nagiosql.tbl_lnkContactToContacttemplate           OK
nagiosql.tbl_lnkContactToVariabledefinition        OK
nagiosql.tbl_lnkContactgroupToContact              OK
nagiosql.tbl_lnkContactgroupToContactgroup         OK
nagiosql.tbl_lnkContacttemplateToCommandHost       OK
nagiosql.tbl_lnkContacttemplateToCommandService    OK
nagiosql.tbl_lnkContacttemplateToContactgroup      OK
nagiosql.tbl_lnkContacttemplateToContacttemplate   OK
nagiosql.tbl_lnkContacttemplateToVariabledefinition OK
nagiosql.tbl_lnkHostToContact                      OK
nagiosql.tbl_lnkHostToContactgroup                 OK
nagiosql.tbl_lnkHostToHost                         OK
nagiosql.tbl_lnkHostToHostgroup                    OK
nagiosql.tbl_lnkHostToHosttemplate                 OK
nagiosql.tbl_lnkHostToVariabledefinition           OK
nagiosql.tbl_lnkHostdependencyToHost_DH            OK
nagiosql.tbl_lnkHostdependencyToHost_H             OK
nagiosql.tbl_lnkHostdependencyToHostgroup_DH       OK
nagiosql.tbl_lnkHostdependencyToHostgroup_H        OK
nagiosql.tbl_lnkHostescalationToContact            OK
nagiosql.tbl_lnkHostescalationToContactgroup       OK
nagiosql.tbl_lnkHostescalationToHost               OK
nagiosql.tbl_lnkHostescalationToHostgroup          OK
nagiosql.tbl_lnkHostgroupToHost                    OK
nagiosql.tbl_lnkHostgroupToHostgroup               OK
nagiosql.tbl_lnkHosttemplateToContact              OK
nagiosql.tbl_lnkHosttemplateToContactgroup         OK
nagiosql.tbl_lnkHosttemplateToHost                 OK
nagiosql.tbl_lnkHosttemplateToHostgroup            OK
nagiosql.tbl_lnkHosttemplateToHosttemplate         OK
nagiosql.tbl_lnkHosttemplateToVariabledefinition   OK
nagiosql.tbl_lnkServiceToContact                   OK
nagiosql.tbl_lnkServiceToContactgroup              OK
nagiosql.tbl_lnkServiceToHost                      OK
nagiosql.tbl_lnkServiceToHostgroup                 OK
nagiosql.tbl_lnkServiceToServicegroup              OK
nagiosql.tbl_lnkServiceToServicetemplate           OK
nagiosql.tbl_lnkServiceToVariabledefinition        OK
nagiosql.tbl_lnkServicedependencyToHost_DH         OK
nagiosql.tbl_lnkServicedependencyToHost_H          OK
nagiosql.tbl_lnkServicedependencyToHostgroup_DH    OK
nagiosql.tbl_lnkServicedependencyToHostgroup_H     OK
nagiosql.tbl_lnkServicedependencyToService_DS      OK
nagiosql.tbl_lnkServicedependencyToService_S       OK
nagiosql.tbl_lnkServiceescalationToContact         OK
nagiosql.tbl_lnkServiceescalationToContactgroup    OK
nagiosql.tbl_lnkServiceescalationToHost            OK
nagiosql.tbl_lnkServiceescalationToHostgroup       OK
nagiosql.tbl_lnkServiceescalationToService         OK
nagiosql.tbl_lnkServicegroupToService              OK
nagiosql.tbl_lnkServicegroupToServicegroup         OK
nagiosql.tbl_lnkServicetemplateToContact           OK
nagiosql.tbl_lnkServicetemplateToContactgroup      OK
nagiosql.tbl_lnkServicetemplateToHost              OK
nagiosql.tbl_lnkServicetemplateToHostgroup         OK
nagiosql.tbl_lnkServicetemplateToServicegroup      OK
nagiosql.tbl_lnkServicetemplateToServicetemplate   OK
nagiosql.tbl_lnkServicetemplateToVariabledefinition OK
nagiosql.tbl_lnkTimeperiodToTimeperiod             OK
nagiosql.tbl_logbook                               OK
nagiosql.tbl_mainmenu                              OK
nagiosql.tbl_service                               OK
nagiosql.tbl_servicedependency                     OK
nagiosql.tbl_serviceescalation                     OK
nagiosql.tbl_serviceextinfo                        OK
nagiosql.tbl_servicegroup                          OK
nagiosql.tbl_servicetemplate                       OK
nagiosql.tbl_settings                              OK
nagiosql.tbl_submenu                               OK
nagiosql.tbl_timedefinition                        OK
nagiosql.tbl_timeperiod                            OK
nagiosql.tbl_user                                  OK
nagiosql.tbl_variabledefinition                    OK

Repairing tables
nagios.nagios_logentries
Error    : Incorrect file format 'nagios_logentries'
error    : Corrupt

Re: Nagios XI upgradation issue

Posted: Thu Nov 26, 2015 6:56 pm
by Box293
Can you execute these commands please:

Code: Select all

mysql -pnagiosxi
use nagios;
repair table nagios_logentries use_frm;
quit;
Let us know the output of this.

Also, if it repairs OK, re-run the upgrade script now and let us know how it goes.

Re: Nagios XI upgradation issue

Posted: Fri Nov 27, 2015 3:31 am
by raamardhani7
Box293 wrote:Can you execute these commands please:

Code: Select all

mysql -pnagiosxi
use nagios;
repair table nagios_logentries use_frm;
quit;
Let us know the output of this.

Also, if it repairs OK, re-run the upgrade script now and let us know how it goes.

Code: Select all

mysql -pnagiosxi
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 2245
Server version: 5.1.73 Source distribution

Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> use nagios;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed
mysql> repair table nagios_logentries use_frm;
+--------------------------+--------+----------+-------------------------------------------------------------+
| Table                    | Op     | Msg_type | Msg_text                                                    |
+--------------------------+--------+----------+-------------------------------------------------------------+
| nagios.nagios_logentries | repair | error    | Can't create new tempfile: './nagios/nagios_logentries.TMD' |
| nagios.nagios_logentries | repair | status   | Operation failed                                            |
+--------------------------+--------+----------+-------------------------------------------------------------+
2 rows in set (0.00 sec)

mysql> quit;
Bye
This still throwing the error.. :(

Re: Nagios XI upgradation issue

Posted: Sun Nov 29, 2015 9:42 pm
by Box293
This sounds like a disk space issue.

I'll get you to check the amount of free disk space on your XI server. Type the following at the command prompt:

Code: Select all

df -h
df -i
If disk usage is your problem, run these commands to produce a breakdown of the directories at / (NOTE: This may take some time to finish).

Code: Select all

cd /
du -sh *
If you want to see more detail about a directory, cd into it and run the du -sh * command again.

If you need to add extra disk space you can follow this guide:

http://assets.nagios.com/downloads/nagi ... M_Disk.pdf

Re: Nagios XI upgradation issue

Posted: Mon Nov 30, 2015 12:25 am
by raamardhani7
Box293 wrote:This sounds like a disk space issue.

I'll get you to check the amount of free disk space on your XI server. Type the following at the command prompt:

Code: Select all

df -h
df -i
If disk usage is your problem, run these commands to produce a breakdown of the directories at / (NOTE: This may take some time to finish).

Code: Select all

cd /
du -sh *
If you want to see more detail about a directory, cd into it and run the du -sh * command again.

If you need to add extra disk space you can follow this guide:

http://assets.nagios.com/downloads/nagi ... M_Disk.pdf

Code: Select all

[root@lussvpnagiosxi00 ~]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/vg_uusrcdlsbx00-lv_root
                      215G  124G   81G  61% /
tmpfs                 7.8G     0  7.8G   0% /dev/shm
/dev/sda1             477M   99M  353M  22% /boot

Code: Select all

[root@lussvpnagiosxi00 ~]# df -i
Filesystem             Inodes   IUsed    IFree IUse% Mounted on
/dev/mapper/vg_uusrcdlsbx00-lv_root
                     14234416 2521427 11712989   18% /
tmpfs                 2041756       1  2041755    1% /dev/shm
/dev/sda1              128016      53   127963    1% /boot

Code: Select all

[root@lussvpnagiosxi00 ~]# cd /
[root@lussvpnagiosxi00 /]# du -sh *
0       &1
12K     backups
7.8M    bin
97M     boot
4.0K    cgroup
180K    dev
34M     etc
344K    home
386M    lib
28M     lib64
16K     lost+found
4.0K    media
4.0K    misc
4.0K    mnt
4.0K    net
23M     opt
du: cannot access `proc/14024/task/10559/fd/71': No such file or directory
du: cannot access `proc/14024/task/10559/fd/99': No such file or directory
du: cannot access `proc/14024/task/18082': No such file or directory
du: cannot access `proc/14024/task/18093': No such file or directory
du: cannot access `proc/14024/task/18104': No such file or directory
du: cannot access `proc/17092/task/17092/fd/4': No such file or directory
du: cannot access `proc/17092/task/17092/fdinfo/4': No such file or directory
du: cannot access `proc/17092/fd/4': No such file or directory
du: cannot access `proc/17092/fdinfo/4': No such file or directory
du: cannot access `proc/17447': No such file or directory
du: cannot access `proc/17813': No such file or directory
du: cannot access `proc/17814': No such file or directory
du: cannot access `proc/17818': No such file or directory
du: cannot access `proc/17841': No such file or directory
du: cannot access `proc/17842': No such file or directory
du: cannot access `proc/17850': No such file or directory
du: cannot access `proc/17852': No such file or directory
du: cannot access `proc/17857': No such file or directory
du: cannot access `proc/17873': No such file or directory
du: cannot access `proc/17887': No such file or directory
du: cannot access `proc/17892': No such file or directory
du: cannot access `proc/17893': No such file or directory
du: cannot access `proc/17894': No such file or directory
0       proc
936K    raamput
178M    root
15M     sbin
4.0K    selinux
4.0K    srv
318M    store
304K    storix
0       sys
8.3M    tmp
34G     usr
du: cannot access `var/spool/mqueue/dftAU5IJ6q022662': No such file or directory
du: cannot access `var/spool/mqueue/qftAU5IJ6q022662': No such file or directory
89G     var

Code: Select all

[root@lussvpnagiosxi00 /]# du -h / | grep '[0-9\.]\+G'
du: cannot access `/var/spool/clientmqueue/dftAU5KH4C016039': No such file or directory
du: cannot access `/var/spool/clientmqueue/qftAU5KH4C016039': No such file or directory
du: cannot access `/var/spool/mqueue/qftAU5KOOu017625': No such file or directory
8.2G    /var/spool/mqueue
9.9G    /var/spool
5.5G    /var/lib/mysql/nagios
5.6G    /var/lib/mysql
1.2G    /var/lib/pgsql/data
1.2G    /var/lib/pgsql
6.9G    /var/lib
72G     /var/log
89G     /var
204K    /usr/lib/vmware-tools/modules/binary/bld-2.4.21-306-i586smp4G-SLES8/objects
212K    /usr/lib/vmware-tools/modules/binary/bld-2.4.21-306-i586smp4G-SLES8
8.0K    /usr/local/tripwire/te/agent/jre/lib/locale/zh.GBK/LC_MESSAGES
12K     /usr/local/tripwire/te/agent/jre/lib/locale/zh.GBK
2.8G    /usr/local/nagios/var/spool/perfdata
2.8G    /usr/local/nagios/var/spool
4.2G    /usr/local/nagios/var/archives
7.3G    /usr/local/nagios/var
20M     /usr/local/nagios/share/perfdata/dalcbamp02-10GB1.fossil.com
20M     /usr/local/nagios/share/perfdata/DALCBCEP01-10G.fossil.com
20M     /usr/local/nagios/share/perfdata/DALCBCEP00-10G.fossil.com
20M     /usr/local/nagios/share/perfdata/dalcbamp02-10GB2.fossil.com
24G     /usr/local/nagios/share/perfdata
24G     /usr/local/nagios/share
31G     /usr/local/nagios
32G     /usr/local
20K     /usr/share/locale/zh_CN.GB2312/LC_MESSAGES
24K     /usr/share/locale/zh_CN.GB2312
1.1G    /usr/share
34G     /usr
du: cannot access `/proc/16045/task/16045/fd/4': No such file or directory
du: cannot access `/proc/16045/task/16045/fdinfo/4': No such file or directory
du: cannot access `/proc/16045/fd/4': No such file or directory
du: cannot access `/proc/16045/fdinfo/4': No such file or directory
du: cannot access `/proc/20896': No such file or directory
du: cannot access `/proc/20902': No such file or directory
du: cannot access `/proc/20903': No such file or directory
du: cannot access `/proc/20909': No such file or directory
du: cannot access `/proc/20912': No such file or directory
du: cannot access `/proc/20913': No such file or directory
du: cannot access `/proc/20914': No such file or directory
du: cannot access `/proc/20920': No such file or directory
du: cannot access `/proc/20939': No such file or directory
du: cannot access `/proc/20941': No such file or directory
du: cannot access `/proc/20942': No such file or directory
du: cannot access `/proc/20967': No such file or directory
du: cannot access `/proc/21005': No such file or directory
124G    /
/usr/local/nagios/share/perfdata/ there are lot of files in this files, acn these files be deleted? If I delete them will I have historical graphs? There is 80GB space still available..

Re: Nagios XI upgradation issue

Posted: Mon Nov 30, 2015 12:37 am
by Box293
raamardhani7 wrote:/usr/local/nagios/share/perfdata/ there are lot of files in this files, acn these files be deleted? If I delete them will I have historical graphs? There is 80GB space still available..
It does not appear that space is the issue.

If you delete the files in /usr/local/nagios/share/perfdata/ you will lose all of your historical performance data.

Try this:

Code: Select all

cd /var/lib/mysql/nagios/
mkdir /tmp/nagios_TMD
mv *.TMD /tmp/nagios_TMD/
mysql -pnagiosxi
use nagios;
repair table nagios_logentries use_frm;
quit;