uwcron: Cron for the fun_plug

Since quite a while i was often asked if there is a possibility to store entries into crontab permanently on NAS devices with fun_plug. That is not that easy as the devices reset their crontab to the default one on every reboot. Therefore you need to add the entries every time the device reboots. I have now developed a script which automates that for your convenience.

The package with the name “uwcron” is available via my repository:

slacker -UaA uli:uwcron
[[ -f /ffp/start/uwcron.sh.new ]] && mv /ffp/start/uwcron.sh.new /ffp/start/uwcron.sh

As soon as this is installed, you can start with the configuration. The configuration files should be created in /ffp/etc/cron.d/. These could look like this:

*/5  * * * * /tmp/uwfancontrol.sh

When all configuration files are created, the service can be started. This works as with all other services:

chmod a+x /ffp/start/uwcron.sh
/ffp/start/uwcron.sh start

Now you should see your entries in crontab:

crontab -l

If the device is rebootet, all entries from these files in /ffp/etc/cron.d/ would be copied into crontab. if you made a change to a file, you could also just restart the service instead of the complete NAS:

/ffp/start/uwcron.sh restart

Questions?

About Uli

Uli bought his first CH3SNAS in May 2007. Now he owns several NAS-Devices for the backup and storage of media data.Feel free to visit his Homepage: http://wolf-u.li (German) Did his posts help you? Please consider buying him a coffee (or two)!