[systemd-devel] question about system reboot and shutdown
Lennart Poettering
lennart at poettering.net
Wed Aug 9 17:15:00 UTC 2017
On Mi, 09.08.17 11:02, Marek FloriaĆczyk (marek.florianczyk at gmail.com) wrote:
> The question is, will my binary be able to open RS232 port eg. /dev/ttyACM0
> when filesystem is Read-Only ?
Yes, /dev is unaffected. It's an API VFS, not a real file system, and
those won't be remounted r/o.
> And if it is binary it will need to load some libs at least libc at
> the start.
As long as you use only libraries and other resources from the root fs
you should be fine. But you shouldn't reference /var, /home, /srv or /usr/local or
such, if you want to remain compatible with generic systems.
> The man page you pointed to says the parameter is: "halt", "poweroff",
> "reboot" or "kexec", so the first two should work for me.
"halt" just halts the system. It shouldn't result in power being
turned off. It will just make the system freeze eventually, that's all.
Lennart
--
Lennart Poettering, Red Hat
More information about the systemd-devel
mailing list