z

Commercial Support Clients: Clients with support contracts can get escalated support assistance by visiting Nagios Answer Hub. These forums are for community support services. Although we at Nagios try our best to help out on the forums here, we always give priority support to our support clients.

Corrupted DB

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.

Corrupted DB

Postby rodrigojuarez » Wed Jan 25, 2023 11:54 am

I was tasked with the migration of some objects from one installation to another.

While doing so, I found out some configuration file's file names had tabulator characters in their name, so I'm blaming that as the reason.

Now there are issues with both hosts and services names, some being garbled, some without names, some of them have time period definition's as names and some others have contact group's names as names.

When clicked, the ones that have names, they show "Object Does Not Exist".

I already ran mysqlcheck and the tables showed either "Ok" or "The storage engine for the table doesn't support repair", depending on the database.

Short than scraping the server and starting from scratch again, what can I do?

Thanks in advance.
rodrigojuarez
 
Posts: 12
Joined: Tue Jan 17, 2023 5:26 pm

Re: Corrupted DB

Postby gormank » Wed Jan 25, 2023 1:19 pm

Since CCM writes the .cfg files I use only underscores and alphanumeric chars in object names. One thing to keep in mind is if a host/service is to be defined, you want to make sure it's subobjects (templates, hostgroups, etc.) are defined first.
How did you migrate the objects?
gormank
 
Posts: 1125
Joined: Tue Dec 02, 2014 12:00 pm

Re: Corrupted DB

Postby rodrigojuarez » Thu Jan 26, 2023 5:36 pm

Hello gormank.

Yes, I usually only use alphanumeric characters but this server was already there.

I didn't notice the problem with the characters until there was garbage in the hosts and services.

What I did was to copy the contents of /usr/local/nagios/hosts and /usr/local/nagios/services directories over from the old server.

Unfortunately the errors piled up enough for the server to be trustworthy so I scrapped it.

I'm in the process of doing it over again with the previos problems fixed beforehand.

Thanks for your response.
rodrigojuarez
 
Posts: 12
Joined: Tue Jan 17, 2023 5:26 pm

Re: Corrupted DB

Postby gormank » Thu Jan 26, 2023 6:39 pm

If you're using XI you can't just copy the files. You'd need to copy them to the import dir and run apply changes or run the reconfigure script.
gormank
 
Posts: 1125
Joined: Tue Dec 02, 2014 12:00 pm


Return to Nagios XI

Who is online

Users browsing this forum: Google [Bot] and 24 guests