Currently I use the following line in /etc/default/grub:

GRUB_CMDLINE_LINUX_DEFAULT="rd.modules-load=vfio-pci amd_iommu=on iommu=pt kvm.ignore_msrs=1 vfio-pci.ids=10de:1e84,10de:10f8"

The purpose of the above line is to reserve the primary GPU for later use by a VM using vfio.

The setup I have is:

  • Asus PRIME B450-PLUS
  • AMD Ryzen 7 3700X 8-Core Processor
  • Primary: TU104 [GeForce RTX 2070 SUPER] via DP
  • Secondary: GK208B [GeForce GT 710] via HDMI
  • Lenovo ThinkVision 2560x1440 display with HDMI and DP in (for switching between host and VMs by pressing the monitor buttons).

There is no setting on the mobo as to which GPU is primary and I do not have integrated graphics on the CPU.

What happens now Grub loads and starts showing the messages on the primary GPU and gets to this line:

[ 0.843241] vfio-pci 0000:07:00.0: vgaarb: changed VGA decodes: olddecodes=io+mem,decodes=io+mem:owns=io+mem

That screen freezes. I then have to type in the LUKS password blindly, wait a bit, then switch the monitor to HDMI for the secondary GPU. At this point I see the Ubuntu log in screen.

What I'd like to happen I would like the GRUB bootloader to use the secondary GPU as soon as it realizes there is one. I would like the messages from GRUB to appear on the secondary GPU so that I get the LUKS prompt and I can type in my password non-blindly. This would also help with any future boot problems as I'll see what is happening. This would also hopefully remove the video from the primary GPU as currently it just shows the last thing it saw - when the computer goes to sleep, the monitor auto-switches back to the lines from GRUB.

  • What version of Ubuntu?
    – David
    Dec 30 '20 at 14:51
  • Ubuntu 20.04, sorry didn't specify.
    – dim_voly
    Dec 31 '20 at 0:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.