Bumblebee-Project / Bumblebee

Bumblebee daemon and client rewritten in C
http://www.bumblebee-project.org/
GNU General Public License v3.0
1.29k stars 142 forks source link

[ERROR]Cannot access secondary GPU - error: [XORG] (EE) [drm] Failed to open DRM device for pci:0000:01:00.0: -19 #945

Open TungstenOxide opened 6 years ago

TungstenOxide commented 6 years ago

I'm running an XPS 9560 with an i7-7700HQ and a GTX 1050. Fedora 27, kernel 4.11.14. Through one hell of a ritual, I can load into the desktop and be stable. Installed using the Fedora wiki. https://fedoraproject.org/wiki/Bumblebee Then to boot, I add a 3 to the end of my boot line to go to CLI Then in CLI, I run sudo service bumblebee start su echo "ON" >/proc/acpi/bbswitch exit sudo init 5 and that gets me to the desktop. Then, when I try to run anything with Optirun, I get this:

[  357.115235] [ERROR]Cannot access secondary GPU - error: [XORG] (EE) [drm] Failed to open DRM device for pci:0000:01:00.0: -19

[  357.115304] [ERROR]Aborting because fallback start is disabled.

This is different from #913 . That fix does not work for this issue. Can anybody shed some light on this? THANK YOU!

gsgatlin commented 6 years ago

Someone suggested in #764 that acpi=! acpi='Windows 2009' added to kernel command line worked for them.

editing /etc/default/grub then running grub2-mkconfig -o /boot/efi/EFI/fedora/grub.cfg on a EFI system.

The packages referenced in the fedora wiki are made by Andrew Gunnerson in a copr. I am not involved at all with that. I also have never had time to test any of that on my laptops. But perhaps he might know or have some ideas?

https://github.com/chenxiaolong/fedora-packages/tree/master/copr/bumblebee

Perhaps you may wish to open a new issue in his repo?

See also:

https://www.reddit.com/r/Fedora/comments/7tpr2w/having_trouble_installing_bumblebee_and_its/

Supposedly my packages worked for that reddit user (shstan)

docs I wrote for my packages: https://www.linux.ncsu.edu/bumblebee/

Cheers,

TungstenOxide commented 6 years ago

Alright, I'll try that and report back. I'll also make sure to open an issue in his repo as well.

TungstenOxide commented 6 years ago

Okay, tried that (was suuuuper busy) and now I can boot and load GUI without issues, but I'm still getting [ 351.914526] [ERROR]Cannot access secondary GPU - error: [XORG] (EE) [drm] Failed to open DRM device for pci:0000:01:00.0: -19 whenever running optirun or primusrun

TungstenOxide commented 6 years ago

Also xorg doesn't work. I'll log in and it'll dump me back on the login page as if it's crashing or something

TungstenOxide commented 6 years ago

Nvm fixed that by deleting something a nouveau.modeset parameter. Full GRUB line now looks like this when Bumblebee is installed to be stable: GRUB_CMDLINE_LINUX="rd.lvm.lv=fedora/root rd.lvm.lv=fedora/swap nouveau.modeset=0 rhgb quiet acpi_osi=! acpi_osi='Windows 2009'"

But the main problem still remains: [ 351.914526] [ERROR]Cannot access secondary GPU - error: [XORG] (EE) [drm] Failed to open DRM device for pci:0000:01:00.0: -19. Anybody know what's going on?

TungstenOxide commented 6 years ago

I might have found a solution. According to chenxiaolong, you install Bumblebee according to the wiki and then add this to your boot line. acpi_rev_override rd.driver.blacklist=nouveau modprobe.blacklist=nouveau

Actually, I have the same laptop as you (XPS 9560 w/NVIDIA GTX 1050). I'd suggest booting with:

acpi_rev_override rd.driver.blacklist=nouveau modprobe.blacklist=nouveau

and removing any reference to acpi_osi. I blacklist nouveau to prevent the system from hanging due to a bug in the driver and set the ACPI revision to 5 to allow bbswitch to work. Note that this requires kernel 4.15+ on Fedora because earlier Fedora kernels were compiled without support for acpi_rev_override. It might be necessary to reboot twice for acpi_rev_override to take effect. I didn't have to do anything else on my laptop to get Bumblebee working.

I'm still testing this, so I'll report back with any issues, but I can boot and be stable and use Xorg and optirun so this is looking promising.

TungstenOxide commented 6 years ago

Oh hey guys I'm back.

So Fedora works flawlessly with the last post's information. Now I've moved to Debian.

So I applied my knowledge from the previous post, set the kernel params, and I got Bumblebee to install and be stable, but now I've got quite the interesting predicament.

The computer reports that it's using the GPU, but from its performance, it's clearly not. In Fedora, I pull 60FPS in glxgears with the iGPU and around 2700 with the dGPU. In Debian, I'm pulling 60 with "both." I also tested Besiege, because I should be getting about 25 in 4K and a silky smooth 60 in 1440p, but I'm barely getting 5FPS in 4K and my GPU fan isn't running.

I think that the computer thinks it's using the GPU, but it's really not. I have no idea why. With no kernel params, my computer freezes when starting Light DM. Also, lspci | grep 3D doesn't actually return the name of a card, just 01:00.0 3D controller: NVIDIA Corporation Device 1c8d (rev ff)

Ideas?

gentunian commented 5 years ago

I might have found a solution. According to chenxiaolong, you install Bumblebee according to the wiki and then add this to your boot line. acpi_rev_override rd.driver.blacklist=nouveau modprobe.blacklist=nouveau

I had the same issue and I needed to add acpi_rev_override. I already had rd.driver.blacklist=nouveau modprobe.blacklist=nouveau so I guess I was missing that. Thanks for leaving this for us! :)