[Ubuntu Touch] rc.local should be in /etc/writable
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
lxc-android-config (Ubuntu) |
Won't Fix
|
Undecided
|
Unassigned |
Bug Description
In Ubuntu Touch, /etc/rc.local is on a read-only filesystem. This prevents inserting commands to be executed at boot time. Here is the output of ls -l /etc/rc.local on Ubuntu Touch 13.10.
-rwxr-xr-x 1 root root 306 Oct 18 11:45 /etc/rc.local
Instead, rc.local needs to be a symbolic link into /etc/writable . Here is an example of a file in /etc that has been made writable.
lrwxrwxrwx 1 root root 17 Nov 14 17:45 /etc/timezone -> writable/timezone
One consequence of this (not the only one, just an example) is that a startup command cannot be added to turn off Bluetooth permanently. The usual instructions for this are to put "rfkill block bluetooth" or "service bluetooth stop" in /etc/rc.local .
This is unrelated to the sysvinit package. Migration of config files into /etc/writable is handled by a touch-specific overlay component.
However, I see no reason that we want to support making /etc/rc.local writable on a read-only touch image. This is a last-resort mechanism for modifying the system startup, not one that we want to endorse in the phone images; and the specific example you give, of disabling bluetooth, is one that will be handled by different means.
And any "usual instructions" that tell users to run 'service bluetooth stop' in /etc/rc.local are absolutely wrong.