Migration to mysql failing because table 'nagios.xi_banner_messages' doesn't exist
- espaanbroek
- Posts: 6
- Joined: Tue Apr 03, 2018 1:54 am
- Location: Dordrecht, The Netherlands
- Contact:
Migration to mysql failing because table 'nagios.xi_banner_messages' doesn't exist
Today we've upgraded from 5.9 to 5.11 and started the migration from postgresql to mysql as described on https://support.nagios.com/kb/article/c ... i-560.html.
After this everything seems to work, but we see the following message in the top of every screen:
SQL Error [nagiosxi] Table 'nagios.xi_banner_messages' doesn't exist
As we couldn't find any messages about this problem we turned back the migration to mysql and running on postgresql again.
What do we have to do to succesfully migrate to postgresql and get rid of the disturbing message about the deprecation?
After this everything seems to work, but we see the following message in the top of every screen:
SQL Error [nagiosxi] Table 'nagios.xi_banner_messages' doesn't exist
As we couldn't find any messages about this problem we turned back the migration to mysql and running on postgresql again.
What do we have to do to succesfully migrate to postgresql and get rid of the disturbing message about the deprecation?
Re: Migration to mysql failing because table 'nagios.xi_banner_messages' doesn't exist
Maybe try searching the internet for similar messages and see what others did.
- espaanbroek
- Posts: 6
- Joined: Tue Apr 03, 2018 1:54 am
- Location: Dordrecht, The Netherlands
- Contact:
Re: Migration to mysql failing because table 'nagios.xi_banner_messages' doesn't exist
5.11.1 was released yesterday, maybe try 5.11.1 to see if you're experiencing the same problem.
Re: Migration to mysql failing because table 'nagios.xi_banner_messages' doesn't exist
we solve this issue dumping the empty xi_banner_messages table from a new instalation and import the dump to create the missing table on the old instalation, now Nagios working ok again.
I'm attach the sql file with the missing table data:
to fix this issue:
1) connect to the mysql db server used by nagiosxi
mysql -uroot -p
[enter de password]
2) open nagiosxi DB
user nagiosxi;
3) import .sql
source /path/to/file/xi_banner_messages.sql ;
exit;
and check nagiosxi again
I'm attach the sql file with the missing table data:
to fix this issue:
1) connect to the mysql db server used by nagiosxi
mysql -uroot -p
[enter de password]
2) open nagiosxi DB
user nagiosxi;
3) import .sql
source /path/to/file/xi_banner_messages.sql ;
exit;
and check nagiosxi again
You do not have the required permissions to view the files attached to this post.
Re: Migration to mysql failing because table 'nagios.xi_banner_messages' doesn't exist
Just to add to this solution since I wasn't exactly sure of the exact .sql destination, I downloaded the xi_banner_messages.sql file to my PC, and then uploaded it to the /tmp/ directory on nagiosxi via WinSCP. I then used a command from the link in one of the previous replies to import it to the default location, which resolved my issue;
Code: Select all
cd /tmp/
Code: Select all
mysql -uroot -pnagiosxi -Dnagiosxi < xi_banner_messages.sql
Re: Migration to mysql failing because table 'nagios.xi_banner_messages' doesn't exist
To fix this issue, we can insert the tables manually. To do so
1: connect to the mysql db in a terminal
mysql -u root -p
{password for db}
2: Copy this sql query into the terminal.
Check your nagios Xi instance and this should have fixed the issue. We will look into the issue to see why the table wasn't inserted on the conversion.
1: connect to the mysql db in a terminal
mysql -u root -p
{password for db}
2: Copy this sql query into the terminal.
Code: Select all
CREATE TABLE IF NOT EXISTS `nagiosxi`.`xi_banner_messages` (
`msg_id` int auto_increment,
`message` varchar(2500) NOT NULL default '',
`time_created` datetime,
`created_by` int NOT NULL default 0,
`acknowledgeable` BOOLEAN default 1,
`specify_users` BOOLEAN default 0,
`banner_color` varchar(40) default 'banner_message_banner_info',
`message_active` BOOLEAN default 1,
`start_date` DATE default '0001-01-01',
`end_date` DATE default '0001-01-01',
`feature_active` BOOLEAN default 1,
`schedule_message` BOOLEAN default 0,
primary key (`msg_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=1;
CREATE TABLE IF NOT EXISTS `nagiosxi`.`xi_link_users_messages` (
`id` int auto_increment,
`msg_id` int NOT NULL,
`user_id` int NOT NULL,
`acknowledged` BOOLEAN default 0,
`specified` BOOLEAN default 0,
primary key (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=1;
Re: Migration to mysql failing because table 'nagios.xi_banner_messages' doesn't exist
After making any changes to the database or the configuration, it's a good practice to clear any caches that Nagios XI might be using. This can help refresh the application's view of the database. You can often do this from the Nagios XI web interface or by running a command provided by the Nagios XI documentation.espaanbroek wrote: ↑Wed Jun 28, 2023 10:22 am Today we've upgraded from 5.9 to 5.11 and started the migration from postgresql to mysql as described on https://support.nagios.com/kb/article/c ... i-560.html fnf
After this everything seems to work, but we see the following message in the top of every screen:
SQL Error [nagiosxi] Table 'nagios.xi_banner_messages' doesn't exist
As we couldn't find any messages about this problem we turned back the migration to mysql and running on postgresql again.
What do we have to do to succesfully migrate to postgresql and get rid of the disturbing message about the deprecation?