Centreon – Logrotate hat Berechtigungsprobleme insecure permissions

Logrotate produziert folgende Meldung: error: skipping  „/var/log/centreon-broker/central-broker.log“ because parent directory has insecure permissions (It’s world writable or writable by group which is not „root“) Set „su“ directive in config file to tell logrotate which user/group should be used for rotation.

Mir ist aufgefallen das bei einem manuellen ausführen von logrotate über „logrotate -f /etc/logrotate.conf“ ein paar Fehler angezeigt werden:

error: skipping "/var/log/centreon-broker/central-broker.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive                                       in config file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon-broker/central-broker-master.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" dir                                      ective in config file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon-broker/central-module-master.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" dir                                      ective in config file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon-broker/central-rrd.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in                                       config file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon-broker/central-rrd-master.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" direct                                      ive in config file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon-broker/watchdog.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in con                                      fig file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon/centAcl.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in config file                                       to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon/centcore.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in config fil                                      e to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon/centreon-backup.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in con                                      fig file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon/centreon-partitioning.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive                                       in config file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon/centreon-purge.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in conf                                      ig file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon/dashboardBuilder.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in co                                      nfig file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon/downtimeManager.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in con                                      fig file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon/eventReportBuilder.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in                                       config file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon/knowledgebase.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in confi                                      g file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon/login.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in config file t                                      o tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon/nagiosPerfTrace.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in con                                      fig file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon/rrdtool.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in config file                                       to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/centreon/sql-error.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in config fi                                      le to tell logrotate which user/group should be used for rotation.

Problem: logrotate fehlt die Berechtigung um die Dateien anpacken zu dürfen.

Lösung: Wir geben Logrotate die passenden Berechtigungen. Hierzu muss die Datei „/etc/logrotate.d/cbd“ mit einem „su centreon-broker centreon-broker“ ergänzt werden:

/var/log/centreon-broker/*log {
    su centreon-broker centreon-broker
    compress
    daily
    notifempty
    missingok
    rotate 7
    size 100M
    copytruncate
}

Das gleiche mit der „/etc/logrotate.d/centreon“ Datei:

/var/log/centreon/*.log {
su centreon centreon
compress
daily
notifempty
copytruncate
missingok
rotate 7
size 20M
}

Letzte Kommentare

  1. Elliot 6. August 2017
    • Tobi 16. August 2017
  2. Dennis 16. August 2017

Hinterlasse einen Kommentar

*

https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_bye.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_good.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_negative.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_scratch.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_wacko.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_yahoo.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_cool.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_heart.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_rose.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_smile.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_whistle3.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_yes.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_cry.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_mail.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_sad.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_unsure.gif 
https://www.maffert.net/wp-content/plugins/wp-monalisa/icons/wpml_wink.gif