Skip to main content

Hi,

I’m trying to change my centreon database to a external one. I have alredy exported my centreon.sql and imported in the new remote server (a debian, with mariadb).

I have created a centreon user o my remote bbdd and changed the /etc/centreon/centreon.conf.php file of my central server.

I have changed the hostCentstorage to my remote server IP and the password parameter but it doesnt work.

Any ideas? I havent seen much documentation or topics created on the forum about this….

  1. Edit the /etc/centreon/centreon.conf.php file,
  2. Edit the /etc/centreon/conf.pm file,
  3. Edit the Centreon Broker central configuration using Centreon web interface and change the password for the Perfdata generator and Broker SQL database output,
  4. Edit the /etc/centreon/config.d/10-database.yaml file.

 

https://docs.centreon.com/21.04/en/migrate/migrate-from-20-x.html


Hi, thank you so much for your reply!

But I still cant connect… I have done all the points except the 3rd one. You say I have to change it in the web but I dont have access.

Do you refer that I have to change the /etc/centreon-broker/central-broker.json?

I get this error:

 


I autoresponse my question. I solved the error. But I have another one...

I solved the rror creating another centreon user but with @’%’ instead of @’localhos’ to allow remote connections.

BUT now I have a ‘database issue’ in my centreon web (however everything works fine)

 


Hi,
In Configuration > Pollers > Broker configuration,

Open “central-broker-master” and in the “Output” tab, you have to change the “DB host”.
Set the new IP address and maybe verify user & password (if changed)

After these modifications, export configuration to the central server and restart Centreon-Engine & Centreon-Broker


I have done this but it still appears the database issue (I have also exported conf and reloaded every process) ...Above they told me something about the perfdata generator, but I dont find it, maybe can be that?

 

Anyway thankyou because now I have that db host correctly configured.


Maybe you can check:

  1. I think you can check first in centengine.log if cbmod.so is initialized correctly
  2. Then, check if cbd process is correctly started (or try to restart it)
  3. And after, check broker’s log (maybe in /var/log/centreon-broker/ , if default path has not changed)

In the 3. point /var/log/centreon-broker I get this error:

[2023-01-11T14:18:24.008+01:00] [sql] [error] mysql_connection: error while starting connection
[2023-01-11T14:18:24.008+01:00] [core] [error] failover: global error: mysql_connection: error while starting connection
 

Ou no, I get an error Access denied for user centreon@’myserver’ on my db server….


There was a password issue, I hace change it and now everything workds, thankyou so much!


Reply