Skip to main content
Question

Export configuration shortcut --> error

  • November 6, 2024
  • 6 replies
  • 361 views

Forum|alt.badge.img+2

Hi
Since upgrade from 24.04.5 to 24.04.7 the export shortcut does not work and tell me:

There was an consistency error in the exported files - please use the legacy export menu to troubleshoot

 

When I use legacy menu no error. If I us default admin account export shortcut work like a charm.

 

I'll try upgrade to 24.10 as my setup is quiet new, same bug.

 

Only error in log file :

[2024-11-06T16:18:06+0100] [ERROR] [Centreon\Application\Controller\Configuration\MonitoringServerController:233]: Generation error on monitoring server #3: Authentication token expired 
 

 

Thank you for helping

ponchoh
Centreonian
Forum|alt.badge.img+13
  • Centreonian
  • November 6, 2024

👋👋👋

 

Do you have the cron job enabled?

/etc/cron.d/centreon

 

##########################
# Cron for Outdated Token removal
* * * * * centreon /usr/share/centreon/cron/outdated-token-removal.php >> /var/log/centreon/centreon-tokens.log 2>&1


Forum|alt.badge.img+2
  • Steward *
  • November 6, 2024

Hi,

thank you for answer.

Cron is enabled but does not work, so i run manually as “centreon” user the php script, and got error opening “/var/log/centreon/sql-error.log” owned by www-data:centreon.

I chown centreon:centreon /var/log/centreon/sql-error.log run the cron and try export menu, and now all work again.

But is it good idea to chown this file? What the best practice, user and permission is little complicated in centreon installation :)?


ponchoh
Centreonian
Forum|alt.badge.img+13
  • Centreonian
  • November 6, 2024

Hello,

In this case I think we can do with the CHOWN, at some point the log got mixed or the folder. We do have this list but we might be missing some. I’ll put a request to include them. (MON-152344)

https://docs.centreon.com/docs/installation/technical/

 

If you have any recommendations please submit them to https://thewatch.centreon.com/ideas

 

Glad we got it working 😊


Forum|alt.badge.img+2
  • Steward *
  • November 20, 2024

Hi,

i’ve a strange behaviour…

The cron run fine every minute with no error but it seems does not work, as export menu does not work

 

##########################
# Cron for Outdated Token removal
* * * * * centreon /usr/share/centreon/cron/outdated-token-removal.php >> /var/log/centreon/centreon-tokens.log 2>&1

 

Log: 

2024-11-20T08:14:01.200702+01:00 banyan CRON[158542]: (centreon) CMD (/usr/share/centreon/cron/outdated-token-removal.php >> /var/log/centreon/centreon-tokens.log 2>&1)
 

 

 

If i run commande in shell the export menu work fine. Have you an idea?

sudo -u centreon /usr/share/centreon/cron/outdated-token-removal.php

 


ponchoh
Centreonian
Forum|alt.badge.img+13
  • Centreonian
  • November 20, 2024

@Lionel 

What are the rights of the token…. php

-rwxr-xr-x 1 centreon centreon

 

and the logs

 

-rw-r--r-- 1 centreon centreon

 

also with php in the cron

 

* * * * * centreon /usr/bin/php -q /usr/share/centreon/cron/outdated-token-removal.php

 

🤞


Forum|alt.badge.img+2
  • Steward *
  • November 21, 2024

Hi, thank you it was permission on the log file… change owner to centreon and all work great

Thank you.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings