Quadro 1000M Optimus Linux: in Optimus mode, LVDS is disconnected

On my W520 running ubuntu 16.04 and 367.57 from Ubuntu, both my display port monitor and laptop panel work fine if BIOS startup is configured for nvidia.

But in Optimus mode, Nvidia profile, the laptop panel is not connected.

tim@w520:~$ xrandr
Screen 0: minimum 8 x 8, current 1920 x 1200, maximum 16384 x 16384
LVDS-0 disconnected (normal left inverted right x axis y axis)
DP-0 connected primary 1920x1200+0+0 (normal left inverted right x axis y axis) 518mm x 324mm
   1920x1200     59.95*+
   1920x1080     60.00  
   1680x1050     59.95  
   1600x1200     60.00  
   1440x900      59.89  
   1280x1024     60.02  
   1280x960      60.00  
   1280x720      60.00  
   1024x768      60.00  
   800x600       60.32  
   640x480       59.94  
DP-1 disconnected (normal left inverted right x axis y axis)
DP-2 disconnected (normal left inverted right x axis y axis)
DP-3 disconnected (normal left inverted right x axis y axis)
DP-4 disconnected (normal left inverted right x axis y axis)
DP-5 disconnected (normal left inverted right x axis y axis)

In discrete mode, something at startup remove xorg.conf
When booted in optimus, something at startup creates the following xorg.conf:

1 Section "ServerLayout"
  2     Identifier "layout"
  3     Screen 0 "nvidia"
  4     Inactive "intel"
  5 EndSection
  7 Section "Device"
  8     Identifier "intel"
  9     Driver "modesetting"
 10     BusID "PCI:0@0:2:0"
 11     Option "AccelMethod" "None"
 12 EndSection
 14 Section "Screen"
 15     Identifier "intel"
 16     Device "intel"
 17 EndSection
 19 Section "Device"
 20     Identifier "nvidia"                                                     
 21     Driver "nvidia"
 22     BusID "PCI:1@0:0:0"
 23     Option "ConstrainCursor" "off"
 24 EndSection
 26 Section "Screen"
 27     Identifier "nvidia"
 28     Device "nvidia"
 29     Option "AllowEmptyInitialConfiguration" "on"
 30     Option "IgnoreDisplayDevices" "CRT"
 31 EndSection

When in Optimus mode, the grub menu at boot is different. The fonts are smaller.
During startup, the laptop panel briefly flashes just before the login screen is presented, but the login screen is actually on the external monitor. During the session, the laptop panel just shows a message from near the near the end of the start up process
e.g. a message the /dev/sda6 is clean…
If I ctlr-alt-F1 to access a virtual console, it takes me to the laptop screen, and the external monitor image disappears (but comes back when resuming the X session).

When restarting or shutting down, the ubuntu shutdown ‘splash’ screen appears on the laptop panel, in high resolution. So it seems the intel driver is active on the panel, and for some reason the discrete driver cannot “offload” to it. I guess this means something is wrong with the script-written xorg.conf ?

I have the same symptopms on W530 (Quadro K1100M) - discrete mode works, optimus does not. Optimus with nouveau drivers can use the internal screen, but cannot drie my three external monitors.

Ubuntu 18.04 version of drivers 390.77
nvidia-bug-report.log.gz (115 KB)

Please run nvidia-bug-report.sh as root and attach the resulting .gz file to your post. Hovering the mouse over an existing post of yours will reveal a paperclip icon.

Change your display manager to lightdm

It already is.

I uploded it. I think the generated xorg.conf is wrong as it does not provide for my built-in display, but then the tool nor xrandr sees it when running in Optimus, so I guess that is just a symptom and not a cause.

Please delete /etc/X11/xorg.conf

Hm, I updated to driver version 430 and now Optimus seems to be working (but I also deleted the xorg.conf file).

Hm, actually not, it still acts weird. I was able to have all four displays on when I set them to mirroring, but when I uncheck that setting, the internal laptop display just seems to be invisible to nvidia-settings app:-/. (it is visible to Ubuntu’s “Displays” app but the display still does not show anything.)