If your system is using systemd, don't use rc.local. rc.local is not
deterministic in systemd. I've had to move everything out of rc.local and
learn systemd to get reliable starting.
I created something like this (run_on_boot.service)
Description=Run at startup
After=network.target network-online.target sshd.service
Copy run_on_boot.service to /etc/systemd/system
systemctl enable run_on_boot
The above will run the file in ExecStart after the targets, etc on next
boot. Systemd will do a topological sort on the dependencies to start
things in the right order and run in parallel if it can.
We used to throw things into rc.local or create a script, tack S99 on the
name and put it in /etc/rc3.d. The systemd group would eliminate rc.local
if they could, so it's barely supported. It gets started at some random
time, not after everything else.
On Tue, Aug 8, 2017 at 10:28 AM, Ken D'Ambrosio <k...@jots.org> wrote:
> Hey, all. I've got some stuff in my rc.local, and it takes *forever* to
> execute -- three+ minutes. (Note that the machine -- a virtual one --
> is up in something like 20 seconds.) I *need* this stuff, which is
> lightweight in the extreme, to execute much more quickly than that.
> Anyone have any ideas on how to make that happen?
> gnhlug-discuss mailing list
gnhlug-discuss mailing list