Sent: Thursday, June 05, 2014 at 8:52 PM
From: "Cliff McDiarmid" <[email protected]>
To: BLFS <[email protected]>
Subject: Systemd conversion now goes wrong
From: "Cliff McDiarmid" <[email protected]>
To: BLFS <[email protected]>
Subject: Systemd conversion now goes wrong
Hi
Some weeks ago I converted a LFS7.5 system to use systemd. I had advice from the forum and things went well, had to do upower and polkit reinstalls, but the system has been running well.
So I decided tonight to complete the switch and uninstall SysVinit, following the hint from Chris Wagner 2012-10-03.
This is the extract:
After systemd is running well, SysVinit can be removed . Check, that no
more LSB scripts are used by systemd using the following command:
more LSB scripts are used by systemd using the following command:
systemctl | grep LSB
Remove the files belonging to SysVinit:
rm -v /usr/bin/{last,lastb,mesg,utmpdump}
rm -v /usr/include/initreq.h /etc/inittab /bin/pidof
rm -v /usr/share/man/man1/{last.1*,lastb.1*,mesg.1*,utmpdump.1*}
rm -v /usr/share/man/man5/{initscript.5*,inittab.5*}
rm -v /usr/share/man/man8/{bootlogd.8*,fstab-decode.8*}
rm -v /usr/share/man/man8/{fstab-decode.8*,init.8*}
rm -v /usr/share/man/man8/{killall5.8*,pidof.8*,sulogin.8*}
rm -v /sbin/{bootlogd,fstab-decode,halt,init,killall5,poweroff}
rm -v /sbin/{reboot,runlevel,shutdown,sulogin,telinit}
Replace sysvinit commands with links to systemd:
rm -v /usr/include/initreq.h /etc/inittab /bin/pidof
rm -v /usr/share/man/man1/{last.1*,lastb.1*,mesg.1*,utmpdump.1*}
rm -v /usr/share/man/man5/{initscript.5*,inittab.5*}
rm -v /usr/share/man/man8/{bootlogd.8*,fstab-decode.8*}
rm -v /usr/share/man/man8/{fstab-decode.8*,init.8*}
rm -v /usr/share/man/man8/{killall5.8*,pidof.8*,sulogin.8*}
rm -v /sbin/{bootlogd,fstab-decode,halt,init,killall5,poweroff}
rm -v /sbin/{reboot,runlevel,shutdown,sulogin,telinit}
Replace sysvinit commands with links to systemd:
ln -sv /usr/lib/systemd/systemd /sbin/init
for tool in runlevel reboot shutdown poweroff halt telinit; do
ln -svf '/usr/bin/systemctl' "/sbin/$tool"
done
#### Uninstall LFS-Bootscripts
for tool in runlevel reboot shutdown poweroff halt telinit; do
ln -svf '/usr/bin/systemctl' "/sbin/$tool"
done
#### Uninstall LFS-Bootscripts
Now we can also move out the lfs-bootscripts and those services
installed with other programs:
installed with other programs:
mkdir -pv /etc/rc.bak
tar -czpvf "/etc/rc.bak/rc.d-backup.tar.gz" /etc/rc.d
rm -v /etc/rc.d/init.d/*
for rcX in rc0 rc1 rc2 rc3 rc4 rc5 rc6 rcS; do
rm -v /etc/rc.d/$rcX.d/*
done
tar -czpvf "/etc/rc.bak/rc.d-backup.tar.gz" /etc/rc.d
rm -v /etc/rc.d/init.d/*
for rcX in rc0 rc1 rc2 rc3 rc4 rc5 rc6 rcS; do
rm -v /etc/rc.d/$rcX.d/*
done
Removing /etc/mtab earlier would cause an error in /init.d/mountfs when
booting LFS via sysvinit. Now that we are not using the init scripts any
more, we can make this change:
booting LFS via sysvinit. Now that we are not using the init scripts any
more, we can make this change:
ln -svf /proc/mounts /etc/mtab
Unfortunately when I boot now I get the following:
sh: cannot set terminal process group (-1):
Inappropriate ioctl for device
sh: no job control in this shell
sh: no job control in this shell
random:non-blocking pool is initialized
sh-4.2#
sh-4.2#
Any ideas how to get out of this one? I followed this method on another LFS and it worked.
thanks
Cliff
-- http://lists.linuxfromscratch.org/listinfo/blfs-support FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page
