Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
system won't boot after switching to systemd
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
Featherfoot
l33t
l33t


Joined: 28 Dec 2002
Posts: 973
Location: Stuart, Florida

PostPosted: Sat Dec 30, 2017 3:23 am    Post subject: system won't boot after switching to systemd Reply with quote

I am trying to update my system to profile 17 with systemd. I believe I have configured systemd and the associated system files correctly and I now have a problem configuring my grub2 entry to work.

menuentry 1 (Gentoo 4.12.12) is the systemd entry. It does not locate the correct root.
menuentry 2 ( Gentoo 4.14.8-r1) is the sysvinit entry it works correctly.

The main difference between the files is the init=/lib/systemd/systemd entry. I am following the example for grub2 in the systemd Wiki, but of course, it is much simpler. Can you suggest how to configure it for this real world case?

Code:


menuentry 'Gentoo 4.12.12 on SSD' --class gentoo --class gnu-linux --class os {
   recordfail
   insmod part_msdos
   insmod ext2
   set root='(hd2,msdos5)'
#        search --no-floppy --fs-uuid --set=root 8b524b22-ca28-49c1-8bbf-9361f7e3f23f
        search --no-floppy --fs-uuid --set=root dfbd92d1-ef3f-4496-bc71-97aacf0fd096
        linux   /kernel-genkernel-x86_64-4.12.12-gentoo root=/dev/ram0 init=/lib/systemd/systemd real_root=UUID=ce12cbd3-e132-49fd-9076-4a444316c489 dodmraid ro
        initrd  /initramfs-genkernel-x86_64-4.12.12-gentoo
}

menuentry 'Gentoo 4.14.8-r1 on SSD' --class gentoo --class gnu-linux --class os {
   recordfail
   insmod part_msdos
   insmod ext2
   set root='(hd2,msdos5)'
        search --no-floppy --fs-uuid --set=root dfbd92d1-ef3f-4496-bc71-97aacf0fd096
        linux   /kernel-genkernel-x86_64-4.14.8-gentoo-r1 root=/dev/ram0 real_root=UUID=ce12cbd3-e132-49fd-9076-4a444316c489 dodmraid ro
        initrd  /initramfs-genkernel-x86_64-4.14.8-gentoo-r1
}


Back to top
View user's profile Send private message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 7073
Location: almost Mile High in the USA

PostPosted: Sat Dec 30, 2017 3:43 am    Post subject: Reply with quote

My systemd binary is at /usr/lib/systemd/systemd ... I suspect the handbook is setting it so that grub-mkconfig will automatically get the right setting for you...

But before that, what is the error that's being shown? Hopefully not just "init not found" ?

BTW, you need to make sure your initramfs knows how to locate the systemd binary. I had to hack my initramfs to handle systemd ("real_init=/usr/lib/systemd/systemd") -- which initramfs are you using?
_________________
Intel Core i7 2700K@ 4.1GHz/HD3000 graphics/8GB DDR3/180GB SSD
What am I supposed watching?


Last edited by eccerr0r on Sat Dec 30, 2017 3:45 am; edited 1 time in total
Back to top
View user's profile Send private message
Featherfoot
l33t
l33t


Joined: 28 Dec 2002
Posts: 973
Location: Stuart, Florida

PostPosted: Sat Dec 30, 2017 3:44 am    Post subject: Reply with quote

No, it can't find the root.
Back to top
View user's profile Send private message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 7073
Location: almost Mile High in the USA

PostPosted: Sat Dec 30, 2017 3:54 am    Post subject: Reply with quote

Please post the exact error or picture of the error... Too many assumptions have to be made here to debug due to the initramfs.

What happens if you use the known working kernel, does it also have problems finding root?
_________________
Intel Core i7 2700K@ 4.1GHz/HD3000 graphics/8GB DDR3/180GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
Featherfoot
l33t
l33t


Joined: 28 Dec 2002
Posts: 973
Location: Stuart, Florida

PostPosted: Sun Dec 31, 2017 12:32 am    Post subject: Reply with quote

You pointed out that the address of the init link was wrong. (Foolish me trusting documentation without checking.) Fixing that and the boot worked!

I still have a couple of serious problems:

XWindows won't start. I re-emerged xorg-server with no results

Ethernet won't start.

Not sure how to troubleshoot these problems, but will poke around.

Glad to have multi-boot systems.
Back to top
View user's profile Send private message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 7073
Location: almost Mile High in the USA

PostPosted: Sun Dec 31, 2017 11:42 am    Post subject: Reply with quote

Systemd network access is different than openrc, unless you were using networkmanager.
If not using NM, you'll need to configure it manually. https://wiki.gentoo.org/wiki/Systemd#Network
If you were using NM, other than enabling the networkmanager unit (systemctl enable NetworkManager.service IIRC), it should be the same config.

For X11, need more information. What are you using (display manager?), what works, what doesn't, what's in your /var/log/Xorg.0.log ?
_________________
Intel Core i7 2700K@ 4.1GHz/HD3000 graphics/8GB DDR3/180GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum