Offloading MySQL on Nagios XI 5.8.6

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
User avatar
dmcingenieria
Posts: 5
Joined: Thu Mar 29, 2018 8:30 pm
Contact:

Offloading MySQL on Nagios XI 5.8.6

Post by dmcingenieria »

After running the process in the documentation to move the database out of NagiosXI, the current status for hosts and services in the CCM is "Not Applied", regardless of whether a host and services was added and successfully applied, but still in the CCM in the same "Not Applied" status.

I don't see errors on logs, could you know why?

NagiosBox: OracleLinux 8, NagiosXI 5.8.6.
Host with Database: OracleLinux 8, mariadb-10.3.28-1.

https://assets.nagios.com/downloads/nag ... Server.pdf
You do not have the required permissions to view the files attached to this post.
--
dmci.co
benjaminsmith
Posts: 5324
Joined: Wed Aug 22, 2018 4:39 pm
Location: saint paul

Re: Offloading MySQL on Nagios XI 5.8.6

Post by benjaminsmith »

Hi,

Not fully sure why it wouldn't be in the logs, but there may be a configuration error in the current nagiosql database preventing the configuration from applying and it's reverting back to a previous snapshot that works.

Try running the following tail command, then apply configuration and post the output to the thread.

Code: Select all

tail -f /usr/local/nagiosxi/var/cmdsubsys.log
Also, please PM the system profile along with the database log from the remote server, and we'll review the logs for any errors. Thanks, Benjamin

To send us your system profile.
Login to the Nagios XI GUI using a web browser.
Click the "Admin" > "System Profile" Menu
Click the "Download Profile" button
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.

Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
dmcingenieria
Posts: 5
Joined: Thu Mar 29, 2018 8:30 pm
Contact:

Re: Offloading MySQL on Nagios XI 5.8.6

Post by dmcingenieria »

No error in the configuration, was applied successfully the configuration and the new nodes are created without errors. But from ccm still getting 'Not applied' and the nodes are not in the 'service status' dashboard.

The nodes are there when I check it from the nagios core url:
/nagiosxi/includes/components/nagioscore/ui/extinfo.php?type=1&host=host917

But From the nagiosxi url the host doesn't exist:
/nagiosxi/includes/components/xicore/status.php?show=hostdetail&host=host917
"Object Does Not Exist"

I have attached the log output. And no errors from the database log.

The nagiosxi is an installation from scratch,
NagiosXI host:
Oracle Linux 8
Nagios XI 5.8.6


NagiosDB:
Oracle Linux 8
mariadb-server-10.3.28-1
You do not have the required permissions to view the files attached to this post.
--
dmci.co
benjaminsmith
Posts: 5324
Joined: Wed Aug 22, 2018 4:39 pm
Location: saint paul

Re: Offloading MySQL on Nagios XI 5.8.6

Post by benjaminsmith »

Hi,

Thank you for the detailed summary. I believe you have a database issue since the Core interface is working. Please run the repair script as root, and let me know if the issue is resolved.

Code: Select all

/usr/local/nagiosxi/scripts/repair_databases.sh
If that does not resolve the error, please send us the system profile and the /etc/my.cnf file.

To send us your system profile.
Login to the Nagios XI GUI using a web browser.
Click the "Admin" > "System Profile" Menu
Click the "Download Profile" button

Regards,
Benjamin
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.

Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
dmcingenieria
Posts: 5
Joined: Thu Mar 29, 2018 8:30 pm
Contact:

Re: Offloading MySQL on Nagios XI 5.8.6

Post by dmcingenieria »

Hello,

Sorry for the delay, we reimport the databases and now is working, the hosts and services imported are showed as applied in the ccm.

also when I ran the repair_databases.sh command I got errors on the nagiosql and nagiosxi databases : "note : The storage engine for the table doesn't support repair", No errors on nagios db.

The only differences that I can see is the databases were created with 'collation': 'utf8_general_ci', 'encoding': 'utf8', but in the nagiosxi server the nagiosxi database was created collation: utf8mb4_0900_ai_ci and encoding: utf8mb4, I have to worry about this?

The engine used is mariadb-server-10.3.28-1.

I sent the system profile on dm.
--
dmci.co
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: Offloading MySQL on Nagios XI 5.8.6

Post by ssax »

note : The storage engine for the table doesn't support repair
That's just a notice and should be ignored, that means they are InnoDB tables instead of MyISAM tables.

Since you're running MariaDB 10+ you'll need to adjust your sql_mode as well if you haven't yet:

https://support.nagios.com/kb/article/n ... n-822.html

You shouldn't have to worry about the collation differences, they are different in MariaDB 10+ as you've found. If everything is working properly and updating in the DB then you should be good to go.

Here's how I validate things are working properly after an upgrade, migration, DB offload, etc:

Go to Home > Host Status:
- Make sure things are showing up
- Click on a host and force a check, make sure the date/time changes
- Click the + tab and submit a passive DOWN check result, make sure it submits properly and the date/time/output changes AND that you receive a host down notification

Go to Admin > System Status and make sure everything shows green.

Go to Admin > Monitoring Engine Status:
- Make sure the graph on the right shows up (can indicate invalid SSL setup)
- Make sure the items on the left show green
- Click one of the gray X to to disable, refresh the page to make sure it shows disabled, then re-enable it.

Apply Configuration and make sure it succeeds.

Make sure things are showing up in Home > Service Status.

That entire process tests a lot of different things with communication between the frontend and backend and is what I use to validate customers systems are generally working properly.
Locked