Run command on boot

I should be able to accomplish this via cron job, but cron jobs are not saved across reboots. Is there a way aroudn this? I’ve found multiple entries suggesting that is possible, and others that is not. So far, just running a cron job (either crontab -e as root, or inserting file in /etc/crond.d/) does not work, as it is over-written upon reboot.

FYI - I’m on fw version 2.11.142

If cron is no longer an option, what option(s) are available for running a command @ boot?

Hopefully an experienced SSH user will be able to assist as such proceedings are not warranted or supported by Western Digital.

If WD doesn’t want to support it, why provide ssh access at all, then?

Further, it is my understanding that prior to recent F/W updates the “/” directory was not over-written on boot and cron-jobs would persist across reboots.

The icing on the cake is that there is obviously some sort of ability to run commands on boot, otherwise the “apps” that are available would fail as well.

I didn’t intend to go off on a rant - but the lack of documentation on how to accomplish this (now that cron-jobs are no longer sufficient thanks to new f/w) is rather frustrating.

Did you ever find any way to do this? I need to do the same.

Looking for the same answer, I currently found 3 ways of doing it (but only one of them works for me). First and second include making and installing an “App”. Second and third include making a docker container. Sorry I’m allowed to post only two links, so for others I’ll give search suggestions.

  • First option: making an “app” which you can install via UI. HERE you can find SDK Instructions (link), and to get a forum thread with some apps packaged this way, google for “community wd com 177885”. I assume that the app runs “” script every time you switch it on via UI, or after every reboot (but I didn’t try this).
  • Second option: making a docker app. HERE you can find official SDK Instructions (link), and to get a forum post with a shorter step-by-step version, which starts rsync from crontab, google for “community wd com 199241”.
  • Third option is for those like me who has Docker but can’t install apps - to stop half-way the second option: get a running docker container and set it to be started automatically. To get official documentation, google for “docker start containers automatically”. If you want (if you still need this and two above options don’t work for you) - I can try to make a step-by-step version and publish it here.