What's new

crontab loss

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

This is almost certainly what happened, many cron entries to start services needs an ntp time synch, or they fail.

I learned this the hard way after RMerlin integrated stubby / DoT. trying to customize stubby they way I had it when stubby was an add on. Ntp never synched, and my router was a mess, missing many cron entries. Took me the better part of a day to figure out why.. :oops: o_O :rolleyes:
Could be worse, a family member could have decided to "reboot" your router "the old way" and corrupt your hard drive. (this happen to me a while back, lost alot of important stuff..always backup and backup again.)
 
Back to this issue again, so on reboots, I am still suffering from functions cru a not being added to the list of cron jobs. I test this because after each reboot I run Cru l to see cronjobs listed. The only ones I see getting added are the ones for Diversion and Skynet. other programs I am running is Scribe, connmon, ntpmerlin, uidiv, and uiscribe. note the scripts that are being affected are Scribe, connmon, ntpmerlin, uidiv, and uiscribe, these scripts cron jobs are occasionally on reboot, not getting added. I have no other scripts or programs running that could be preventing or holding the router from adding these.
 
Last edited:
Back to this issue again, so on reboots, I am still suffering from functions cru a not being added to the list of cron jobs. I test this because after each reboot I run Cru l to see cronjobs listed. The only ones I see getting added are the ones for Diversion and Skynet. other programs I am running is Scribe, connmon, ntpmerlin, uidiv, and uiscribe. note the scripts that are being affected are Scribe, connmon, ntpmerlin, uidiv, and uiscribe, these scripts cron jobs are occasionally on reboot, not getting added. I have no other scripts or programs running that could be preventing or holding the router from adding these.
Anything wrong with your services-start file out of interest?
 
What should the permissions look like for the file?
755

This is the permissions when using the long directory command:

Code:
-rwxr-xr-x
 
Anything wrong with your services-start file out of interest?
Code:
#!/bin/sh
/jffs/scripts/connmon startup # connmon
/jffs/scripts/ntpmerlin startup # ntpMerlin
/jffs/scripts/uiDivStats startup # uiDivStats
/jffs/scripts/uiScribe startup # uiScribe
this is what services-start looks like
 
SO i deleted all of the Jackyaz Collectables, and deleted any directories linked to it. then I redid the permissions, on the basic start files (i.e. services-start) because there were some scripts with messed up permissions, then I went back and reinstalled everything. I will see now if everything will behave properly.
 
I have also the problem of losing my cronjobs. From 21 to 3 sometimes. (RT-AX88U)
I noticed with the WAN-check I have running every 10 minutes that it happens always at a new hour, because the next WAN-check is not happening.
uiDivStats is generating a new report at a new hour and is taking the same number of hosts and clients as in Diversion in the new version.
The Top x clients and hosts in Diversion are both configured on the maximum of 40 on mine setup.
I think uiDivStats uses too much memory and a lot of processes are killed (Also are the cronjobs maybe) to keep uiDivStats running.
The Swapfile size is 1GB and isn't filled above a couple of MB's.

This is just an assumption and I don't know if this can happen...........
 
I have also the problem of losing my cronjobs. From 21 to 3 sometimes. (RT-AX88U)
I noticed with the WAN-check I have running every 10 minutes that it happens always at a new hour, because the next WAN-check is not happening.
uiDivStats is generating a new report at a new hour and is taking the same number of hosts and clients as in Diversion in the new version.
The Top x clients and hosts in Diversion are both configured on the maximum of 40 on mine setup.
I think uiDivStats uses too much memory and a lot of processes are killed (Also are the cronjobs maybe) to keep uiDivStats running.
The Swapfile size is 1GB and isn't filled above a couple of MB's.

This is just an assumption and I don't know if this can happen...........
Make sure you have the latest versions, I tweaked some of the cron logic as I had noticed something similar start happening
 
Make sure you have the latest versions, I tweaked some of the cron logic as I had noticed something similar start happening
Thanks for your reply.
I uninstalled uiDivStats for the moment to see if the cronjobs stay active.........
 
