The officially official Devuan Forum!

You are not logged in.

#1 2024-04-07 16:17:46

deepforest
Member
Registered: 2020-03-24
Posts: 354  

[SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

If it possible, how do this?

Thanks.


-=linux its buggy crap that have no antifool protection (c)=- smile
*linux is free software, and comes with ABSOLUTELY NO WARRANTY* smile
+ALL YOURS ACTIONS at Linux YOU DO at YOUR OWN RISK!+ smile

Offline

#2 2024-04-07 18:31:30

nahkhiirmees
Member
Registered: 2022-07-24
Posts: 261  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

Not sure if this helps, but: have you tried dpkg -reconfigure ?

Offline

#3 2024-04-07 20:49:59

deepforest
Member
Registered: 2020-03-24
Posts: 354  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

Thanks for reply
Are you mean install runit and do dpkg-reconfigure openrc or dpkg-reconfigure runit?
Is it safe, i am aware that i can broke os by this commands?


-=linux its buggy crap that have no antifool protection (c)=- smile
*linux is free software, and comes with ABSOLUTELY NO WARRANTY* smile
+ALL YOURS ACTIONS at Linux YOU DO at YOUR OWN RISK!+ smile

Offline

#4 2024-04-07 22:35:07

nahkhiirmees
Member
Registered: 2022-07-24
Posts: 261  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

Haven't actually tried to change the init system after the install.
And after some thinking, update-alternatives sounds more like what deepforest is after.

Offline

#5 2024-04-11 20:51:20

Lorenzo
Member
Registered: 2020-03-03
Posts: 46  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

Hi,

If it possible, how do this?

try the following

apt-get install runit-init

and then reboot the system

reboot

if plain 'reboot' doesn't work you may have to call
/usr/sbin/openrc-shutdown with appropriate options to reboot into runit

I tested sysv --> runit and going back to sysv, never tested from
openrc but it should work.

Best,
Lorenzo

Offline

#6 2024-04-25 20:24:42

deepforest
Member
Registered: 2020-03-24
Posts: 354  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

@Lorenzo
Thanks man!
it seems to have worked smile But i not feeling any difference, only boot log looks another.
its was easy.
And to move back i must uninstall runit-init and make dpkg-reconfigure openrc or reinstall openrc?

Last edited by deepforest (2024-04-25 20:48:33)


-=linux its buggy crap that have no antifool protection (c)=- smile
*linux is free software, and comes with ABSOLUTELY NO WARRANTY* smile
+ALL YOURS ACTIONS at Linux YOU DO at YOUR OWN RISK!+ smile

Offline

#7 2024-04-25 23:20:10

Lorenzo
Member
Registered: 2020-03-03
Posts: 46  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

it seems to have worked smile But i not feeling any difference, only boot log looks another.
its was easy.

did you installed also runit-services package?

And to move back i must uninstall runit-init and make dpkg-reconfigure openrc or reinstall openrc?

I don't think dpkg-reconfigure has any use here; reinstall openrc + sysvinit-core should do it.
Then, to reboot from runit into openrc call

/lib/runit/runit-init 6

Offline

#8 2024-04-28 22:23:49

deepforest
Member
Registered: 2020-03-24
Posts: 354  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

did you installed also runit-services package?

idk, only this apt-get install runit-init

I don't think dpkg-reconfigure has any use here; reinstall openrc + sysvinit-core should do it.
Then, to reboot from runit into openrc call

Thanks, reinstall only openrc? Why you mentioned +sysvinit-core?


-=linux its buggy crap that have no antifool protection (c)=- smile
*linux is free software, and comes with ABSOLUTELY NO WARRANTY* smile
+ALL YOURS ACTIONS at Linux YOU DO at YOUR OWN RISK!+ smile

Offline

#9 2024-04-28 23:24:34

Lorenzo
Member
Registered: 2020-03-03
Posts: 46  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

Thanks, reinstall only openrc? Why you mentioned +sysvinit-core?

Originally openrc used to run on top of sysvinit, so you need sysvinit-core + openrc;
recently openrc got it's own init, so it can run without sysvinit.
I'm not sure what the openrc deb package does, if you install openrc without sysvinit-core
just make sure that /sbin/init points to somewhere that make sense for openrc, like
maybe

/usr/sbin/openrc-init

I never used openrc so I'm more or less guessing the above.

Offline

#10 2024-04-30 20:22:53

deepforest
Member
Registered: 2020-03-24
Posts: 354  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

i am trying move back to open rc,
already reinstall openrc and sysvinit-core,
system booting good in openrc,
but why i see this?

root@home:/home/freeartist-devuan# dpkg-reconfigure openrc
/usr/sbin/dpkg-reconfigure: openrc is broken or not fully installed
root@home:/home/freeartist-devuan# 
freeartist-devuan@home:~$ sudo su
[sudo] password for freeartist-devuan: 
root@home:/home/freeartist-devuan# dpkg-reconfigure openrc
/usr/sbin/dpkg-reconfigure: openrc is broken or not fully installed
root@home:/home/freeartist-devuan# apt install openrc
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
openrc is already the newest version (0.45.2-2).
The following package was automatically installed and is no longer required:
  sysuser-helper
Use 'sudo apt autoremove' to remove it.
0 upgraded, 0 newly installed, 0 to remove and 23 not upgraded.
2 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] 
Setting up openrc (0.45.2-2) ...
Add existing services ...
 * rc-update: killprocs already installed in runlevel `recovery'; skipping
 * rc-update: single already installed in runlevel `recovery'; skipping
 * rc-update: bootlogs already installed in runlevel `recovery'; skipping
 * rc-update: console-setup.sh already installed in runlevel `default'; skipping
 * rc-update: binfmt-support already installed in runlevel `default'; skipping
 * rc-update: mono-xsp4 already installed in runlevel `default'; skipping
 * rc-update: pulseaudio-enable-autospawn already installed in runlevel `default'; skipping
 * rc-update: rsyslog already installed in runlevel `default'; skipping
 * rc-update: sudo already installed in runlevel `default'; skipping
 * rc-update: uuidd already installed in runlevel `default'; skipping
 * rc-update: service `acpid' is not executable
dpkg: error processing package openrc (--configure):
 installed openrc package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of sysvinit-core:
 sysvinit-core depends on sysv-rc | openrc | file-rc; however:
  Package sysv-rc is not installed.
  Package openrc is not configured yet.
  Package file-rc is not installed.

dpkg: error processing package sysvinit-core (--configure):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 openrc
 sysvinit-core
E: Sub-process /usr/bin/dpkg returned an error code (1)
root@home:/home/freeartist-devuan# 

Last edited by deepforest (2024-04-30 20:24:01)


-=linux its buggy crap that have no antifool protection (c)=- smile
*linux is free software, and comes with ABSOLUTELY NO WARRANTY* smile
+ALL YOURS ACTIONS at Linux YOU DO at YOUR OWN RISK!+ smile

Offline

#11 2024-04-30 21:45:15

Lorenzo
Member
Registered: 2020-03-03
Posts: 46  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

it looks like there is a problem with openrc postinstall script, likely a bug. As already mentioned, I know very few about openrc so I don't have an explanation. I suggest you open a bug report on openrc package linking this page

Lorenzo

Offline

#12 2024-04-30 22:02:14

Kristof12
Member
Registered: 2023-12-01
Posts: 9  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

A file that is not executable on /etc/init.d/ breaks openrc installation for some reason, needs to make executable first or move to another directory

Offline

#13 2024-05-01 21:34:18

Lorenzo
Member
Registered: 2020-03-03
Posts: 46  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

A file that is not executable on /etc/init.d/ breaks openrc installation for some reason, needs to make executable first or move to another directory

Please, next time, report bug like this! Nobody reports = nobody fixes.
It's now fixed in unstable/openrc 0.54-2
https://bugs.debian.org/cgi-bin/bugrepo … ug=1070167

Offline

#14 2024-05-02 07:29:00

delgado
Member
Registered: 2022-07-14
Posts: 213  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

From Lorenzo's bug report:

Note that recently debhelper started to chmod -x initscripts when a package is
removed but not purged, (...)

That sounds terrible!
Is the consequence, that any sysv initscript needs to be updated to fix this behavior?
(Or: If you have such a "helper" you don't need enemies.)

Back to main topic:
Unused stuff can be removed - sorry purged - too apt purge openrc.

Last edited by delgado (2024-05-02 07:39:24)

Offline

#15 2024-05-02 13:58:06

Kristof12
Member
Registered: 2023-12-01
Posts: 9  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

Please, next time, report bug like this! Nobody reports = nobody fixes.
It's now fixed in unstable/openrc 0.54-2
https://bugs.debian.org/cgi-bin/bugrepo … ug=1070167

Thanks with the bug report and updated here

Offline

#16 2024-05-02 21:18:44

deepforest
Member
Registered: 2020-03-24
Posts: 354  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

move back to openrc
uninstall runit-init
reinstall sysvinit-core
reconfigure openrc
working, booting, as usual, nothing is broken

Last edited by deepforest (2024-05-02 21:49:55)


-=linux its buggy crap that have no antifool protection (c)=- smile
*linux is free software, and comes with ABSOLUTELY NO WARRANTY* smile
+ALL YOURS ACTIONS at Linux YOU DO at YOUR OWN RISK!+ smile

Offline

#17 2024-05-02 22:19:10

golinux
Administrator
Registered: 2016-11-25
Posts: 3,318  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

Congrats!

Offline

#18 2024-05-04 09:17:34

Lorenzo
Member
Registered: 2020-03-03
Posts: 46  

Re: [SOLVED] Daedalus. Can i switch from openrc to runit without reinstall os?

From Lorenzo's bug report:

    Note that recently debhelper started to chmod -x initscripts when a package is
    removed but not purged, (...)

That sounds terrible!

Why? in any case the sysv script is not usable if the binary is not installed. The chmod - x is done for heuristics, for example to be able to tell if the binary is installed and avoid to unecessary call the script if it's not (I'm talking about automatic start/restart that happens in maintainers script during package upgrades)

Is the consequence, that any sysv initscript needs to be updated to fix this behavior?
(Or: If you have such a "helper" you don't need enemies.)

Not really: the script is automatically chmod +x as soon as you reinstall the package, you don't need to worry about this.  Other tools around initscript (invoke-rc.d, runit's /lib/runit/run_sysv_scripts) were changed to cope with non executable initscripts, openrc was just lagging behind.
Note that debhelper is used at build time to help pkg maintainers to automate the build process, it affects build-time, it doesn't affects runtime.

Lorenzo

Offline

Board footer