
No estoy seguro de por qué este archivo en particular no se rota. No es un directorio. ¿Algunas ideas?
El tamaño del archivo firewalld:
$ ls -alh /var/log
-rw-r--r--. 1 root root 134M Jan 31 13:49 firewalld
La estrofa relevante de /etc/logrotate.conf:
/var/log/firewalld {
hourly
copytruncate
maxsize 1M
missingok
rotate 8
compress
notifempty
nomail
noolddir
}
El comando ejecutado:
$ sudo logrotate -fv /etc/logrotate.conf
rotating pattern: /var/log/firewalld forced from command line (8 rotations)
empty log files are not rotated, log files >= 1048576 are rotated earlier, old logs are removed
No logs found. Rotation not needed.
set default create context
El tamaño resultante del archivo firewalld:
$ ls -alh /var/log
-rw-r--r--. 1 root root 134M Jan 31 13:49 firewalld
Respuesta1
Encontré la respuesta en esta publicación:https://stackoverflow.com/posts/43398163/timeline
Aparentemente, el modificador -v es el mismo que el modificador -n; en otras palabras, el v-switch en realidad no permitirá que logrotate rote los registros.