cron simply not working...

Post new topic   Reply to topic    DD-WRT Forum Index -> Marvell MVEBU based Hardware (WRT1900AC etc.)
Author Message
lakester
DD-WRT Novice


Joined: 25 May 2014
Posts: 13

PostPosted: Wed Aug 12, 2020 2:00    Post subject: cron simply not working... Reply with quote
Subject line says it all.

Running on build 41586 (11/21/19) on a wrt1900acsv2

Got onto this track while trying to install YaMon v4.

Have added a simple test to the crontab.

Have verified that the script works, and that permissions are set as permissively as possible.

The cron entry is:

/1 * * * * root /tmp/mnt/sda1/test

have also tried:

1-59/1 * * * * root /tmp/mnt/sda1/test

Have tried running the script from both /tmp/mnt/sda1 (a thumb drive) and /tmp.

The script is never invoked. Have done stopservice and startservice many many times. Have manually invoked /usr/sbin/cron. Nada.

I've read several old threads on the subject, but they appear to be out of date.

I would really rather not upgrade to another version, simply because it was a long game of wack-a-mole to get to a tolerable set of bugs with this version.

Any thoughts?

Thx!!!
Sponsor
eibgrad
DD-WRT Guru


Joined: 18 Sep 2010
Posts: 9157

PostPosted: Thu Aug 13, 2020 2:07    Post subject: Reply with quote
If you're trying to run something every minute, the following is NOT the right syntax.

Code:
/1 * * * * root /tmp/mnt/sda1/test


This is.

Code:
*/1 * * * * root /tmp/mnt/sda1/test


Also, make sure you have marked the test script as executable.

Code:
chmod +x /tmp/mnt/sda1/test


Also, when dealing w/ jobs that run every 5 mins or less (esp. every minute), it's usually more efficient to put the script into a loop, sleeping between each pass. Esp. if your script needs persistence. There are also startup costs associated w/ initiating a new process each time the cronjob is triggered.

_________________
ddwrt-ovpn-split-basic.sh (UPDATED!) * ddwrt-ovpn-split-advanced.sh (UPDATED!) * ddwrt-ovpn-client-killswitch.sh * ddwrt-ovpn-client-watchdog.sh * ddwrt-ovpn-remote-access.sh * ddwrt-ovpn-client-backup.sh * ddwrt-mount-usb-drives.sh * ddwrt-blacklist-domains.sh * ddwrt-wol-port-forward.sh * ddwrt-dns-monitor.sh (NEW!)
egc
DD-WRT Guru


Joined: 18 Mar 2014
Posts: 12814
Location: Netherlands

PostPosted: Thu Aug 13, 2020 6:21    Post subject: Reply with quote
There were also some builds with broken cron.

If the right syntax, @eibgrad pointed out, is not working step up to a recent build

_________________
Routers:Netgear R7000, R6400v1, R6400v2, EA6900 (XvortexCFE), E2000, E1200v1, WRT54GS v1.
Install guide R6400v2, R6700v3,XR300:https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=316399
Install guide R7800/XR500: https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=320614
Forum Guide Lines (important read):https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=324087
lakester
DD-WRT Novice


Joined: 25 May 2014
Posts: 13

PostPosted: Thu Aug 13, 2020 18:01    Post subject: Reply with quote
Thx guys. Yah..., simply isn't working.

I realize this is changing the topic a bit:

I noticed in another thread some mention regarding problems relating to the way DHCP was initializing some table..., some sort of race condition involved maybe..., that caused leases to expire in an unexpected way that resulted in 2.4Ghz connection problems for Android devices.

Apologies if I misconstrued what was being talked about..., but one of the issues I've had with recent versions of dd-wrt relates to problems connecting at 2.4Ghz with Pixel phones (perhaps others).

Do you know if this was broadly impacting recent Android devices at 2.4Ghz?

I'm just trying to judge the likelihood of getting both cron AND wi-fi completely working at the same time.

The range of 2.4Ghz is important for me since I live on a farm with lousy mobile service..., so wi-fi is generally my best option when working within reasonable distance of the house.
egc
DD-WRT Guru


Joined: 18 Mar 2014
Posts: 12814
Location: Netherlands

PostPosted: Thu Aug 13, 2020 18:22    Post subject: Reply with quote
Wifi and Marvell is problematic combination, the wireless drivers are not well supported i.e abandoned by the manufacturer.

Try the latest build read the build threads

_________________
Routers:Netgear R7000, R6400v1, R6400v2, EA6900 (XvortexCFE), E2000, E1200v1, WRT54GS v1.
Install guide R6400v2, R6700v3,XR300:https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=316399
Install guide R7800/XR500: https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=320614
Forum Guide Lines (important read):https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=324087
Display posts from previous:    Page 1 of 1
Post new topic   Reply to topic    DD-WRT Forum Index -> Marvell MVEBU based Hardware (WRT1900AC etc.) All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum