Nvidia Optimus on XPS 15 9560


I have tried migrating my system from the open source nvidia drivers to the proprietary ones. First I tried with the nvidia-dkms-installer and the -b flag, which installed everything fine but made the system unbootable (I could not even open tty with Ctrl+Alt+F2), then I tried following the guides from here
and here

but in both cases no matter how many configs I changed and initramfs I adapted, I always got stuck at sddm failing to “read the display number from pipe”. So the service would start, xorg would report “unable to get display device for dpi computation” and thats the end of it. I am now on a fresh Endeavour + KDE install, because whatever I would try I could not revert the changes I made and sddm would outright refuse to find the display. So my question is, did anyone have success setting up nvidia optimus on Endeavour with KDE in such a way one could use the integrated graphics and the discrete GPU and if so: Does anyone happen to know where to find a complete and reproducible guide?

This is not recommended! Bumblebee is deprecated. Please read this info

You can easily revert back to nouveau using the -n flag. Also note that Optimus is only needed if you have a hybrid card and want to switch between say Intel and Nvidia card. I use a hybrid card laptop for example and the Nvidia kicks in when connecting an external monitor. No Optimus is needed. Just the right Nvidia driver.

Please also post hardware info to get help

Or use the welcome app

Welcome to the forum :grin: btw

1 Like

This might be helpful also.


Thanks, I read the post. I tried dskm without the b flag and I adjusted the sddm conf with the two lines that add xrandr but sddm still cant find the display. I also read the 9560 guide from the arch wiki but it didnt prove to be helpful. As soon as nvidia drivers are installed, sddm stays black and I can only start a session with tty. I can try again, since I have a fresh install now. What is the recommended approach? dksm without any flags, adjust the sddm conf and reboot?

You read wiki or you tried the methods that the Arch wiki suggests?

Edit: Have you tried it with installing it with nvidia without bumblebee.

I tried installing the nvidia drivers directly with pacman as is described in the wiki including the early loading and pacman hook suggestion, I tried dkms without bumblebee and dkms with bumblebee. Only the last one made the system entirely unusable. The other two just caused sddm to not work any longer

When you installed EndeavourOS did you use the non free or nvidia option?

Edit: If it’s a fresh install just reinstall again with Nvidia option and see.

I selected the nvidia option and the output of inxi -Fxxxa is

  Device-1: Intel HD Graphics 630 vendor: Dell driver: i915 v: kernel
    bus-ID: 00:02.0 chip-ID: 8086:591b class-ID: 0300
  Device-2: NVIDIA GP107M [GeForce GTX 1050 Mobile] vendor: Dell
    driver: nvidia v: 495.46 alternate: nouveau,nvidia_drm bus-ID: 01:00.0
    chip-ID: 10de:1c8d class-ID: 0302

Does that mean I have the proprietary nvidia drivers installed now and does optimus work out of the box or do I need to configure something else as well?

Yes you have Nvidia current drivers installed. Post the following.

inxi -Ga

Edit: From what i read ion the Arch wiki your laptop uses the dedicated graphics all the time and the only reason for using bumblebee is to switch it off to conserve battery power when not needed.

Is the laptop working now?

Can you please clarify why you think you need Optimus or why you want to use it?

As I said above, it’s not necessary to install Optimus, and I would avoid it altogether as it messes things up with updates to my experience.

The only usecase, is if you want to specifically run the laptop screen with Nvidia and not the external monitor, and have the ability to manually switch it. But then you could also switch entirely to Nvidia card which is also recommended by big distributor s such as Lenovo for their hybrid laptops shipping with Linux…

$ inxi -Ga
  Device-1: Intel HD Graphics 630 vendor: Dell driver: i915 v: kernel
    bus-ID: 00:02.0 chip-ID: 8086:591b class-ID: 0300
  Device-2: NVIDIA GP107M [GeForce GTX 1050 Mobile] vendor: Dell
    driver: nvidia v: 495.46 alternate: nouveau,nvidia_drm bus-ID: 01:00.0
    chip-ID: 10de:1c8d class-ID: 0302
  Device-3: Microdia Integrated_Webcam_HD type: USB driver: uvcvideo
    bus-ID: 1-12:3 chip-ID: 0c45:6713 class-ID: 0e02
  Display: x11 server: X.Org compositor: kwin_x11 driver:
    loaded: intel,nvidia unloaded: modesetting alternate: fbdev,nouveau,nv,vesa
    display-ID: :0 screens: 1
  Screen-1: 0 s-res: 1920x1080 s-dpi: 96 s-size: 508x285mm (20.0x11.2")
    s-diag: 582mm (22.9")
  Monitor-1: eDP1 res: 1920x1080 dpi: 139 size: 350x190mm (13.8x7.5")
    diag: 398mm (15.7")
  OpenGL: renderer: Mesa Intel HD Graphics 630 (KBL GT2) v: 4.6 Mesa 21.3.1
    direct render: Yes

I dont think its using the dedicated all the time. Although its just an assumption, I ran some benchmarks and the performance was subpar, not what I expected from a dedicated GPU

Can you put code tags around what you posted?

It only runs nvidia if you connect an external monitor unless you use Optimus to switch on your laptop…

People are confused all the time about that, including me until last year. :innocent:

I would like to be able to use the integrated graphics only for when I use the laptop on the go as to conserve power, and the dedicated one since I am doing some graphics programming and gaming, but mostly at home when the machine is plugged in anyway

Ok, then once you have the Nvidia driver installed, which seems the case, plug in an external monitor and start the Nvidia settings utility, it should show that it is using Nvidia on the external monitor. Once that works,.then I would proceed and install Optimus. If something goes wrong, easier to troubleshoot step by step.

With Optimus you can then switch you laptop graphics card, log out and back in.

Edit: I would also use optimus-manager-qt

It looks to me like it is running on Intel but the nvidia drivers are installed correctly. I would probably try either optimus switch or optimus-manager. Optimus Manager is what i would try and if on KDE you can use optimus-manager-qt for tray icon.

1 Like

What do you mean… I’m still confused because i don’t have any Hybrid stuff only one Nvidia card also.

If you have the Nvidia driver installed (no Optimus or additional stuff) the Intel card will be activated on the laptop. Once one connects and external monitor, the Nvidia card will kick in for that monitor.

There are two options to use Nvidia on the laptop screen, that I use. One method is to use Optimus. I was just wondering if the OP is ok to use Nvidia on external monitor, then no need for installing Optimus. But if Nvidia is required on laptop, optimus-manager is easy for switching. The alternative that worked for me better to harness full poser of nvidia graphics,

bit more for advanced users

was to switch off the intel altogether in the bios (or UEFI), but then I had to add a flag in grub so it doesnt try loading the nouveau, else it’s booting into black screen.

Thanks everyone, I did not know that nvidia automatically kicks in when plugging in an external monitor. I installed the graphical optimus manager and it seems to work better now from the few benchmarks I tried.

If user isn’t using an external monitor then they want ability to switch to dedicated.