Comment 3 for bug 1485236

Revision history for this message
Laszlo Marai (atleta.hu) wrote :

I'm facing this same issue. I'm trying to move my old system (previously running on a lenovo t410 with discrete nvidia graphics) to a t450, only that has intel graphics. However, the generated xorg.conf still contains a reference to nvidia (I have Screen 0 "nvidia").

I have removed all traces of the nvidia driver from the system, but still experienced this issue. Fortunately I found this bug report. After looking at the source of gpu-manager, the problem is that it thinks that the nvidia module was unloaded. The reason is that what it does is that it looks at the syslog (instead of dmesg, as the comment for 'has_unloaded_module' states) and my syslog still contains the trace of the last boot on the old machine (the "nvidia: module" string fragment, that has_unloaded_module looks for).

Note, that dmesg (of course) does not contain anything about nvidia. The solution would be to really scan dmesg instead of syslog (fixing line 708 here: https://github.com/tseliot/ubuntu-drivers-common/blob/master/share/hybrid/gpu-manager.c ).

This bug may well have caused the problem for Rafał above. The quick fix is forcing rotation of (or removing) syslog and removing /etc/X11/xorg.conf .

The relevant files:
------ /var/log/gpu-manager.log ----
log_file: /var/log/gpu-manager.log
last_boot_file: /var/lib/ubuntu-drivers-common/last_gfx_boot
new_boot_file: /var/lib/ubuntu-drivers-common/last_gfx_boot
grep dmesg status 0
dmesg status 0 == 0? Yes
grep dmesg status 256
dmesg status 256 == 0? No
Is nvidia loaded? no
Was nvidia unloaded? yes
Is nvidia blacklisted? no
Is fglrx loaded? no
Was fglrx unloaded? no
Is fglrx blacklisted? no
Is intel loaded? yes
Is radeon loaded? no
Is radeon blacklisted? no
Is nouveau loaded? no
Is nouveau blacklisted? no
Is fglrx kernel module available? no
Is nvidia kernel module available? no
Vendor/Device Id: 8086:1616
BusID "PCI:0@0:2:0"
Is boot vga? yes
Skipping "/dev/dri/card0", driven by "i915"
Skipping "/dev/dri/card0", driven by "i915"
Found "/dev/dri/card0", driven by "i915"
output 0:
        eDP connector
Number of connected outputs for /dev/dri/card0: 1
Does it require offloading? yes
last cards number = 1
Has amd? no
Has intel? yes
Has nvidia? no
How many cards? 1
Has the system changed? No
main_arch_path x86_64-linux-gnu, other_arch_path i386-linux-gnu
Current alternative: /usr/lib/x86_64-linux-gnu/mesa/ld.so.conf
Current core alternative: (null)
Is nvidia enabled? no
Is fglrx enabled? no
Is mesa enabled? yes
Is pxpress enabled? no
Is prime enabled? no
Is nvidia available? no
Is fglrx available? no
Is fglrx-core available? no
Is mesa available? yes
Is pxpress available? no
Is prime available? no
Single card detected
PRIME detected
pci bus from dmesg status 0
can't open /sys/module/nvidia/version
can't access /usr/share/nvidia-prime/prime-quirks
Error: /usr/share/nvidia-prime/prime-quirks does not exist or is empty.
1st try: bbswitch without quirks
Loading bbswitch with "load_state=-1 unload_state=1" parameters
2nd try: bbswitch with quirks
Loading bbswitch with "load_state=-1 unload_state=1 skip_optimus_dsm=1" parameters
Warning: can't load bbswitch, switching between GPUs won't work
Selecting nvidia
Error: no alternative found for nvidia
Error: failed to enable the driver
Selecting mesa
/usr/bin/update-alternatives --set x86_64-linux-gnu_gl_conf /usr/lib/x86_64-linux-gnu/mesa/ld.so.conf
update-alternatives status 0
Calling ldconfig
ldconfig status 0
/usr/bin/update-alternatives --set i386-linux-gnu_gl_conf /usr/lib/i386-linux-gnu/mesa/ld.so.conf
update-alternatives status 0
Calling ldconfig
ldconfig status 0
Error: no alternative found for unblacklist
Removing xorg.conf. Path: /etc/X11/xorg.conf
can't access /etc/X11/xorg.conf
Check failed
Removing xorg.conf. Path: /etc/X11/xorg.conf
Moved /etc/X11/xorg.conf to /etc/X11/xorg.conf.12292015
Regenerating xorg.conf. Path: /etc/X11/xorg.conf
No need to change the current bbswitch status
----------------------------------

-------------- /etc/X11/xorg.conf -------
Section "ServerLayout"
    Identifier "layout"
    Screen 0 "nvidia"
    Inactive "intel"
EndSection

Section "Device"
    Identifier "intel"
    Driver "modesetting"
    BusID "PCI:0@0:2:0"
    Option "AccelMethod" "None"
EndSection

Section "Screen"
    Identifier "intel"
    Device "intel"
EndSection
-----------------------------

----------- /var/log/Xorg.0.log -----------
[ 4250.228]
X.Org X Server 1.17.2
Release Date: 2015-06-16
[ 4250.228] X Protocol Version 11, Revision 0
[ 4250.228] Build Operating System: Linux 3.19.0-30-generic x86_64 Ubuntu
[ 4250.228] Current Operating System: Linux Habanero 4.2.0-18-generic #22-Ubuntu SMP Fri Nov 6 18:25:50 UTC 2015 x86_64
[ 4250.228] Kernel command line: BOOT_IMAGE=/boot/vmlinuz-4.2.0-18-generic root=UUID=7eac7ecd-26df-479a-90b2-0040a19d1427 ro plymouth:debug quiet splash acpi_backlight=vendor nomdmonddf nomdmonisw resume=/dev/sda2 vt.handoff=7
[ 4250.229] Build Date: 30 September 2015 09:08:47AM
[ 4250.229] xorg-server 2:1.17.2-1ubuntu9 (For technical support please see http://www.ubuntu.com/support)
[ 4250.229] Current version of pixman: 0.32.6
[ 4250.229] Before reporting problems, check http://wiki.x.org
 to make sure that you have the latest version.
[ 4250.229] Markers: (--) probed, (**) from config file, (==) default setting,
 (++) from command line, (!!) notice, (II) informational,
 (WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[ 4250.229] (==) Log file: "/var/log/Xorg.0.log", Time: Tue Dec 29 15:32:43 2015
[ 4250.229] (==) Using config file: "/etc/X11/xorg.conf"
[ 4250.229] (==) Using system config directory "/usr/share/X11/xorg.conf.d"
[ 4250.229] Data incomplete in file /etc/X11/xorg.conf
 Undefined Screen "nvidia" referenced by ServerLayout "layout".
[ 4250.229] (EE) Problem parsing the config file
[ 4250.229] (EE) Error parsing the config file
[ 4250.229] (EE)
Fatal server error:
[ 4250.229] (EE) no screens found(EE)
[ 4250.229] (EE)
Please consult the The X.Org Foundation support
  at http://wiki.x.org
 for help.
[ 4250.229] (EE) Please also check the log file at "/var/log/Xorg.0.log" for additional information.
[ 4250.229] (EE)
[ 4250.229] (EE) Server terminated with error (1). Closing log file.
---------------------------