News for hackers. Stuff that matters.
Re:Porting systemd to musl Libc-powered Linux by rkangel on Thursday September 05, 2024 @10:24AM (#41456938)
> it's funny that many people mention boot time as a metric

For the majority of deployments of systemd, that's probably true. Note that this is a musl port, and that the existing musl port is from OpenEmbedded. It's embedded devices that are often using cut-down userspaces (e.g. using MUSL), and embedded devices often do care about startup time because they're not Always-On.

E.g. the VTech baby monitor I've just bought is generally pretty good, but spends >10 seconds at a splash screen when you turn it on. No idea if it's Linux under the hood, but an optimised boot time would be great.

In a previous work project, we need the Linux based software to be ready from low power state quickly (battery powered, only doing work occasionally). By getting the boot time down <1s, I could also avoid a load of sleep-state shenanigans - when we wanted to power save, we just turned off completely (there was already a supervisory micro to decide when to turn back on).

Re:Porting systemd to musl Libc-powered Linux by throwaway984393 on Thursday September 05, 2024 @10:33AM (#41457022)
It's pretty trivial for an embedded device to trim down the series of startup tasks to only what's required, and then just write a C program that does those steps. I certainly wouldn't pick up such a gigantic, complex and potentially insecure package as systemd for an embedded project. I want less moving parts, not more
Re:Porting systemd to musl Libc-powered Linux by telotortium on Thursday September 05, 2024 @12:23PM (#41458101)
It depends on what you mean by embedded, I suppose. Having a service monitor to restart your jobs is pretty useful too, and it can be tricky enough to write a good one. Something like a baby monitor (to use an example mentioned elsewhere) might run almost as many services as a desktop Linux installation.
Re:Porting systemd to musl Libc-powered Linux by 6SixTy on Thursday September 05, 2024 @01:23PM (#41458684)
Good chance that baby monitor uses something like FreeRTOS, not Linux for doing it's stuff. If you are unlucky, it's Android and they did the bare minimum to have a functional product.

E: Also, Android uses the Linux kernel, but similarities with Linux based operating systems pretty much stop there.

Re:Porting systemd to musl Libc-powered Linux by RandomThoughts3 on Thursday September 05, 2024 @04:26PM (#41460131)
Android is a Linux based operating system so saying it stops there doesn’t make any sense. There is a wild variety of Linux OS out there in embedded encompassing a lot of various patchsets, libc and userland. You just have a bad understanding of what are Linux OS if all you think about is the usual distros.
Re:Porting systemd to musl Libc-powered Linux by hulitu on Friday September 06, 2024 @02:47AM (#41463549)
> Android is a Linux based operating system

Where are the posix utilities ? /s Where is man ? /s

Re:Porting systemd to musl Libc-powered Linux by Lockal on Friday September 06, 2024 @05:05AM (#41464343)
No sarcasm, Bionic libc is a subset of POSIX, Musl strictly follows POSIX 2008 and Glibc is superset of POSIX. 99% of Glibc->Musl porting is dealing with non-POSIX features (a.k.a. GNU extensions)[1]. So in the end we could find that Android apps are more POSIX compliant than software from generic glibc-based distros.

[1] https://wiki.gentoo.org/wiki/Musl_porting_notes