News for hackers. Stuff that matters.
Re:OpenRC is a dependency-based init system for Unix-like sy... by pxc on Tuesday June 27, 2023 @02:42PM (#36497001)
When 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 as '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.

Re:OpenRC is a dependency-based init system for Unix-like sy... by alerighi on Tuesday June 27, 2023 @03:58PM (#36497881)
I 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.
Re:OpenRC is a dependency-based init system for Unix-like sy... by skldjfhskdfgh on Tuesday June 27, 2023 @04:05PM (#36497963)
i 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.

Re:OpenRC is a dependency-based init system for Unix-like sy... by dv_dt on Tuesday June 27, 2023 @04:10PM (#36498029)
It 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.
Re:OpenRC is a dependency-based init system for Unix-like sy... by gary_0 on Tuesday June 27, 2023 @04:19PM (#36498117)
The main systemd guy, Lennart Poettering, recently left Red Hat to go work for Microsoft. Hmm...
Re:OpenRC is a dependency-based init system for Unix-like sy... by dv_dt on Tuesday June 27, 2023 @04:20PM (#36498124)
Oh I didn't realize that. Maybe similar teeth, different dragon. I'm cautious about Microsoft, but recently I'd have to say they've been a more reasonable Linux community member - though if there are fewer larger balancing orgs - who knows.
Re:OpenRC is a dependency-based init system for Unix-like sy... by inetknght on Tuesday June 27, 2023 @05:54PM (#36499192)
> about Microsoft, but recently I'd have to say they've been a reasonable Linux community member

All it takes is to look around at what Microsoft is doing to gestures vaguely to see the writing on the wall for how Microsoft sees Linux.

Advertisements on the home screen? Advertisements on the every screen? Login darkpatterns? Configuration resets on updates? Forceful browser choices? Forced updates? UEFI shenanigans? Boot manager shenanigans?

Re:OpenRC is a dependency-based init system for Unix-like sy... by dv_dt on Tuesday June 27, 2023 @07:59PM (#36500436)
Yup, the windows OS (as opposed to Linux) is where they have no counterbalancing reason to not pursue darker patterns. So it's a window into unchecked tendencies.
Re:OpenRC is a dependency-based init system for Unix-like sy... by pjmlp on Wednesday June 28, 2023 @01:24AM (#36502622)
It looks like....Android.

As proven by OEM distributions on by gone netbooks, and Android flavours, OEMs will always do what they do best.

In what concerns Windows, unfortunately it appears only Azure, Office and XBox matter now.

Re:OpenRC is a dependency-based init system for Unix-like sy... by kaba0 on Wednesday June 28, 2023 @04:38AM (#36503883)
Or you know, Microsoft is a giga-company with no singular goal (besides increasing revenue). Improving and “destroying” linux may be simultaneously goals to separate areas of the same company, and due to bureaucracy I really can’t take this conteos seriously.
Re:OpenRC is a dependency-based init system for Unix-like sy... by Arch-TK on Wednesday June 28, 2023 @02:01PM (#36510196)
>but recently I'd have to say they've been a reasonable Linux community member

LOL

Its amazing how easy it is. I guess if you spend your entire history being a shitty company and then spend a couple of years pretending to be marginally less shitty then you can dupe a bunch of people.

Re:OpenRC is a dependency-based init system for Unix-like sy... by hawski on Tuesday June 27, 2023 @04:23PM (#36498156)
Being now run increasingly more and more by IBM mothership I guess systemd may become a very profitable cow to fatten for them.
Re:OpenRC is a dependency-based init system for Unix-like sy... by wkat4242 on Tuesday June 27, 2023 @06:15PM (#36499422)
How though? How will they make money off it?

I do think they had commercial aspirations work systemd, but more about "being the company that invented..." Than a direct cash cow.

This is in contrast to the play canonical makes with snaps that has 30% app store tax written all over it.

Re:OpenRC is a dependency-based init system for Unix-like sy... by sliken on Tuesday June 27, 2023 @11:36PM (#36501953)
The oracle pattern of making it more complicated = more support costs/more consulting/more profit
Re:OpenRC is a dependency-based init system for Unix-like sy... by kaba0 on Wednesday June 28, 2023 @04:42AM (#36503913)
That’s just baseless fearmongering conteo. Like, I honestly you think that is a feasible financial strategy?!
Re:OpenRC is a dependency-based init system for Unix-like sy... by wkat4242 on Wednesday June 28, 2023 @05:12AM (#36504111)
Oracle lives very well with basically extorting their customers...
Re:OpenRC is a dependency-based init system for Unix-like sy... by Eduard on Tuesday June 27, 2023 @05:21PM (#36498839)
> then i start to find out it is full of rando backdoors intended for VMs,

Do you have some links to share?

Re:OpenRC is a dependency-based init system for Unix-like sy... by egberts1 on Wednesday June 28, 2023 @10:00AM (#36506599)
Got hit by a Bitcoin hacker via a seldomly-used systemd unit file.

Now working on a replacement to systemd-tmpfiled for OpenRC.

Run these sysvinit, OpenRC and maintain systemd as well at this shop.

Re:OpenRC is a dependency-based init system for Unix-like sy... by Asooka on Tuesday June 27, 2023 @05:37PM (#36499008)
The unit and service file formats are honestly fine, it should be possible to have a second implementation. We have several varieties of SysV init already.
Re:OpenRC is a dependency-based init system for Unix-like sy... by bandrami on Tuesday June 27, 2023 @08:35PM (#36500723)
The unit file format is what I don't like about it. A giant spaghetti code mess where dependencies can be literally anywhere and the final imperative result is completely opaque. An init system, ultimately, does a bunch of one time actions to bring the system up; it really does just work better as an imperative script.
Re:OpenRC is a dependency-based init system for Unix-like sy... by esarbe on Wednesday June 28, 2023 @02:12AM (#36502927)
How are Systemd's unit files any worse than unconstrained init scripts written in a Turing complete language with even basic stuff - like PID files - managed manually?
Re:OpenRC is a dependency-based init system for Unix-like sy... by bandrami on Wednesday June 28, 2023 @03:38AM (#36503525)
Because they are opaquely translated into an imperative sequence but you never get to see it.

Also who are these people who have complicated sysv scripts? I've heard this for years and never really understood it. One script per service with a stop and start command (and maybe a status if you want to get fancy) and runlevel definitions that start and stop them. It's not rocket surgery, and it's a hell or a lot easier to debug than a declarative system definition.

Re:OpenRC is a dependency-based init system for Unix-like sy... by kaba0 on Wednesday June 28, 2023 @04:36AM (#36503870)
> Because they are opaquely translated into an imperative sequence but you never get to see it

Into correct imperative sequence. That’s the whole point of declarative things.

You can’t feasibly write it correctly otherwise. You are writing programming languages over assembly for largely this same reason.

Re:OpenRC is a dependency-based init system for Unix-like sy... by pjmlp on Wednesday June 28, 2023 @05:41AM (#36504287)
Ah, the wonders of sysv scripts in commercial UNIX systems doing all kinds of interesting stuff from corporate IT.
Re:OpenRC is a dependency-based init system for Unix-like sy... by JdeBP on Thursday June 29, 2023 @03:25AM (#36517459)
The reality is that it wasn't corporate scripts hidden away from the public eye. There were some nightmare van Smoorenberg rc scripts in the likes of Debian.

FreeBSD has Mewburn rc not van Smoorenberg rc and was thus inherently better in this regard until the middle of 2014 (https://unix.stackexchange.com/a/480897/5132). But even FreeBSD has some large rc scripts, particularly in the networking and the HID parts such as Bluetooth and configuring all attached keyboards; albeit that the FreeBSD style guidelines mean that they are more legible than the nightmare Debian (et al.) ones.

Re:OpenRC is a dependency-based init system for Unix-like sy... by kaba0 on Wednesday June 28, 2023 @04:34AM (#36503864)
An init system is for all practical purposes a build system - a very complex problem where literally every sane solution is declarative. Especially when you take into account error handling (that HDD is not yet available, will you imperatively wait for it to come up and pause everything else? Do parallel work in the meantime in fking bash? Or what exactly?)
Re:OpenRC is a dependency-based init system for Unix-like sy... by bandrami on Wednesday June 28, 2023 @04:44AM (#36503926)
I mean, yes? Start one service at a time, in the order specified? There's not some reason that magically stopped working in 2010.
Re:OpenRC is a dependency-based init system for Unix-like sy... by orra on Wednesday June 28, 2023 @05:17AM (#36504139)
Sequential start-up is unnecessarily slow.

Startup is ultimately a complex problem. There is no magic, just race conditions which maybe became more apparent. LVM may or may not be used, and takes time to start up. Do you wait for it? Ditto wireless networks. And how do you handle devices being hotplugged? Setups vary widely, and can be dynamic.

Re:OpenRC is a dependency-based init system for Unix-like sy... by hulitu on Wednesday June 28, 2023 @04:45PM (#36512339)
> Startup is ultimately a complex problem

??

Mount filesystem, start networking, start networking daemons, update crappy gtk stuff, run rc.local.

What is so complex ?

Re:OpenRC is a dependency-based init system for Unix-like sy... by JdeBP on Thursday June 29, 2023 @03:07AM (#36517334)
Apparently, for starters, knowing when rc.local is to be run.

It was run in the middle of rc, not at the end; as pointed out in the OpenBSD manual.

Re:OpenRC is a dependency-based init system for Unix-like sy... by orra on Wednesday June 28, 2023 @05:09AM (#36504090)
This is a very interesting analogy, which I haven't seen before. Thanks.
Re:OpenRC is a dependency-based init system for Unix-like sy... by avhception on Tuesday June 27, 2023 @04:10PM (#36498035)
Gentoo was the first distro that lead to me really understanding what was going on.

So OpenRC was "normal" for me, and when the systemd debate came around I didn't think about the fact that OpenRC wasn't the norm and folks hat been using SysV init all that time.

I'm still a Gentoo user these days (although not as heavily, the laptops are running Fedora nowadays), but running systemd. The unitfile format is really great.

Re:OpenRC is a dependency-based init system for Unix-like sy... by gerdesj on Tuesday June 27, 2023 @07:48PM (#36500338)
I ran Gentoo on a fair few systems from around 2002 to 2016ish. For me the killer part of OpenRC was "net" - https://wiki.gentoo.org/wiki/Handbook:X86/Full/Networking

I remember being stuck in a holiday let in the arse end of Somerset, whilst waiting for a house purchase to grind through to a conclusion. Around 2009. I got pppd to use both of our mobiles via bluetooth to get some sort of rather sad internet connection together so we could browse rather slowly and email etc.

All of that was done in /etc/conf.d/net - one file! You can also put a firewall together with it and generate routing tables and all sorts of things. I have no idea why netplan needed inventing, when net already did it all without the bloody YAML! OK - slap YAML on net. Job done.

I don't miss Miguel van S's sysvinit scripts and all the peculiarities in the various ways of doing them by distro.

I did try to write OpenRC initscripts but they are still too complicated for a simple sysadmin like me. I have used git to get an elderly Gentoo box from 2007 to 2022 - so can attest to the sheer robustness of the distro. It did take some doing.

I think that the greatest gift that Gentoo gives to its adherents is this: No matter how broken a Linux box is, provided the storage is operational, the CPU can crunch stuff and RAM is mostly functional and there are not too many holes in your files, you will repair it.

Oh and it has always had the best looking terminal in all modes, bar none, for decades.

Cheers: Uberlord.

[EDIT] Took me a while: https://web.archive.org/web/20211120235128/https://roy.marpl...

also: https://news.ycombinator.com/item?id=26449179

Re:OpenRC is a dependency-based init system for Unix-like sy... by earth2jason on Wednesday June 28, 2023 @06:36AM (#36504629)
In breaking init news, I was sitting at the bar inside Guthrie's of Somerset (wet county now) the exact moment I read this comment. Tried to login for the first time in a decade to reply at the time but the mobile app doesn't have the account recovery that I could find.

Thought that was petty exciting. On this note, I think I will finally overcome my anxieties and make July the month I finally install Gentoo!

Re:OpenRC is a dependency-based init system for Unix-like sy... by gerdesj on Wednesday June 28, 2023 @05:35PM (#36512930)
"July the month I finally install Gentoo!"

Go for it - it really is rather satisfying. Your lap will get rather warm if its a laptop! Stick to the manual and don't get too hung up on minutiae until you have to. I do recommend ~amd64 (the ~ is very significant). Although ~ means something like "beta" you tend to get much more modern software. Make sure you have another route to the internet to find out how to fix breakage because it is inevitable with Gentoo.

I leave the compiler output to fairly verbose and found it hypnotic and very satisfying to watch. I could tell what was being compiled just by the shape of the output.

The wiki and forums are superb.

You might consider running it in a VM at first to get the hang of it and make use of snapshots/checkpoints to back out failed experiments. You could turn that into a stage 4 and recover to bare metal (if you dare!)

Cheers from Yeovil.

Re:OpenRC is a dependency-based init system for Unix-like sy... by mid-kid on Wednesday June 28, 2023 @08:44AM (#36505585)
It's probably been a while since you've last used OpenRC, and I don't know how it was back then, but these days, service scripts are really trivial to write[1]. You just need to provide the command= and command_arguments= to use, and depending on whether the daemon backgrounds itself or not, configure the pidfile location or set command_background=true. It really couldn't be easier.

Personally I just wish it had any notion of logging stdout/stderr, or a way to manage daemons as a user.

[1]: https://github.com/OpenRC/openrc/blob/master/service-script-...

Re:OpenRC is a dependency-based init system for Unix-like sy... by gerdesj on Wednesday June 28, 2023 @05:46PM (#36513077)
I migrated to systemd, wholesale.

You have piqued my interest and I will spin up a VM at work and have another look at the state of the art on Gentoo.

I absolutely loved it back in the day. Every few months or so a major change would arrive and make life better. Sets - @world etc - smashing. User patching - drop a patch in a suitable directory and effectively you could fix snags yourself without having to write your own ebuild. Do your own ebuilds - again drop your override into the right directory and your personal ebuild is seamlessly part of the distro.

No doubt much more has happened in the roughly five years when I have used it in anger. Ironically enough I have two systems at work that do run Gentoo but are woefully "legacy". Today I emerged a couple of packages to fix something on one of them and it is still hanging on in there. It is quite a delicate dance on a rather crucial system. I will get rid of it eventually but one step at a time 8)

Re:OpenRC is a dependency-based init system for Unix-like sy... by kaba0 on Wednesday June 28, 2023 @04:31AM (#36503835)
> read: dominated

Through being voted on/carefully chosen based on merit.

Re:OpenRC is a dependency-based init system for Unix-like sy... by pxc on Wednesday June 28, 2023 @01:35PM (#36509801)
* * *
Re:OpenRC is a dependency-based init system for Unix-like sy... by cykros on Thursday June 29, 2023 @07:52AM (#36519214)
SysV isn't so much the problem; the old Debian/Redhat standard init scripts for it were the absolute mess. Slackware's implementation of SysV is something I've never had a complaint about.

That said, OpenRC also looks to be a nice system that does its job well without function creep, which is more than I can say for systemd.