You are not logged in.

#1 2021-02-06 22:01:52

rosenpin
Member
Registered: 2015-08-30
Posts: 29

[SOLVED] Failed boot after adding modules to mkinitcpio.conf

I'm trying to enable PCIe passthrough on my machine, I followed the instructions from the wiki and after I tried adding the vfio kernel modules on load I couldn't boot into my system.

At boot I would see something like

:: running early hooks [udev]
Starting version 247.2-1-arch

And then it will just get stuck

I booted from a flash drive and chroot into my system to revert the changes and after running 

sudo mkinitcpio -p linux

again I could boot normally.

I want to understand what I did wrong and where I could find logs related to the modules loading.


Thanks

Last edited by rosenpin (2021-02-06 23:15:04)

Offline

#2 2021-02-06 22:03:57

loqs
Member
Registered: 2014-03-06
Posts: 19,025

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

rosenpin wrote:

I want to understand what I did wrong and where I could find logs related to the modules loading.

Have you tried the journal?

Offline

#3 2021-02-06 22:05:41

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,349

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

Just from that, you shouldn't include the dots. And you did ensure that the relevant module parameters talked about earlier are set up? Other than that, try checking the journal of a failed boot

Offline

#4 2021-02-06 22:11:24

rosenpin
Member
Registered: 2015-08-30
Posts: 29

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

I found this in the journal

Feb 06 23:46:27 pc kernel: NVRM: The NVIDIA probe routine was not called for 1 device(s).
Feb 06 23:46:27 pc kernel: NVRM: This can occur when a driver such as:
                           NVRM: nouveau, rivafb, nvidiafb or rivatv
                           NVRM: was loaded and obtained ownership of the NVIDIA device(s).
Feb 06 23:46:27 pc kernel: NVRM: Try unloading the conflicting kernel module (and/or
                           NVRM: reconfigure your kernel without the conflicting
                           NVRM: driver(s)), then try loading the NVIDIA kernel module
                           NVRM: again.
Feb 06 23:46:27 pc kernel: NVRM: No NVIDIA devices probed.

Seems relevant though I don't think this could be what caused the boot to fail, could it?

Before rebooting I checked that I can modprobe those modules if that's what you mean, there wasn't any problem

Offline

#5 2021-02-06 22:14:55

loqs
Member
Registered: 2014-03-06
Posts: 19,025

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

Please post the full journal for a boot with the issue and the contents of /etc/mkinitcpio.conf

Offline

#6 2021-02-06 22:19:28

rosenpin
Member
Registered: 2015-08-30
Posts: 29

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

mkinitpcio.conf:

# vim:set ft=sh
# MODULES
# The following modules are loaded before any boot hooks are
# run.  Advanced users may wish to specify all system modules
# in this array.  For instance:
#     MODULES="piix ide_disk reiserfs"
MODULES=(vfio_pci vfio vfio_iommu_type1 vfio_virqfd)
#MODULES=""

# BINARIES
# This setting includes any additional binaries a given user may
# wish into the CPIO image.  This is run last, so it may be used to
# override the actual binaries included by a given hook
# BINARIES are dependency parsed, so you may safely ignore libraries
BINARIES=""

# FILES
# This setting is similar to BINARIES above, however, files are added
# as-is and are not parsed in any way.  This is useful for config files.
FILES=""

# HOOKS
# This is the most important setting in this file.  The HOOKS control the
# modules and scripts added to the image, and what happens at boot time.
# Order is important, and it is recommended that you do not change the
# order in which HOOKS are added.  Run 'mkinitcpio -H <hook name>' for
# help on a given hook.
# 'base' is _required_ unless you know precisely what you are doing.
# 'udev' is _required_ in order to automatically load modules
# 'filesystems' is _required_ unless you specify your fs modules in MODULES
# Examples:
##   This setup specifies all modules in the MODULES setting above.
##   No raid, lvm2, or encrypted root is needed.
#    HOOKS="base"
#
##   This setup will autodetect all modules for your system and should
##   work as a sane default
#    HOOKS="base udev autodetect block filesystems"
#
##   This setup will generate a 'full' image which supports most systems.
##   No autodetection is done.
#    HOOKS="base udev block filesystems"
#
##   This setup assembles a pata mdadm array with an encrypted root FS.
##   Note: See 'mkinitcpio -H mdadm' for more information on raid devices.
#    HOOKS="base udev block mdadm encrypt filesystems"
#
##   This setup loads an lvm2 volume group on a usb device.
#    HOOKS="base udev block lvm2 filesystems"
#
##   NOTE: If you have /usr on a separate partition, you MUST include the
#    usr, fsck and shutdown hooks.
HOOKS="base udev autodetect modconf block keyboard keymap resume filesystems fsck"

