Have not yet done troubleshooting, but as you can see the log stopped rotating 6 days ago.
This system is now FreePBX 16, but had the same problem multiple times int he past on FreePBX 15. I previously posted about it in this thread.
I do not have a PM2 instance holding reload logs open this time.
sudo -u asterisk /usr/sbin/logrotate -s /var/lib/logrotate/logrotate.status /etc/logrotate.conf
Logrotate says it ran, but obviously not.
Ran updates. Nothing log related.
logrotate -v -f /etc/logrotate.conf
will effectively force (-f) and be verbose (-v) as it rotates all configured rotations in /etc/logrotate.d, chances are that you might need to add an ‘su asterisk asterisk’ directive in all your stanzas related to asterisk logs
No one said I wanted to rotate all the logs.
/var/lib/logrotate/logrotate.satus and backed the date up one point for
Edit: first try failed because I left a -d (debug switch in)
Then I ran logrotate again and it rotated them.
Whats the output of
The relevant section has the correct information.
The problem is that this is a recurring issue, but lograte itself has no logs.
Something is very obviously broken when
logrotate.status says the file was rotated, but it very obviosuly was not.
Side note… Permissions are wrong in
It is creating the new file as 640, but `fwconsole chown sets the file to 664
You can run individually anything in /etc/logrotate* with any arguments you choose and as any user.
But the ‘system’ (cron) will run logrotate as the root user
ls -l /etc/cron.daily/logrotate
whilst trouble shooting, I suggest you do exactly that ,i.e. as root, not asterisk. We see it used to run successfully at 04:02 until last week but now runs successfully and , presumably as asterisk, at your whim but not as a cron job.
So I rebooted last night after updates. Of course this will reset everything. But this is what I found this morning.
Found another system doing this today. This is getting really, really, really old.
What is the content of your
logrotate -v -f /etc/logrotate.d/asterisk
throw any oopsies?
This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.