Disposal of systemd
Systemd and System V (SysV) are two start-up systems used in Linux distributions to manage system and service boot. System V (SysV) is a traditional start-up system that uses shell scripts stored at different running levels (runlevels) to start and stop services sequentially. It was widely used in many Unix and Linux distributions for decades. On the other hand, Systemd is a more modern and advanced start-up system that replaces SysV. Incorporated to improve system start speed and efficiency, systemd uses a unit-based approach and depends on paralleling to start services simultaneously. It also includes additional features such as service management, sockets, timers, and dependencies, making it a more robust and flexible option compared to SysV.
Migration from systemd to systemV
Modify /etc/apt/sources.list to point to Daedalus repositories that is the equivalent of Debian 12 in Devuan.
root@ASOjaviercruces:~# nano /etc/apt/sources.list
Modify sources.list to look like the one provided. Comes on all the other lines.
root@ASOjaviercruces:~# cat /etc/apt/sources.list
deb http://deb.devuan.org/merged daedalus main
deb http://deb.devuan.org/merged daedalus-updates main
deb http://deb.devuan.org/merged daedalus-security main
deb http://deb.devuan.org/merged daedalus-backports main
It updates the package lists from the Daedalus repositories, allowing unsafe origins as it is signed the repositories.
root@ASOjaviercruces:~# apt-get update --allow-insecure-repositories
Install Devuan’s key ring to authenticate the repository and packages.
root@ASOjaviercruces:~# apt-get install devuan-keyring --allow-unauthenticated
Update the package lists again to authenticate the repositories and packages.
root@ASOjaviercruces:~# apt-get update
Update the installed packages to the latest versions. Note that this does not complete migration to system-v.
root@ASOjaviercruces:~# apt-get upgrade (ten cuidado de NO usar dist-upgrade aquí)
We install the eudev and sysvinit@-@ core packages to efficiently manage the detection and configuration of devices through eudev, while sysvinit@-@ core is in charge of the control of the start and process system.
root@ASOjaviercruces:~# apt-get install eudev sysvinit-core
The last command may cause package breakages, but they will be resolved as part of the migration process.
root@ASOjaviercruces:~# apt-get -f install
A reboot is required to change the change from systemd to systemV.
root@ASOjaviercruces:~# reboot
We will update the distribution to move the packages from using systemd to systemV.
root@ASOjaviercruces:~# apt-get dist-upgrade
Once migration to Devuan is completed, it eliminates the packages related to systemd.
root@ASOjaviercruces:~# apt-get purge systemd libnss-systemd
Eliminates any orphan package generated by the migration process and any unusable cache file.
root@ASOjaviercruces:~# apt-get autoremove --purge
root@ASOjaviercruces:~# apt-get autoclean
# Checking and using systemV
Check that process 1 is init, this means that the system has started using systemV:
root@ASOjaviercruces:~# ps -s1
PID TTY TIME CMD
1 ? 00:00:00 init
I will install a service that should depend on systemd but as we have changed to systemv, I will not use it as we now use Devuan’s repositories:
debian@ASOjaviercruces:~$ sudo apt install apache2 -y
Then to manage the service we will do it from the / etc / init.d / directory and looking for the “service” of each demon:
#Para iniciar el servicio
debian@ASOjaviercruces:~$ sudo /etc/init.d/apache2 start
Starting Apache httpd web server: apache2.
#Para parar el servicio
debian@ASOjaviercruces:~$ sudo /etc/init.d/apache2 stop
Stopping Apache httpd web server: apache2.
#Para reiniciar el servicio
debian@ASOjaviercruces:~$ sudo /etc/init.d/apache2 restart
Restarting Apache httpd web server: apache2AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 192.168.122.208. Set the 'ServerName' directive globally to suppress this message
.
#Para ver el estado
debian@ASOjaviercruces:~$ sudo /etc/init.d/apache2 status
apache2 is running.