Debian Bullseye Guide: Install Sysvinit, but Keep Systemd

If it doesn't relate to Debian, but you still want to share it, please do it here

Debian Bullseye Guide: Install Sysvinit, but Keep Systemd

Postby thmtrxhsu » 2020-04-25 14:24

First you need to add two repos the your sources.list

deb http://mxrepo.com/mx/repo/ buster main non-free. (provides maintained systemd-shim)
deb http://deb.debian.org/debian/ buster main contrib non-free (provides other systemd dependencies, not in bullseye repo)

Then: sudo apt update.
Then: sudo apt install sysvinit-core sysv-rc sysvinit-utils sysv-rc-conf systemd-shim systemd

N.B. You'll have to add the key for the MX repo, just use the keyserver.ubuntu.com

Done; and you should not see your gnome packages disappear upon install sysvinit-core.

Important: In keeping with Debian philosophy and principles, those repos should be removed thereafter.

Now if you go to install a package such as flatpak it will destroy your config if you are not careful.
You want to look for what it is going to remove and what it is going to auto remove when you issue the the command sudo apt autoremove.
Then you want to install these so that your configuration is unaffected.

So for flatpak:

sudo apt install flatpak systemd-shim sysvinit-core libpython3.7-minimal libpython3.7-stdlib python3.7 python3.7-minimal

systemd-shim and sysvinit-core were going to removed, and
the python stuff was going to be autoremoved, but not with the above command.
Last edited by thmtrxhsu on 2020-04-25 16:39, edited 4 times in total.
thmtrxhsu
 
Posts: 18
Joined: 2020-04-09 13:46


Re: Debian Bullseye Guide: Install Sysvinit, but Keep System

Postby thmtrxhsu » 2020-04-25 15:25

Pursuant and to appease my colleague, you should remove those repositories thereafter. However Debian must be Free and thus pursuant to installing sysvinit whilest keeping systemd, this work around is necessary and within the meaning of Free without going against the stable Debian philosophy.
thmtrxhsu
 
Posts: 18
Joined: 2020-04-09 13:46

Re: Debian Bullseye Guide: Install Sysvinit, but Keep System

Postby Head_on_a_Stick » 2020-04-25 16:00

So what happens when the next serious vulnerability in systemd is announced?

How do the people who have followed the steps in this thread keep their system secure?
User avatar
Head_on_a_Stick
 
Posts: 12132
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: Debian Bullseye Guide: Install Sysvinit, but Keep System

Postby Bulkley » 2020-04-25 16:20

I tried this a couple of weeks ago in a virtual machine. It worked, sort of. It really did not have the snap that one finds in unadulterated Debian Buster.

I'm typing this in Debian Stretch (old Stable) which uses systemd-shim, sysvinit-core and openrc. It works very well. A similar setup in Buster is not as successful. With Buster, Debian moved further into the systemd arena. MX does more than simply use a new version of systemd-shim to get around it.

I applaud any and all attempts to get around systemd's total control however I am forced to admit that it is not as easy as in the opening post.
Bulkley
 
Posts: 5942
Joined: 2006-02-11 18:35

Re: Debian Bullseye Guide: Install Sysvinit, but Keep System

Postby thmtrxhsu » 2020-04-25 19:40

To answer both of your enquiries. To the first the point is not to mix the packages from different base versions of Debian i.e., buster with bullseye.
Thus as a matter of principle if you install a bullseye Debian then you use the bullseye repo.
Now I'm not sure if you are referring to systemd or systemd-shim.
The first is covered by the bullseye repo which is enabled at all times.
However, it is perfectly safe to temporarily re-enable the mx repo to check for an updated systemd-shim and then make a judgement call or not bother at all.
Then you disable that source and sudo apt update to return to "safety".

"I tried this a couple of weeks ago in a virtual machine. It worked, sort of. It really did not have the snap that one finds in unadulterated Debian Buster.