My crontab was damaged as well sometime between 6/28 and 7/5. It is now 10 lines, the first eight are blank and the last two are for uiDivStats and ntpMerlin.

I have added a backup of cron to my backup scripts.

It would appear that I need to uninstall and reinstall everything in my signature.
 
My crontab was damaged as well sometime between 6/28 and 7/5. It is now 10 lines, the first eight are blank and the last two are for uiDivStats and ntpMerlin.

I have added a backup of cron to my backup scripts.

It would appear that I need to uninstall and reinstall everything in my signature.
After reinstalling, there are now 11 full lines:
Code:
00 2 * * Sun sh /opt/share/diversion/file/update-bl.div reset #Diversion_UpdateBL#
20 5 * * * sh /opt/share/diversion/file/rotate-logs.div #Diversion_RotateLogs#
20 17 * * * diversion count_ads count #Diversion_CountAds#
30 1 * * Sun sh /opt/share/diversion/file/stats.div #Diversion_WeeklyStats#
30 3 * * * /jffs/scripts/FreshJR_QOS -check #FreshJR_QOS#
25 3 * * * sh /jffs/scripts/firewall banmalware #Skynet_banmalware#
25 1 * * Mon sh /jffs/scripts/firewall update #Skynet_autoupdate#
0 * * * * sh /jffs/scripts/firewall save #Skynet_save#
*/5 * * * * /jffs/scripts/connmon generate #connmon#
*/10 * * * * /jffs/scripts/ntpmerlin generate #ntpMerlin#
0 * * * * /jffs/scripts/uiDivStats generate #uiDivStats#
 
and people said he was crazy. :eek::eek::eek::oops:

Here is what i did to resolv.conf this issue. I backup anything that was relevant to my own personal stuff and diversion an i simply formatted the hard drive i was using with AMTM. This resolved the issue, alot of the problems are not related to cron but were related to entware behavior with certain scripts it seems. I have been running without this issue for several days now.
 
Code:
*/5 * * * * /jffs/scripts/connmon generate #connmon#
*/10 * * * * /jffs/scripts/ntpmerlin generate #ntpMerlin#
0 * * * * /jffs/scripts/uiDivStats generate #uiDivStats#
25 9 * * * sh /jffs/scripts/firewall banmalware #Skynet_banmalware#
25 1 * * Mon sh /jffs/scripts/firewall update #Skynet_autoupdate#
0 * * * * sh /jffs/scripts/firewall save #Skynet_save#
00 2 * * Fri sh /opt/share/diversion/file/update-bl.div reset #Diversion_UpdateBL#
20 5 * * * sh /opt/share/diversion/file/rotate-logs.div #Diversion_RotateLogs#
20 17 * * * diversion count_ads count #Diversion_CountAds#
30 1 * * Fri sh /opt/share/diversion/file/stats.div #Diversion_WeeklyStats#
50 1 * * Fri sh /opt/share/diversion/file/backup.div #Diversion_AutoBackup#
10 1 * * Fri sh /opt/share/diversion/file/update.div #Diversion_UpdateCheck#
5 0 * * * /opt/sbin/logrotate /opt/etc/logrotate.conf >> /opt/tmp/logrotate.daily 2>&1 #logrotate#
30 3 * * * /jffs/scripts/FreshJR_QOS -check #FreshJR_QOS#
 
I have also the problem of losing my cronjobs. From 21 to 3 sometimes. (RT-AX88U)
I noticed with the WAN-check I have running every 10 minutes that it happens always at a new hour, because the next WAN-check is not happening.
uiDivStats is generating a new report at a new hour and is taking the same number of hosts and clients as in Diversion in the new version.
The Top x clients and hosts in Diversion are both configured on the maximum of 40 on mine setup.
I think uiDivStats uses too much memory and a lot of processes are killed (Also are the cronjobs maybe) to keep uiDivStats running.
The Swapfile size is 1GB and isn't filled above a couple of MB's.

This is just an assumption and I don't know if this can happen...........

After uninstalling uiDivStats 2 days ago. I don't have the issue anymore of losing cronjobs..................................
 

Similar threads

Latest threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top