Skip to main content
Question

Why the file /etc/cron.d/centreon is overwritten everytime Centreon is updated?

  • 5 June 2024
  • 3 replies
  • 23 views

Hi,

I observe this on Centreon 23.10 but this has been the case at least from 20.04.

On RHEL 8 a user modified config file usually generate a *.rpmnew file when a new version of the config file has to be installed, so the it’s possible to keep user modifications in place and eventually merging both files when it makes sens. 

Actually in this case there isn’t even a new version of this file. The update just overwrites it for nothing, this is annoying.

3 replies

Userlevel 6
Badge +20

Hi @Stéphane you right, /etc/cron.d/cent* are overwritten each time you update your Centreon platform.

If you want to add new cron, you can use cron module from Gorgone to do this.

Hi, thx for your answer.

>If you want to add new cron, you can use cron module from Gorgone to do this.

That’s an interesting link but I know how cron works and I find far more simple to add a cron job the natural way (legacy or via systemd). Anyway, what I’d like to be able to do is to is keep some of those cron jobs commented out or have them executed at the most preferable time for us, without having to edit this file at every update.

Again, my question is: why is it overwritten?

 

Userlevel 6
Badge +20

For historical reasons, Centreon uses files in /etc/cron.d/cent*.

We have in the past, and this is still true recently, added or deleted definitions.

To facilitate updating these crons, installing and updating Centreon overwrites this file.

I understand that this can be very annoying for those who have modified its definitions.

We plan to change this mechanism and put everything in Gorgon's cron format. This will provide more flexibility to activate/deactivate these crons and to change their frequency if needed.

Reply