I'm typing this in Debian Stretch (old Stable) which uses systemd-shim, sysvinit-core and openrc. It works very well. A similar setup in Buster is not as successful. With Buster, Debian moved further into the systemd arena. MX does more than simply use a new version of systemd-shim to get around it.

I applaud any and all attempts to get around systemd's total control however I am forced to admit that it is not as easy as in the opening post."

Your experiment is flawed. The only thing that CAN be slower between systemd only and sysvinit-core is the startup. Systemd is notoriously fast regardless of what you install. Sysvinit on the other hand is quite finicky. Never install ifupdown on a sysvinit system, the boot hangs by 30 seconds, but this type of scenerio is less common on systemd. The speed of the system is strictly determined by the kernel which you are technically free to choose. The fastest kernel in existence as of this moment is xanmod's kernel; it is stupid fast especially 5.4.32 with sysvinit. You don't seem to understand the purpose of systemd-shim; think of it as a gnome compatibility layer. There is no need to include a gnome compatibility layer technically no need, but given that much software has its origin in gnome time that is why you would include it in a distro. It is not to get away from systemd. Basically, init aside you have to choose between do I want high compatibility, or do I want absolute freedom with either significantly less packages or dependency hell. For sure, MX has probably added restrictions to systemd probably along the lines of what head on a stick described in another post. So systemd-shim has nothing to do with not using systemd, because it requires systemd; it is merely a compatibility layer for gnome. To get around systemd's total control you have to fully exclude it or live with mitigations which I wont describe here.
thmtrxhsu
 
Posts: 18
Joined: 2020-04-09 13:46

Re: Debian Bullseye Guide: Install Sysvinit, but Keep System

Postby anticapitalista » 2020-04-25 21:21

To O/P - Can you name a 100% Debian-based (buster since it is the latest) distro that does not include systemd at all?
antiX with runit - lean and mean.
https://antixlinux.com
anticapitalista
 
Posts: 381
Joined: 2007-12-14 23:16

Re: Debian Bullseye Guide: Install Sysvinit, but Keep System

Postby Head_on_a_Stick » 2020-04-25 22:01

thmtrxhsu wrote:Now I'm not sure if you are referring to systemd or systemd-shim.

I am referring to systemd itself, the shim was abandoned by the original developers some time ago and is no longer properly maintained.

thmtrxhsu wrote:The first is covered by the bullseye repo which is enabled at all times.

Oh dear. You really don't have a clue what you're doing, do you? :roll:

Please check the output of
Code: Select all
apt policy systemd

You will notice that the MX version of systemd is the Candidate, this is because the MX devs applied an epoch to their version so that APT sees it as "newer" than the bullseye version.

Did you not wonder why a plain 'apt install' pulled the MX version instead of the bullseye version?

So if you want to keep the MX version of systemd updated then you will have to keep their repositories active. It may be worth noting that MX were running an outdated version of systemd for some months which included several vulnerabilities with official CVEs assigned, they only got around to updating it when I alerted them to the problem. Obviously I will try to stop this from happening again but...
User avatar
Head_on_a_Stick
 
Posts: 12132
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: Debian Bullseye Guide: Install Sysvinit, but Keep System

Postby sunrat » 2020-04-25 22:14

Head_on_a_Stick wrote:
thmtrxhsu wrote:The first is covered by the bullseye repo which is enabled at all times.

Oh dear. You really don't have a clue what you're doing, do you? :roll:


I'm glad you said it, I was just about to.
Adding Buster-based packages like this to Bullseye is a hybrid unmaintainable system.

@thmtrxhsu - I know it's exciting to experiment with different things like this and we have all done it, but please keep it to yourself and stop advising others to do it. Someone else will try it, totally screw up their system, and come asking you how to fix it.
“ computer users can be divided into 2 categories:
Those who have lost data
...and those who have not lost data YET ”
Remember to BACKUP!
User avatar
sunrat
 
Posts: 3086
Joined: 2006-08-29 09:12
Location: Melbourne, Australia

Re: Debian Bullseye Guide: Install Sysvinit, but Keep System

Postby thmtrxhsu » 2020-04-26 01:45