# COMPRESSION
# Use this to compress the initramfs image. By default, gzip compression
# is used. Use 'cat' to create an uncompressed image.
#COMPRESSION="gzip"
#COMPRESSION="bzip2"
#COMPRESSION="lzma"
#COMPRESSION="xz"
#COMPRESSION="lzop"
#COMPRESSION="lz4"

# COMPRESSION_OPTIONS
# Additional options for the compressor
#COMPRESSION_OPTIONS=""

The journal log is very long, so I posted it as a gist here:
https://gist.githubusercontent.com/rose … tfile1.txt

Offline

#7 2021-02-06 22:26:06

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,349

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

You do have an integrated GPU to cover the host and did enable that to be loaded in your UEFI/BIOS right? You can't passthrough your main card while expecting to be able to use it on the host. You need a secondary GPU.

Last edited by V1del (2021-02-06 22:26:22)

Offline

#8 2021-02-06 22:28:52

rosenpin
Member
Registered: 2015-08-30
Posts: 29

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

I didn't explicitly do it, I do have an integrated GPU though

How do I go about doing that? I didn't see it mentioned in the relevant wiki

These are the only kernel params I added in the process

intel_iommu=on iommu=pt

Offline

#9 2021-02-06 22:30:20

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,349

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

That depends on your mainboard, go into your UEFI/BIOS settings, most will disable the integrated GPU when a dedicated one exists, you need to explicitly enable that.

And you'd also likely need to replug your monitor into the integrated GPUs port/have a second one/multiple cables plugged into either.

Last edited by V1del (2021-02-06 22:33:37)

Offline

#10 2021-02-06 22:40:52

rosenpin
Member
Registered: 2015-08-30
Posts: 29

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

Oh I see, I misunderstood earlier

I enabled the option I believe was relevant (ASUS: Advanced > System Agent (SA) Configuration > Graphics Configuration > iGPU Multi-Monitor > Enabled)

After which I tried to reboot, after everything seemed to load correctly I was greeted with a black empty screen (where my login prompt should show up)

Here is the boot log
https://gist.githubusercontent.com/rose … tfile1.txt


Note: I didn't enable the kernel modules from earlier (that caused my system to not boot originally)

Offline

#11 2021-02-06 22:45:04

loqs
Member
Registered: 2014-03-06
Posts: 19,025

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

Feb 07 00:35:45 pc kernel: i915 0000:00:02.0: [drm] Cannot find any crtc or sizes
Feb 07 00:35:45 pc kernel: i915 0000:00:02.0: [drm] Cannot find any crtc or sizes
Feb 07 00:35:45 pc kernel: i915 0000:00:02.0: [drm] Cannot find any crtc or sizes

Just to confirm there is a display attached to the integrated GPU and the i915 module can not detect it rather than there is no display to detect?

Last edited by loqs (2021-02-06 22:45:22)

Offline

#12 2021-02-06 22:46:43

rosenpin
Member
Registered: 2015-08-30
Posts: 29

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

The display is connected to my Nvidia graphics card, am I supposed to connect it to the integrated graphics card?

Offline

#13 2021-02-06 22:50:58

loqs
Member
Registered: 2014-03-06
Posts: 19,025

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

When you pass through the Nvidia GPU it no longer exists as far as the linux host is concerned so you need a display attached to the integrated GPU or you would need to connect to the host through some other means e.g. ssh.

Offline

#14 2021-02-06 22:52:34

rosenpin
Member
Registered: 2015-08-30
Posts: 29

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

I see, makes sense

But when I try to boot connected to the integrated graphics card nothing shows up at all (including BIOS, grub or anything else)

Offline

#15 2021-02-06 22:55:57

rosenpin
Member
Registered: 2015-08-30
Posts: 29

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

Ok I managed to boot using the integrated graphics card (set it as default in bios)

But now I can't start X

Edit: obviously it doesn't work, I'm using nvidia xorg config

Last edited by rosenpin (2021-02-06 22:59:16)

Offline

#16 2021-02-06 23:09:05

rosenpin
Member
Registered: 2015-08-30
Posts: 29

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

Changed my config to xorg, seems to work now

Thanks for your help!

Offline

#17 2021-02-06 23:14:17

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,349

Re: [SOLVED] Failed boot after adding modules to mkinitcpio.conf

Great, please mark the thread as [SOLVED] by editing the title in the first post

Offline

Board footer

Powered by FluxBB