What type of hardware are you using: Raspberry Pi 3, 4+ What YunoHost version are you running: 12.1.39 How are you able to access your server: The webadmin
SSH Are you in a special context or did you perform specific tweaking on your YunoHost instance ?: nothing special
I want to personalise fail2ban and adding new rules. Searching for logs files location, I discover in /var/log/nginx/ that there are access.log, error.log etc… but there size is 0 and the files access.log.1, error.log.1 are gradually growing in size. Does my logrotate service running correctly?
More, fail2ban monitores the empty files.
How can I correct all that?
Share relevant logs or error messages
sudo ls -al /var/log/nginx/
total 24128
drwxr-xr-x+ 2 root adm 4096 May 17 12:44 .
drwxr-xr-x 17 root root 4096 May 17 00:00 ..
-rw-r----- 1 www-data adm 0 May 10 00:00 access.log
-rw-r----- 1 www-data adm 4011431 May 17 17:28 access.log.1
-rw-r----- 1 www-data adm 1072011 May 9 18:17 access.log.2.gz
-rw-r----- 1 www-data adm 517890 Mar 20 06:24 access.log.3.gz
-rw-r----- 1 www-data adm 66655 Feb 17 20:14 access.log.4.gz
-rw-r----- 1 www-data adm 0 May 10 00:00 error.log
-rw-r----- 1 www-data adm 72205 May 17 14:27 error.log.1
-rw-r----- 1 www-data adm 32258 May 9 18:10 error.log.2.gz
-rw-r----- 1 www-data adm 20628 Mar 20 06:09 error.log.3.gz
-rw-r----- 1 www-data adm 3467 Feb 17 20:10 error.log.4.gz
warning: logrotate in debug mode does nothing except printing debug messages! Consider using verbose mode (-v) instead if this is not what you want.
reading config file /etc/logrotate.d/nginx
Reading state from file: /var/lib/logrotate/status
Allocating hash table for state file, size 64 entries
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Creating new state
Handling 1 logs
rotating pattern: /var/log/nginx/*.log after 1 days (14 rotations)
empty log files are not rotated, old logs are removed considering log /var/log/nginx/access.log Now: 2026-05-17 20:01 Last rotated at 2026-05-10 00:00 log does not need rotating (log is empty) considering log /var/log/nginx/error.log Now: 2026-05-17 20:01 Last rotated at 2026-05-10 00:00 log does not need rotating (log is empty) ... not running prerotate script, since no logs will be rotated not running postrotate script, since no logs were rotated