You guys are absolutely hilarious. Just a bunch of pompous arrogant dudes.

@ head on a stick

Firstly, since this was a bulleye install, systemd comes from bullseye.
"This embarrassing notion that you think it is coming from mx...is absolute folly and hilarious"

@ the other guy
You need to make sense. If you properly read what I wrote, here let me rewrite part of it for you 99.9% of the time only the bullseye repo should be enabled. This was in plain site in my original post.

But it seems two guys are "happy typers". That is they forgo the art of reading, enter the world of narcism and just utter what ever they like and declare themselves correct and superior; this is exceptional folly.

Well done you two. Bravo, I'm impressed.
thmtrxhsu
 
Posts: 18
Joined: 2020-04-09 13:46

Re: Debian Bullseye Guide: Install Sysvinit, but Keep System

Postby cuckooflew » 2020-04-26 02:16

This thread is getting to be entertaining,
Post by thmtrxhsu » 2020-04-26 01:45
You guys are absolutely hilarious.
So are you, thank you for the entertainment.
And yes,there is even some good advice:
by sunrat » 2020-04-25 22:14 )(partitial quote)
@thmtrxhsu - I know it's exciting to experiment with different things like this and we have all done it, but please keep it to yourself and stop advising others to do it. Someone else will try it, totally screw up their system, and come asking you how to fix it.

Be YEE advised, DO NOT try this on your main system, or in your real "home" it could be dangerous.
Steve, Where is the popcorn, please ? :mrgreen:
Please Read.. What we expect you have already Done.
Does any one know about this ?
Users browsing this forum: Google Knows, and
My grand father knows all about everything:
…one flew east, one flew west,
One flew over the cuckoo’s nest.
cuckooflew
 
Posts: 388
Joined: 2018-05-10 19:34
Location: Some where out west

Re: Debian Bullseye Guide: Install Sysvinit, but Keep System

Postby thmtrxhsu » 2020-04-26 02:41

Well you are right about something, "with great power comes great responsibility". I don't expect most users to make the right call. In fact, I expect most of them to make the wrong call. Nevertheless, for those that endeavors whether blinded or enlightened the path forth is clear should you take it. I know with 100% certainty that I can navigate without breaking a single package on the system. Noobs be forewarned, in this case when you play the lottery, you are guaranteed to win :) You either know what you are doing, you're learning or you haven't a damn clue. If any of the last two, I advise a virtual machine. But no need to re-invent the wheel, previously I was creating MX NoFrills with a Devuan base; this has been aborted for a superior Bullseye base the details (why, how) of which I shall not detail to the chagrin of some. But the point is, I will make it so your chances of messing the system up are significantly reduced. And it will already be awesomely configured.
thmtrxhsu
 
Posts: 18
Joined: 2020-04-09 13:46

Re: Debian Bullseye Guide: Install Sysvinit, but Keep System

Postby sunrat » 2020-04-26 03:24

Not sure if hubris or Dunning-Kruger effect.
:mrgreen:

TL;DR of your last post - don't do this.
Which is what we were saying.
“ computer users can be divided into 2 categories:
Those who have lost data
...and those who have not lost data YET ”
Remember to BACKUP!
User avatar
sunrat
 
Posts: 3086
Joined: 2006-08-29 09:12
Location: Melbourne, Australia

Re: Debian Bullseye Guide: Install Sysvinit, but Keep System

Postby Head_on_a_Stick » 2020-04-26 09:55

thmtrxhsu wrote:Firstly, since this was a bulleye install, systemd comes from bullseye.
"This embarrassing notion that you think it is coming from mx...is absolute folly and hilarious"

Oh really? Then why does the github page for MX's systemd-shim implementation say this (emphasis added):
This repo contains a fork of systemd-shim. It builds a Debian Buster based debian package for MX Linux. It depends on a modified systemd

But I'm bored 'cos of lockdown so I downloaded the Debian bullseye ISO image, installed it in a VM and tried to follow your "guide"...

