CXS Cron hanging
CXS Cron hanging
Got an odd problem on the last server you guys set up.
The cxs daily cron will sometimes just hang and prevent the logrotate process from running. I'll notice it when I receive an email that /var is running out of drive space, due to logs growing in size.
If I kill the cxs cron, then logrotate will run. I've noticed this happening about 3 or 4 different times since last december. Just noticed it now, looks like it hung on 12 Jan 2014, the logs were rotated on the 11th and now that I killed the cron, the logs rotated today, 14 Jan.
Any idea what I should be looking for? I have cxs installed on all my shared servers and a couple more, maybe 8-10 servers and this is the only one that hangs. Current version is 4.10
The cxs daily cron will sometimes just hang and prevent the logrotate process from running. I'll notice it when I receive an email that /var is running out of drive space, due to logs growing in size.
If I kill the cxs cron, then logrotate will run. I've noticed this happening about 3 or 4 different times since last december. Just noticed it now, looks like it hung on 12 Jan 2014, the logs were rotated on the 11th and now that I killed the cron, the logs rotated today, 14 Jan.
Any idea what I should be looking for? I have cxs installed on all my shared servers and a couple more, maybe 8-10 servers and this is the only one that hangs. Current version is 4.10
-
- Moderator
- Posts: 1524
- Joined: 01 Oct 2008, 09:24
Re: CXS Cron hanging
We'll look at adding a timeout. For now, if you edit the script and place a space then an ampersand " &" at the end of each cxs line in /etc/cxs/cxsdaily.sh it should fork the process and not block the cron job.
Re: CXS Cron hanging
Thanks for the fix and quick repy!
Re: CXS Cron hanging
Added the space ampersand and it hung again, stopping the other daily crons:
/usr/sbin/cxs --upgrade --quiet &
/usr/sbin/cxs --qclean 7 --quarantine /home/quarantine --quiet &
are the two lines that aren't remarked out. I modified it on the 15th, worked on the 16th, then on the 17th, it hung again, killing the process allowed the other crons to run.
/usr/sbin/cxs --upgrade --quiet &
/usr/sbin/cxs --qclean 7 --quarantine /home/quarantine --quiet &
are the two lines that aren't remarked out. I modified it on the 15th, worked on the 16th, then on the 17th, it hung again, killing the process allowed the other crons to run.
-
- Moderator
- Posts: 1524
- Joined: 01 Oct 2008, 09:24
Re: CXS Cron hanging
It might help if you could log a ticket with access details when the process hangs again so we can look at it, if possible. We'll keep looking into possible causes, though.
-
- Moderator
- Posts: 1524
- Joined: 01 Oct 2008, 09:24
Re: CXS Cron hanging
Additionally, to prevent it hanging your daily cron you might want to remove the current jobs and add them via:
And schedule them for some time convenient to you. It may still hang, but should not hold anything up.
Code: Select all
crontab -e
-
- Moderator
- Posts: 1524
- Joined: 01 Oct 2008, 09:24
Re: CXS Cron hanging
We were able to recreate the problem. This should hopefully now be fixed once you are running on v4.14:
http://blog.configserver.com/
http://blog.configserver.com/
Re: CXS Cron hanging
That was quick, thanks. I'll let you know if it happens again.
Re: CXS Cron hanging
This hasn't happened since I updated to 4.14, so the fix is working.
-
- Moderator
- Posts: 1524
- Joined: 01 Oct 2008, 09:24
Re: CXS Cron hanging
Thank you for the follow-up, glad to hear it