For my logfiles I have the problem of all but one (or a few) files use the same configuration, while the rest has another one. I tried to realize this by giving a general configuration for all files and then overwriting this configuration for the few specific files later, e.g.:
/var/log/mylogs/*.log {
size 1000k
copytruncate
create 0644 root root
rotate 99
compress
missingok
}
/var/log/mylogs/thatonespecial.log {
size 1000k
copytruncate
create 0644 myuser mygroup
rotate 99
compress
missingok
}
However, this raises an error:
error: /var/log/mylogs/logrotate.conf:10 duplicate log entry for /var/log/mylogs/thatonespecial.log
How should I handle such a situation properly? I certainly don't want to list the large number of standard log files individually, so the use of the wildcard configuration seems reasonable to me. But how can I then specify an exception among the wildcarded files?