Pages

Unixbhaskar's Blog

Thursday, September 20, 2012

Best possible way to Systemd's transition from /lib to usr/lib on Arch Linux


Okay,I seriously had struggle(due to my lack of brilliance) for this transition ,once I update one regular update on Arch Linux by ignoring glibc like previous time.And only found out that kernel image creation is not possible. Because the kernel module location has changed with new kernel with systemd.So ,it was trowing "module not found error"..irk..

And I was trying to do it from chroot environment on Fedora and Gentoo.

After several hours of brain scratching and hover through different forum thread at Arch Linux site;I landed on a wiki page ,which solve the mystery.

The simplest possible way to do this transition from chroot environment is below:



pacman -Syv
pacman -S busybox rsync
rsync -rapv /lib/ /usr/lib/
mv /lib/ /lib.backup/
busybox ln -s /usr/lib/ /lib
# rm -rf /usr/lib/modules/
ldconfig
pacman -Suv
pacman -Sf glibc linux
rm -rf /lib.backup/



And please do it sequentially.Period.

If you don't do that, then the glibc and as well the system will be broken for ever for the new kernel which run systemd for boot.You just cannot create or make the new kernel image by running mkinitcpio! which was the case with me.

Hope this will help.

Cheers!
Bhaskar