NagiosXI Slowness and Database error

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
apteancloud
Posts: 47
Joined: Wed Sep 09, 2020 4:05 am

NagiosXI Slowness and Database error

Post by apteancloud »

Hi Team,

We have deployed NagiosXI on Linux (ubuntu 18.04) Azure VM(4 vcpus, 16 GiB memory) and we are monitoring around 4600 services on it. Upon making any changes in CCM and saving, we are getting page unresponsive and database error.

Even after running the database repair script, the Page is either unresponsive or we get the database error. Not sure if I have to clean some cache/logs on the server.

Could you guys please suggest your inputs to fix this issue.

Thanks,
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: NagiosXI Slowness and Database error

Post by ssax »

Please PM me a copy of your profile, you can download it from Admin > System Profile by clicking the Download Profile button.

If you're unable to generate the the profile through the web interface, please try generating it from the command line by running these commands as root:

Code: Select all

rm -rf /usr/local/nagiosxi/var/components/profile*​​
/usr/local/nagiosxi/scripts/components/getprofile.sh SUPPORT
Then send me the resulting /usr/local/nagiosxi/var/components/profile.zip​ file.​

If the profile script fails, please include the ENTIRE output.

Additionally, please send the output of these commands:
- NOTE: You may need to adjust the -h 127.0.0.1, the -uroot, and -pnagiosxi in the first command if your DB is offloaded to another server and/or you've changed the root mysql password

Code: Select all

echo "SELECT table_name AS 'Table', round(((data_length + index_length) / 1024 / 1024), 2) 'Size in MB' FROM information_schema.TABLES WHERE table_schema IN ('nagios', 'nagiosql', 'nagiosxi');" | mysql -h 127.0.0.1 -uroot -pnagiosxi --table
This next command may fail, that's okay, not all systems run postgresql, send the output anyways:

Code: Select all

echo "SELECT relname as Table, pg_size_pretty(pg_total_relation_size(relid)) As Size, pg_size_pretty(pg_total_relation_size(relid) - pg_relation_size(relid)) as ExternalSize FROM pg_catalog.pg_statio_user_tables ORDER BY pg_total_relation_size(relid) DESC;" | psql nagiosxi nagiosxi
Check your free space as well:

Code: Select all

df -h
df -i
apteancloud
Posts: 47
Joined: Wed Sep 09, 2020 4:05 am

Re: NagiosXI Slowness and Database error

Post by apteancloud »

Hi Ssax,

Sorry for the delayed response, I have sent PM containing all the details you've asked for. Please, check and review. Thanks in Advance.

Thanks,
Vishwas BS
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: NagiosXI Slowness and Database error

Post by ssax »

Please edit this file:

Code: Select all

/usr/local/nagiosxi/html/config.inc.php
Change this:

Code: Select all

        "charset" => "latin1",
To this:

Code: Select all

        "charset" => "utf8",
Have you tried rebooting the server?

Code: Select all

2021-01-27T14:12:19.185386Z 0 [Note] InnoDB: page_cleaner: 1000ms intended loop took 11333ms. The settings might not be optimal. (flushed=3 and evicted=0, during the time.)
2021-01-27T14:21:44.038405Z 2036295 [Note] Aborted connection 2036295 to db: 'nagios' user: 'ndoutils' host: 'localhost' (Got an error reading communication packets)
2021-01-27T14:21:44.038786Z 2028982 [Note] Aborted connection 2028982 to db: 'nagios' user: 'ndoutils' host: 'localhost' (Got an error reading communication packets)
Please PM me your /var/log/mysqld.log.

Additionally, please try disabling kaspersky on that system to see if that resolves it, I have a feeling it's related to that because it's trying to scan everything.
apteancloud
Posts: 47
Joined: Wed Sep 09, 2020 4:05 am

Re: NagiosXI Slowness and Database error

Post by apteancloud »

Hi Ssax,

Thanks for the update. I have sent details of /var/log directory. Please, check and suggest if clean is needed

Thanks,
Vishwas BS
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: NagiosXI Slowness and Database error

Post by ssax »

Did you do this?
Additionally, please try disabling kaspersky on that system to see if that resolves it, I have a feeling it's related to that because it's trying to scan everything.
Please send me your /var/log/mysql/error.log. You can get it with WinSCP.
Locked