Tâche #34153
Scénario #34096: EOLE 2.9 : warning logrotate sur Amon
Étude
Statut:
Fermé
Priorité:
Normal
Assigné à:
Version cible:
Début:
09/05/2022
Echéance:
% réalisé:
100%
Restant à faire (heures):
0.0
Demandes liées
Révisions associées
Supprimer l’option size en conflit avec l’option daily.
Ref #34153
Historique
#1 Mis à jour par Benjamin Bohard il y a presque 2 ans
- Statut changé de Nouveau à En cours
#2 Mis à jour par Benjamin Bohard il y a presque 2 ans
Les deux options incompatibles (size et daily) cohabitent néanmoins depuis 2015.
A priori, l’option ifempty devrait suffire à s’assurer que la rotation est effectuée tous les jours (et nécessaire parce que ifnotempty est déclarée globalement).
#3 Mis à jour par Benjamin Bohard il y a presque 2 ans
Avec les deux options :
rotating pattern: /var/log/rsyslog/local/e2guardian/*.log forced from command line (365 rotations) empty log files are rotated, old logs are removed switching euid from 0 to 0 and egid from 0 to 4 (pid 5191) considering log /var/log/rsyslog/local/e2guardian/e2guardian0.info.log Now: 2022-05-11 14:33 Last rotated at 2022-05-11 14:32 log needs rotating considering log /var/log/rsyslog/local/e2guardian/e2guardian2.err.log Now: 2022-05-11 14:33 Last rotated at 2022-05-11 14:32 log needs rotating considering log /var/log/rsyslog/local/e2guardian/e2guardian2.info.log Now: 2022-05-11 14:33 Last rotated at 2022-05-11 14:32 log needs rotating
Sans l’option size :
rotating pattern: /var/log/rsyslog/local/e2guardian/*.log forced from command line (365 rotations) empty log files are rotated, old logs are removed switching euid from 0 to 0 and egid from 0 to 4 (pid 5501) considering log /var/log/rsyslog/local/e2guardian/e2guardian0.info.log Now: 2022-05-11 14:37 Last rotated at 2022-05-11 14:33 log needs rotating considering log /var/log/rsyslog/local/e2guardian/e2guardian2.err.log Now: 2022-05-11 14:37 Last rotated at 2022-05-11 14:33 log needs rotating considering log /var/log/rsyslog/local/e2guardian/e2guardian2.info.log Now: 2022-05-11 14:37 Last rotated at 2022-05-11 14:33 log needs rotating
Sans l’option ifempty (et avec l’option resize 0) :
rotating pattern: /var/log/rsyslog/local/e2guardian/*.log forced from command line (365 rotations) empty log files are not rotated, old logs are removed switching euid from 0 to 0 and egid from 0 to 4 (pid 5709) considering log /var/log/rsyslog/local/e2guardian/e2guardian0.info.log Now: 2022-05-11 14:40 Last rotated at 2022-05-11 14:37 log does not need rotating (log is empty) considering log /var/log/rsyslog/local/e2guardian/e2guardian2.err.log Now: 2022-05-11 14:40 Last rotated at 2022-05-11 14:37 log does not need rotating (log is empty) considering log /var/log/rsyslog/local/e2guardian/e2guardian2.info.log Now: 2022-05-11 14:40 Last rotated at 2022-05-11 14:37 log does not need rotating (log is empty) not running postrotate script, since no logs were rotated switching euid from 0 to 0 and egid from 4 to 0 (pid 5709)
La combinaison des options ifempty (pour surcharger l’option globale notifempty) et daily semblent donc répondre à la problématique de rotation tous les jours même en cas de fichier vide.
#4 Mis à jour par Benjamin Bohard il y a presque 2 ans
- Lié à Tâche #13349: fichier de log pas forcement "rotate" ajouté
#5 Mis à jour par Benjamin Bohard il y a presque 2 ans
- Statut changé de En cours à À valider
#6 Mis à jour par Laurent Gourvenec il y a presque 2 ans
- Statut changé de À valider à Résolu
#7 Mis à jour par Laurent Gourvenec il y a presque 2 ans
- % réalisé changé de 0 à 100
#8 Mis à jour par Joël Cuissinat il y a presque 2 ans
eole-proxy$ git branch -r --contains c3158a53 origin/2.8.1/master origin/HEAD -> origin/master origin/dist/eole/2.8.1/master origin/dist/eole/2.9.0/master origin/master
#9 Mis à jour par Joël Cuissinat il y a presque 2 ans
- Statut changé de Résolu à Fermé
- Restant à faire (heures) mis à 0.0