After adding the MX and buster repositories (btw why do you suggest adding the contrib & non-free components when neither are needed?) I ran 'apt update' and was told some packages were upgradable:
Code: Select all
libnss-systemd/mx 1:241-7~deb10u3+mx19 amd64 [upgradable from: 245.5-1]
libpam-systemd/mx 1:241-7~deb10u3+mx19 amd64 [upgradable from: 245.5-1]
libsystemd0/mx 1:241-7~deb10u3+mx19 amd64 [upgradable from: 245.5-1]
libudev1/mx 1:241-7~deb10u3+mx19 amd64 [upgradable from: 245.5-1]
os-prober/mx 1.77mx19+1 amd64 [upgradable from: 1.77]
systemd-sysv/mx 1:241-7~deb10u3+mx19 amd64 [upgradable from: 245.5-1]
systemd/mx 1:241-7~deb10u3+mx19 amd64 [upgradable from: 245.5-1]
udev/mx 1:241-7~deb10u3+mx19 amd64 [upgradable from: 245.5-1]

Can you see the problem yet?

Let's see what the output of 'apt policy systemd' is for this bullseye system:
Code: Select all
systemd:
  Installed: 245.5-1
  Candidate: 1:241-7~deb10u3+mx19
  Version table:
     1:241-7~deb10u3+mx19 500
        500 http://mxrepo.com/mx/repo buster/main amd64 Packages
 *** 245.5-1 500
        500 http://deb.debian.org/debian bullseye/main amd64 Packages
        100 /var/lib/dpkg/status
     241-7~deb10u3 500
        500 http://deb.debian.org/debian buster/main amd64 Packages

Oh look, APT thinks the MX version is the newest and so should be upgraded to in preference to the bullseye version. Who could possibly have predicted that? :mrgreen:

I'm guessing that you don't even know what an epoch is :lol:

And here's what happens when I try the 'apt install' command listed in your idiotic OP:
Code: Select all
Reading package lists...
Building dependency tree...
Reading state information...
sysvinit-utils is already the newest version (2.96-3).
The following additional packages will be installed:
  cgmanager initscripts insserv libcgmanager0 libcurses-perl libcurses-ui-perl
  libidn11 libip4tc0 libnih-dbus1 libnih1 libnss-systemd libpam-systemd
  libsystemd0 libterm-readkey-perl psmisc startpar
Suggested packages:
  bootchart2 systemd-container policykit-1 pm-utils bootlogd
The following packages will be REMOVED:
  systemd-sysv systemd-timesyncd
The following NEW packages will be installed:
  cgmanager initscripts insserv libcgmanager0 libcurses-perl libcurses-ui-perl
  libidn11 libip4tc0 libnih-dbus1 libnih1 libterm-readkey-perl psmisc startpar
  systemd-shim sysv-rc sysv-rc-conf sysvinit-core
The following packages will be upgraded:
  libnss-systemd libpam-systemd libsystemd0 systemd
