11 ms·
OpenRC is a dependency-based init system for Unix-like systems
- wkat4242 3y agoI don't like systemd, but I'm not too convinced by openrc. I know alpine has the inventor of s6 working on a service manager based on that and I have higher hopes for it.
- felixgallo 3y agofinally, a modern alternative to systemd.
- hackcasual 3y agoOpenRC predates systemd I believe
- Arnavion 3y agoIt's also not a complete alternative, because it doesn't have anything for user session services like `systemd --user`. I use postmarketOS which is based on Alpine which uses OpenRC, and desktop session daemons currently have to be started by the compositor via XDG autostart files. So services start fine but they're not restarted if they crash, they have ad-hoc logging, etc. One of the pmOS devs wrote a user session service manager [1] but pmOS doesn't use it (yet?). And Alpine as a whole is planning on moving away from OpenRC anyway. [1]: https://git.sr.ht/~craftyguy/superd https://git.sr.ht/~craftyguy/superd
- jabl 3y agoOh, what is Alpine planning to move to?
- Arnavion 3y agohttps://news.ycombinator.com/item?id=36496431 https://news.ycombinator.com/item?id=36496431
- navi-desu 3y ago> It's also not a complete alternative, because it doesn't have anything for user session services like `systemd --user`. i am working on a implementation of that for openrc for a while now, it's been working nicely so far: https://github.com/OpenRC/openrc/pull/573 https://github.com/OpenRC/openrc/pull/573
- JdeBP 3y agoEnjoy https://jdebp.uk/Softwares/nosh/guide/per-user-dbus-demand-start.html https://jdebp.uk/Softwares/nosh/guide/per-user-dbus-demand-s... and https://jdebp.uk/Softwares/nosh/guide/commands/dbus-daemon-launch-helper.xml https://jdebp.uk/Softwares/nosh/guide/commands/dbus-daemon-l... .
- chlorion 3y agoThere is work being done to add user sessions to openrc by some person. It seems pretty cool so far! I'm not totally sure whether openrc will merge this or not, but I would definitely like to see this be added. edit: They actually seem to have replied to you while I was writing the original comment.
- m4rtink 3y agoIt really seems strange to me that postmarketOS does not use systemd, given how its too main usecases (mobile use as well as server use of repurposed devices) would certainly benefit from a mature service manager. Possibly even if they had to put it on top of Alpine themselves.
- Arnavion 3y agopmOS has no intention of moving off of Alpine base, and systemd is still incompatible with musl (or vice versa, depending on which side you're on in the arguement :) ), and OpenRC works well enough for now.
- hedora 3y agoThat doesn't mean its initial design didn't learn from the mistakes systemd made.
- jmclnx 3y agoAnd it is portable to the BSDs, what a concept, writting portable applications :) To bad that is now out of fashion. If the BSD software was not portable Linux would not have gotten off the ground.
- PlutoIsAPlanet 3y agoIt’s a system service manager, it being portable is not a requirement nor any benefit when BSD has nearly no traction in the desktop or server space other than a few cases.
- yjftsjthsd-h 3y ago> it being portable is not a requirement nor any benefit when BSD has nearly no traction in the desktop or server space other than a few cases. Is your argument that portability is irrelevant because nothing but (systemd/)GNU/Linux matters, or that service manager in particular don't need to be portable?
- jmclnx 3y agoSome complex applications are starting to require systemd components. So yes, portability may become important to the BSDs.
- bitwize 3y agoSystemd is a complete solution to a variety of problems with system services under Linux, including user sessions, non-racy session termination, etc. Other init systems, not so much. There are no alternatives to systemd, kinda like there are no alternatives to Excel. Some packages solve many of the same problems, but none solve all of them as thoroughly.
- blablabla123 3y ago> non-racy session termination I've seen a lot of dangling sessions with systemd actually although I'm not sure what the root cause is.
- bandrami 3y agoI had to get an intern to basically live in the server room and look for screens saying "stop command for user 1001 waiting 30 seconds... 90 seconds..." etc. and power cycle the machine. It's ludicrous.
- tadfisher 3y agoIn other words, tell me you've never adminned systemd without telling me you've never adminned systemd. Hint: man systemd.service, look for TimeoutStopSec.
- anthk 3y ago
- bandrami 3y agoOpenRC was released 3 years before systemd
- srgpqt 3y agoIt’s been the default (only?) init system for Alpine Linux since forever.
- Arnavion 3y agoAlpine is hoping to replace it with s6.
- wener 3y agoNot by s6, but s6 author may introduce a new init for alpine
- generalizations 3y agoEither way, I've been watching that s6 project for a couple years now and am looking forward to when that happens. Is there any progress on that front? I hadn't heard that the replacement might not actually be s6.
- frankjr 3y agoNot really. https://old.reddit.com/r/AlpineLinux/comments/ug3ipr/any_news_about_migration_from_openrc_to_s6/ https://old.reddit.com/r/AlpineLinux/comments/ug3ipr/any_new...
- Pet_Ant 3y agoFor those who haven't heard of s6 before (like myself) here is the homepage: https://www.skarnet.org/software/s6/ https://www.skarnet.org/software/s6/ and the repo: https://github.com/skarnet/s6 https://github.com/skarnet/s6
- nerdponx 3y agoS6 and the Obarun-developed wrapper 66 Suite are really really nice. I hope more distros pick it up.
- 3y ago
- bamfly 3y agoI've used several Linux init systems over the years. OpenRC is the only one I've ever liked using. Not sure why it never seemed to catch on with any of the major distros, even before Systemd made itself nigh-unavoidable.
- taneliv 3y agoI have serious dislike for what I perceive as (unnecessary) complexity of Systemd. I made a quick analysis of different init systems when that nigh-unavoidability had not yet happened. OpenRC seemed then the most reasonable of the ones I read about (for qualities I have since forgotten), and your comment stirred this memory. So, a question: why did/do you like using it?
- bamfly 3y agoFound the ergonomics of rc-update and other commands exceptionally decent, and consistent enough that I could usually guess the correct invocation even if I hadn't used it in a while. Never saw it break or tie itself in knots (which, on Gentoo, at least as I managed my Gentoo systems, was an accomplishment). I find the config syntax non-awful. Every other init system I've tried is worse (IMO, obviously) on one or more of those fronts, and not enough-better on any others to make up for it.
- mid-kid 3y agomy biggest pet peeve is having "rc-update <action> <name>" vs "rc-service <name> <action>". systemctl does this consistently, at least.
- esarbe 3y agoWith Systemd you have a configuration language and a defined surface. With OpenRC you have unconstained init scrips written in a Turing-complete language. How exactly is Systemd more complex?
- taneliv 3y ago
- timw4mail 3y agoLast I checked, OpenRC is still the default init system recommended in Gentoo setup.
- Arnavion 3y agoGentoo setup involves completely different downloads depending on whether you want OpenRC or systemd. It's not like there's a single installer that you run which lets you choose between the two and has OpenRC as the default choice. They're both equivalent and the installation handbook doesn't suggest either one over the other. Of course I have no doubt that there are more Gentoo users that use OpenRC than systemd, and I wouldn't be surprised if outing yourself as a systemd user will get you flamed in tech support channels :)
- timw4mail 3y agoApparently it's been a while since I've had to go through that section of the manual.
- Zambyte 3y agoI don't think there is anything really stopping you from standing up a Gentoo system with OpenRC from the systemd installer or vice versa though. It seems really more like a convenience than a requirement to have both installers.
- Arnavion 3y agoTo be precise, there is a single installer image that you boot and use to create the partition layout. Then you pick a stage 3 tarball and unpack it into the root partition, and this tarball is either OpenRC-specific or systemd-specific. Yes it is possible to change your mind and switch from one to the other after installation, but it's not straightforward.
- djbusby 3y agoIIRC the Kernel needs to know which one you use too.
- nickstinemates 3y agoI really love OpenRC, and Gentoo in general. It's my favorite linux distro by far.
- contingencies 3y agoMe too. It has the best and only package management system with the required configurability for many complex but real situations that make other distros a non-option. The biggest drawback of course is if you don't update a box for awhile you have to redo from stage3 - rolling releases are a double-edged sword. In theory, portage solves this. In practice, it just gets to a certain level of ungrokkable problems and you have to pull the parachute. Currently battling with ZFS root (stage3 and portage snapshots on same filesystem) as a workaround. It's nontrivial getting that up and running again. But once I do it's probably going to be a stable workhorse for 5+ years. I'm done with Apple.
- redog 3y agoZfs root on my daily driver machine is held together by... blood sacrifice .,built it's first kernel in Feb 2014 and have rescued it at least three times from catastrophic update neglect I finally killed a fedora install 2years unupdated...I quit trying to restore it after an hour and just took my data off
- contingencies 3y ago'zfs root on gentoo': The way that can be named is not the way. But it's damn close.
- redog 3y agoA zfs root implementation on a Gentoo system(which builds the zfs system it depends upon)...
- wkat4242 3y agoTry FreeBSD. ZFS on root is like a concrete foundation <3
- pxc 3y agoWhen I was a teenager adventuring through the GNU/Linux userland and all its interchangeable components (including on Gentoo!), OpenRC was awesome compared to what I was used to (SysV). Beautiful colorized output, fast startup with parallel execution of jobs... all before Upstart (RIP, though I don't miss it) and Systemd. I'm pretty happy with Systemd these days, and in some ways I don't mind the way it has 'standardized' (read: dominated) Linux stacks. But I'm glad that people are still doing the work to keep OpenRC viable and integrating it into a full-featured, long-lived, relatively popular distro.
- alerighi 3y agoI also remember it, first time I installed Gentoo for it, it was very nice compared to the alternatives. Also very configurable, easy, and did also have an interactive boot mode to debug a system that didn't start.
- skldjfhskdfgh 3y agoi was fine with systemd for a few years, even truly enjoying getting rid of hacky docker workflows in place of machined. then i start to find out it is full of rando backdoors intended for VMs, which will run just the same on your bare metal. For example, just to list the very last one, you can inject smbios data that will be parsed to create files in your system. very convenient to drop passwords and keyfiles around a vm... unless it is the firmware on your actual bios doing the same. And we know how common persistence via bios is. sigh. but as you mention correctly, it have crushed and dominated linux. so i guess i just waste a week or some working around those things later, as usual.
- dv_dt 3y agoIt may shift to a different community balance seeing how RedHat employs a lot of the main contributors to systemd and more recently are showing signs of acting in a more closed manner.
- gary_0 3y agoThe main systemd guy, Lennart Poettering, recently left Red Hat to go work for Microsoft. Hmm...
- PrimeMcFly 3y agoHow does it compare to Runit[[0] used by Void Linux? [0]http://smarden.org/runit/ http://smarden.org/runit/
- JdeBP 3y agoOne problem is that Gerrit Pape hasn't been seen on the mailing list where xe points people to for runit support, for some years now; much to the chagrin of the people left fielding runit questions on that mailing list.
- euclaise 3y agoRunit is way more minimal, the difference between them is extreme even on that alone
- arp242 3y agoI wouldn't say it's "more minimal", it just operates on an entirely different set of principles and assumptions.
- throw7 3y agoDidn't know there was a standalone logind. Reminded me of how they broke vnc sessions. Still kind of annoyed at that one.
- bandrami 3y agoThe guix people wrote it a few years ago to make Gnome work better. Personally I still think "who is logged in to this TTY?" has been a solved problem for a long time now, but apparently that wheel just had to be reinvented in the 2010s.
- jpgvm 3y agoLoved OpenRC when I was still a Gentoo daily driver. These days on I'm systemd like almost everyone else but I will never forget how advanced it felt for it's time. It predated Upstart and systemd by several years but was already fully event-based with parallel execution etc BUT it didn't sacrifice the best parts of sysv to get there. At the end of the day you still had a bunch of relatively easily to debug shell scripts. Running Gentoo with OpenRC meant booting in a fraction of time of other distros out of the box. I appreciate the format of systemd unit files but they result in much of the complexity, corner cases etc being baked into systemd itself reducing debugability. systemd has it's own killer features ofc like systemd-nspawn and friends.
- messe 3y agoYou should try Gentoo+systemd these days. I'm running KDE Plasma on my gaming PC, and it works pretty smoothly. Wayland still has a few rare hiccups, as I'm on NVIDIA, but for the most part works without issue.
- slicktux 3y agoOh, yes, OpenRC…my choice init when I was using Gentoo! I recall the controversy of OpenRC vs Systemd and the flame wars in IRC…
- redog 3y agoDaemontools for maximum minimumness
- arp242 3y agoI use OpenRC to start runit on my Alpine systems, and use runit to manage everything else. I had some trouble getting the OpenRC script "just right", and figured this was easier. The systemd people really were right about SysV init being not-so-great (which, of course, doesn't automatically mean systemd is the answer). The overall principles and usage of runit (e.g. just keeping stdout/err attached) is significantly simpler than the whole "daemonize" dance.
- throwawaaarrgh 3y agoOpenRC is the init system used for Alpine. It's alright; I prefer SysV. But then again I sharpen my own knives.
- hitori 3y agoI want to know it's there any way to manage logs produced by a OpenRC service like `journalctl` in systemd?