On Sat, Aug 12, 2017 at 3:35 AM, Matthias Hanft <m...@hanft.de> wrote: > > But now, there's agetty left, and I don't know how to restart this > service (without reboot): >
This is because these are run directly by init and not by openrc, unlike all the other daemons on the system. As others pointed out you can just kill these directly. Under systemd agetty is run as a service just like everything else and you can restart it the same way that you'd restart apache. There isn't really any equivalent to inittab in systemd other than one or two similar global settings. Arguably it might be nicer to treat them more like a normal service under openrc, now that it can restart crashed services. I'm not sure how reliable this feature is (I haven't run openrc in a while now), and you would need it to be reliable for agetty since most people like having a console. Traditionally agetty has been run by init for a long time though, so there might be some reluctance to make this change. Offhand I'm not sure if there are any other issues with making it a service in openrc. Fun fact: sysvinit is essentially a poor man's service manager. You could stick anything in inittab and init will start it, and restart it if it dies. There is just no control over things like dependencies and sequencing, and you have to watch out because if you have init run some bash script, which launches a process that forks, and your script terminates, then init will re-launch it possibly giving you a fork bomb at boot. Things like this are why more full-featured service managers were created. Even these tend to fall in generations, with openrc being a lot more modern than what most distros were using before upstart/runit/systemd came along. -- Rich