4 upgraded, 17 newly installed, 2 to remove and 3 not upgraded.
Need to get 5,656 kB of archives.
After this operation, 2,896 kB of additional disk space will be used.
Get:1 http://deb.debian.org/debian bullseye/main amd64 libidn11 amd64 1.33-2.2 [116 kB]
Get:2 http://deb.debian.org/debian buster/main amd64 libip4tc0 amd64 1.8.2-4 [70.2 kB]
Get:3 http://deb.debian.org/debian bullseye/main amd64 libnih1 amd64 1.0.3-10+b5 [127 kB]
Get:4 http://deb.debian.org/debian bullseye/main amd64 libnih-dbus1 amd64 1.0.3-10+b5 [98.1 kB]
Get:5 http://mxrepo.com/mx/repo buster/main amd64 libpam-systemd amd64 1:241-7~deb10u3+mx19 [209 kB]
Get:6 http://deb.debian.org/debian bullseye/main amd64 libcgmanager0 amd64 0.41-2+b1 [41.7 kB]
Get:7 http://deb.debian.org/debian bullseye/main amd64 cgmanager amd64 0.41-2+b1 [85.1 kB]
Get:8 http://deb.debian.org/debian bullseye/main amd64 sysvinit-core amd64 2.96-3 [153 kB]
Get:9 http://deb.debian.org/debian bullseye/main amd64 insserv amd64 1.21.0-1 [68.9 kB]
Get:10 http://deb.debian.org/debian bullseye/main amd64 startpar amd64 0.64-3 [23.5 kB]
Get:11 http://deb.debian.org/debian bullseye/main amd64 sysv-rc all 2.96-3 [33.3 kB]
Get:12 http://deb.debian.org/debian bullseye/main amd64 initscripts all 2.96-3 [57.7 kB]
Get:13 http://deb.debian.org/debian bullseye/main amd64 libcurses-perl amd64 1.36-1+b6 [94.5 kB]
Get:14 http://deb.debian.org/debian bullseye/main amd64 libterm-readkey-perl amd64 2.38-1+b1 [27.7 kB]
Get:15 http://deb.debian.org/debian bullseye/main amd64 libcurses-ui-perl all 0.9609-1 [241 kB]
Get:16 http://deb.debian.org/debian bullseye/main amd64 psmisc amd64 23.3-1 [131 kB]
Get:17 http://deb.debian.org/debian bullseye/main amd64 sysv-rc-conf all 0.99-7 [24.2 kB]
Get:18 http://mxrepo.com/mx/repo buster/main amd64 libnss-systemd amd64 1:241-7~deb10u3+mx19 [204 kB]
Get:19 http://mxrepo.com/mx/repo buster/main amd64 systemd amd64 1:241-7~deb10u3+mx19 [3,498 kB]
Get:20 http://mxrepo.com/mx/repo buster/main amd64 libsystemd0 amd64 1:241-7~deb10u3+mx19 [331 kB]
Get:21 http://mxrepo.com/mx/repo buster/main amd64 systemd-shim amd64 10-4 [20.3 kB]
apt-listchanges: Reading changelogs...
Preconfiguring packages ...
Fetched 5,656 kB in 3s (1,698 kB/s)
(Reading database ... 32768 files and directories currently installed.)
Preparing to unpack .../libpam-systemd_1%3a241-7~deb10u3+mx19_amd64.deb ...
Unpacking libpam-systemd:amd64 (1:241-7~deb10u3+mx19) over (245.5-1) ...
Preparing to unpack .../libnss-systemd_1%3a241-7~deb10u3+mx19_amd64.deb ...
Unpacking libnss-systemd:amd64 (1:241-7~deb10u3+mx19) over (245.5-1) ...
Preparing to unpack .../systemd_1%3a241-7~deb10u3+mx19_amd64.deb ...
Unpacking systemd (1:241-7~deb10u3+mx19) over (245.5-1) ...
dpkg: error processing archive /var/cache/apt/archives/systemd_1%3a241-7~deb10u3+mx19_amd64.deb (--unpack):
 trying to overwrite '/etc/dhcp/dhclient-exit-hooks.d/timesyncd', which is also in package systemd-timesyncd 245.5-1
dpkg-deb: error: paste subprocess was killed by signal (Broken pipe)
Errors were encountered while processing:
 /var/cache/apt/archives/systemd_1%3a241-7~deb10u3+mx19_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

So that's a pretty epic fail right there, well done. *slow handclap*
User avatar
Head_on_a_Stick
 
Posts: 12132
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: Debian Bullseye Guide: Install Sysvinit, but Keep System

Postby trinidad » 2020-04-26 12:00

But I'm bored 'cos of lockdown


Me too, but I'm happy you are too, because your replies like this help alleviate my cabin fever with a smile.

Not sure if hubris or Dunning-Kruger effect


Enjoy your philosophical/psychological backgrounded observations too. Fun stuff for gray days.

TC
You can't believe your eyes if your imagination is out of focus.
trinidad
 
Posts: 129
Joined: 2016-08-04 14:58


Return to Offtopic

Who is online

Users browsing this forum: No registered users and 5 guests

fashionable