/etc/rc.local doesn't run on startup

Seems that /etc/rc.local doesn’t run on startup like it’s supposed to. For testing purposes, my /etc/rc.local currently contains:

#!/bin/sh -e
# rc.local
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
# In order to enable or disable this script just change the execution
# bits.
# By default this script does nothing.
/usr/bin/touch /home/osmc/testfile
exit 0

Obviously I’d expect to see a file called ‘testfile’ in my home directory after a restart, but it’s not happening.

Any ideas? I’m using a Vero 4K with the latest stable build.

Check if the file is executable.

Well that’s embarrassing. I’m an idiot.

Thanks, it’s working now.

It’s frequent oversight :wink: