Nvidia proprietary drivers fallback test failed: do not hardcode "Driver=nvidia" in xorg.conf

Bug #522061 reported by Federico Vera
108
This bug affects 22 people
Affects Status Importance Assigned to Milestone
Jockey
Fix Released
High
Martin Pitt
jockey (Ubuntu)
Fix Released
High
Martin Pitt
Lucid
Won't Fix
High
Alberto Milone
Natty
Fix Released
High
Martin Pitt

Bug Description

Binary package hint: xorg

Install the latest Lucid build
Install proprietary drivers
Restart the computer.
Rename '/lib/modules/2.6.32-13-generic/updates/dkms/nvidia-current.ko' to '/lib/modules/2.6.32-13-generic/updates/dkms/nvidia-bkup'
Restart the computer.

What should happen: When the driver isn't found the system should start with the open source driver.
What happens: all black unless session is started in low graphics mode.

This steps were specified by the X proprietary drivers testing team: http://testcases.qa.ubuntu.com/Hardware/X/ProprietaryDrivers#Fallback%20Testing

ProblemType: Bug
Architecture: i386
CurrentDmesg:
 [ 16.155464] ppdev: user-space parallel port driver
 [ 25.828007] eth0: no IPv6 routers present
Date: Mon Feb 15 06:26:40 2010
DistroRelease: Ubuntu 10.04
DkmsStatus: nvidia-current, 190.53, 2.6.32-13-generic, i686: installed (WARNING! Diff between built and installed module!)
InstallationMedia: Ubuntu 10.04 "Lucid Lynx" - Alpha i386 (20100212)
MachineType: MICRO-STAR INTERNATIONAL CO., LTD MS-7142
Package: xorg 1:7.5+1ubuntu2
ProcCmdLine: BOOT_IMAGE=/boot/vmlinuz-2.6.32-13-generic root=UUID=808da161-3e25-49b5-9195-0ad41a7e8552 ro quiet splash
ProcEnviron:
 LANG=en_US.utf8
 SHELL=/bin/bash
ProcVersionSignature: Ubuntu 2.6.32-13.18-generic
RelatedPackageVersions:
 xserver-xorg 1:7.5+1ubuntu2
 libgl1-mesa-glx 7.7-0ubuntu8
 libdrm2 2.4.17-0ubuntu2
 xserver-xorg-video-intel 2:2.9.1-1ubuntu4
SourcePackage: xorg
Uname: Linux 2.6.32-13-generic i686
dmi.bios.date: 06/27/2006
dmi.bios.vendor: Phoenix Technologies, LTD
dmi.bios.version: 6.00 PG
dmi.board.name: MS-7142
dmi.board.vendor: MICRO-STAR INTERNATIONAL CO., LTD
dmi.board.version: 1.00
dmi.chassis.type: 3
dmi.modalias: dmi:bvnPhoenixTechnologies,LTD:bvr6.00PG:bd06/27/2006:svnMICRO-STARINTERNATIONALCO.,LTD:pnMS-7142:pvr1.00:rvnMICRO-STARINTERNATIONALCO.,LTD:rnMS-7142:rvr1.00:cvn:ct3:cvr:
dmi.product.name: MS-7142
dmi.product.version: 1.00
dmi.sys.vendor: MICRO-STAR INTERNATIONAL CO., LTD
system:
 distro: Ubuntu
 architecture: i686kernel: 2.6.32-13-generic

Revision history for this message
Federico Vera (fedevera) wrote :
Bryce Harrington (bryce)
affects: xorg (Ubuntu) → nvidia-graphics-drivers-180 (Ubuntu)
Revision history for this message
Federico Vera (fedevera) wrote :

Sorry, but according to the logs the driver is the 190

Revision history for this message
Charlie Kravetz (cjkgeek) wrote :

I can confirm this bug in Lucid. After attempting to reconfigure the graphics mode, a restart is required. Using Ctrl+Alt+Del results in the same screen message. Using 'switch to console' and using "shutdown -r now" also results in the same message. After attempting this about 4 times, I allowed it to login to the desktop in low graphics mode. The hardware drivers can not be renamed or reinstalled at this point, and the system is running in low graphics.

Changed in nvidia-graphics-drivers-180 (Ubuntu):
status: New → Confirmed
importance: Undecided → High
Changed in nvidia-graphics-drivers-180 (Ubuntu):
assignee: nobody → Canonical Desktop Team (canonical-desktop-team)
Martin Pitt (pitti)
Changed in nvidia-graphics-drivers-180 (Ubuntu):
assignee: Canonical Desktop Team (canonical-desktop-team) → Alberto Milone (albertomilone)
affects: nvidia-graphics-drivers-180 (Ubuntu) → nvidia-graphics-drivers (Ubuntu)
Revision history for this message
Timo Aaltonen (tjaalton) wrote :

the fallback code in the xserver doesn't work if there is an xorg.conf around

Bryce Harrington (bryce)
Changed in nvidia-graphics-drivers (Ubuntu Lucid):
status: Confirmed → Triaged
Revision history for this message
Charlie Kravetz (cjkgeek) wrote :

Also, the renamed .ko file is now removed from the hard drive during the reboot.

tags: added: iso-testing
Revision history for this message
Rick Spencer (rick-rickspencer3) wrote :

I don't think this will get addressed as the driver is proprietary and this kind of behavior may depend on hardware configuration. We need to focus on addressable bugs in the end game.

Changed in nvidia-graphics-drivers (Ubuntu Lucid):
status: Triaged → Won't Fix
Revision history for this message
Ofir Klinger (klinger-ofir) wrote :

I also followed the steps from:
http://testcases.qa.ubuntu.com/Hardware/X/ProprietaryDrivers#Fallback%20Testing
and the test failed also for me.

Revision history for this message
Chad A Davis (chadadavis) wrote :

Also affects Natty development branch on MacBook Pro. Hangs on splash screen, without any fallback to the nv or nouveau or any other video driver. Works fine again when the driver file is put back where it belongs.

Revision history for this message
Chad A Davis (chadadavis) wrote :

If the /etc/X11/xorg.conf is removed, then it does correctly load the default (nouveau) driver, but if the xorg.conf wants to load the nvidia driver and that fails, then it doesn't fallback to nouveau like it should.

Revision history for this message
Ofir Klinger (klinger-ofir) wrote :

Just followed the test again and this time I also tried booting using recovery mode.

Ubuntu booted up just fine. When an option to continue with failsafe X was offered I took it and then chose to run Ubuntu in low graphic mode.
Then I run gksudo jockey-gtk and jockey said that the nvidia driver is running properly and is activated, while it should say that something is wrong and ask whether to reinstall the driver.

Changed in nvidia-graphics-drivers (Ubuntu Natty):
assignee: Alberto Milone (albertomilone) → Canonical Desktop Team (canonical-desktop-team)
Revision history for this message
Richard (richpaulfahey) wrote :

No gui after fallback for me too. Have attached messages

Revision history for this message
Richard (richpaulfahey) wrote :

Here is dmesg output also

Revision history for this message
Patrick Geltinger (patlkli) wrote :

Same here under Natty, dmesg and Xorg.0.log are the same as Richard's above in the relevant parts.

Revision history for this message
Martin Pitt (pitti) wrote :

Alberto, Bryce, Chris, do we even need to explicitly set the nvidia driver in xorg.conf these days? I thought X.org would prefer nvidia over nv/nouveau now, so perhaps the easiest thing here would be to fix the jockey handler to not set the driver at all?

Revision history for this message
Ric Flomag (ricflomag) wrote :

@Martin: Indeed, xorg.conf is not necessary, i've just removed it and Xorg started using the nvidia driver. The only difference i've noticed is that the nvidia logo shows up for an instant when X starts, because the option "NoLogo" defaults to false.

Revision history for this message
Chad A Davis (chadadavis) wrote :

I tested Matin's suggestion. The fallback works properly if /etc/X11/xorg.conf is simply not present.

I moved the nvidia-current.ko aside, restarted. The X.org.0 shows that the order of preference for the autoconfigured drivers is: 0: nvidia 1: nouveau 2: nv 3: vesa 4: fbdev. In this case, nouveau is chosen. Metacity starts.

Jockey ('Additional Drivers') shows that Nvidia is "activated and currently in use", even though lsmod, Xorg.0.log and glxinfo concur that it is not in use.

I restored the nvidia driver file. I was tried to switch drivers by logging out and in, but nouveau was still used. Then I restarted gdm, but nouveau was still used. I didn't try rmmod and modprobe. After rebooting, however, nvidia was used again as the preferred default.

The only (minor) disadvantage is that the nVidia splash screen displays (for <1 second) when it loads, because the 'Option "NoLogo" "True"' is no longer being read from the non-existant xorg.conf

This is with
Natty Daily 2011-03-18
Linux 2.6.38.7.21
nvidia-current 270.30-0ubuntu3
xorg 1:7.6~3ubuntu11

amd64/mac
GeForce GT 330M

Revision history for this message
Martin Pitt (pitti) wrote : Re: [Bug 522061] Re: Nvidia proprietary drivers fallback test failed

Chad A. Davis [2011-03-24 21:49 -0000]:
> I tested Matin's suggestion. The fallback works properly if
> /etc/X11/xorg.conf is simply not present.

Thanks. That's actually kind of surprising, as in the past we at least
needed to set DisplayDepth to 24, and some other bits.

> The only (minor) disadvantage is that the nVidia splash screen displays
> (for <1 second) when it loads, because the 'Option "NoLogo" "True"' is
> no longer being read from the non-existant xorg.conf

Right. Perhaps you could do the same test again, but this time don't
remove xorg.conf entirely, but just drop the Driver option and leave
the other bits in place?

Revision history for this message
Chad A Davis (chadadavis) wrote : Re: Nvidia proprietary drivers fallback test failed

Leaving the xorg.conf in place, commenting out the 'Driver' line, also allows driver fallback (nvidia to nouveau) to work correctly.

And the color depth is 24 (verified in Xorg.0.log), in both cases: whether nvidia is used, or if it falls back to nouveau.

Revision history for this message
Alberto Milone (albertomilone) wrote :

@Martin
Removing xorg.conf in Natty won't prevent the xserver from loading nvidia and will also set DisplayDepth to 24, thanks to a patch that we included in the xserver.

What we still need in xorg.conf is the Nologo option, otherwise users will see the Nvidia logo every time the xserver starts.

Revision history for this message
Martin Pitt (pitti) wrote :

Great, then I'll change Jockey to not hardcode the driver and displaydepth any more.

Thanks!

affects: nvidia-graphics-drivers (Ubuntu Natty) → jockey (Ubuntu Natty)
Changed in jockey (Ubuntu Natty):
assignee: Canonical Desktop Team (canonical-desktop-team) → Martin Pitt (pitti)
status: Triaged → In Progress
Revision history for this message
Martin Pitt (pitti) wrote :

This needs some changes in the general XorgDriverHandler class as well. I did that in trunk now and added appropriate test cases.

Changed in jockey:
assignee: nobody → Martin Pitt (pitti)
importance: Undecided → High
status: New → Fix Committed
summary: - Nvidia proprietary drivers fallback test failed
+ Nvidia proprietary drivers fallback test failed: do not hardcode
+ "Driver=nvidia" in xorg.conf
Revision history for this message
Martin Pitt (pitti) wrote :

I fixed that in jockey's packaging bzr now, and also uploaded to my PPA: https://launchpad.net/~pitti/+archive/ppa

Unfortunately I cannot really test this in a real-life scenario, as I only have machines with intel. I only did some "dry run" tests.

Can someone with Nvidia hardware please give them a spin? I'm interested in the following scenarios:

 * No xorg.conf (-> nouveau), enable nvidia in jockey (-> proprietary), disable nvidia.ko (-> nouveau, this bug report), re-renable nvidia.ko (-> nvidia) -> disable nvidia in jockey (-> back to no xorg.conf, nouveau)

 * Existing xorg.conf without Driver, enable nvidia in jockey (-> proprietary), disable nvidia.ko (-> nouveau, this bug report), re-renable nvidia.ko (-> nvidia) -> disable nvidia in jockey (-> back to original xorg.conf).

Thank you in advance!

Changed in jockey (Ubuntu Natty):
status: In Progress → Fix Committed
Revision history for this message
Chad A Davis (chadadavis) wrote :

I'm trying this out with jockey-gtk-0.9.2-0ubuntu3pitti1 on Natty dev (2011-03-29) with nvidia-current-270.30-0ubuntu3

 * No xorg.conf (-> nouveau)
=> passed (default setup, a noop)

* enable nvidia in jockey (-> proprietary)
=> passed, but thinks it fails
jockey.log shows: (also attached the tail of the log)
nvidia_current the driver is not installed in all of the relevant device sections
After reboot, jockey shows: 'A different version of this driver is in use'

* disable nvidia.ko (-> nouveau, this bug report),
=> passed, Xorg.0.log simply warns: Nouveau(0): Option "NoLogo" is not used

re-renable nvidia.ko (-> nvidia)
=> passed

disable nvidia in jockey (-> back to no xorg.conf, nouveau),
=> failed
Since Jockey doesn't acknowledge that nvidia is running, I cannot 'Remove' it.
I try to 'Activate' it again, even though it's already running, jockey.log shows same error from install:
nvidia_current the driver is not installed in all of the relevant device sections
I close jockey. I manually add 'Driver "nvidia"' to xorg.conf to see if this is recognized.
Jockey still show 'A different version of this driver is in use". Try to 'Activate' again.
Same jockey.log error:
nvidia_current the driver is not installed in all of the relevant device sections

I haven't yet tested the scenario involving an existing xorg.conf, as I'm not yet able to uninstall nvidia via jockey.

And while I'm here a small question: if no xorg.conf existed, then it was subsequently customized, then nvidia is uninstalled, what happens to those customizations? Is the xorg.conf completely removed, because there was none at the time of install, or should the Driver simply be removed? I can't test this yet, but wanted to keep it in mind for the next round.

Revision history for this message
Alberto Milone (albertomilone) wrote :

the attached patch should solve your problem. Since we no longer set the driver in xorg.conf we don't need to check whether the driver is set in xorg.conf anymore to see if the driver is enabled.

Revision history for this message
Martin Pitt (pitti) wrote :

Chad, thanks a lot for testing.

Alberto committed the fix to the packaging branch, thanks! I updated the package in my PPA. I'd appreciate if someone on nvidia could test version 0.9.2-0ubuntu3pitti2.

> if no xorg.conf existed, then it was subsequently customized, then nvidia is uninstalled, what happens to those customizations? Is
> the xorg.conf completely removed, because there was none at the time of install, or should the Driver simply be removed

I'm afraid right now it would just remove xorg.conf again, as it restores the situation that you had before enabling the driver. It doesn't change the "Driver" option any more now.

Revision history for this message
Chad A Davis (chadadavis) wrote :

Updated to Martin's jockey-gtk-0.9.2-ubuntu3pitt2 (Alberto's patch).
All tests pass!
Jockey now recognizes the nvidia driver after it's been installed.
Fallback from nvidia to nouveau still works.
The xorg.conf will be restored to the state it had when nvidia was installed:
* If there was no xorg.conf, it will be removed (even if customized)
* If there was a custom xorg.conf, it is modified for nvidia and the original file is restored after uninstalling nvidia
* Even if the original had a "Driver" entry,
** it's commented out for nvidia;
** after uninstall, the original Driver entry is restored.

The only issue: after uninstalling nvidia (generally), jockey does not show the reboot icon (the one that it shows after installing nvidia). Though, the system logout menu does show 'Restart to complete udpate'. I'll file this is a separate bug, if it doesn't exist.

Revision history for this message
Martin Pitt (pitti) wrote :

Great, thanks for testing!

tags: added: patch
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package jockey - 0.9.2-0ubuntu4

---------------
jockey (0.9.2-0ubuntu4) natty; urgency=low

  [ Martin Pitt ]
  * data/handlers/nvidia.py: Some cleanup:
    - Drop obsolete add_modules=['glx'].
    - Drop setting DefaultDepth=24, X.org does that by default now.
    - Move version 96 specific code to NvidiaDriver96 class.
    - Remove some dead code.
  * Merge from trunk:
    - XorgDriverHandler: Support None X.org driver to avoid changing the
      Driver setting. This is appropriate for drivers which X.org conf
      autodetects.
    - Add new flag Handler.needs_kernel_headers and install kernel headers if
      set.
  * data/handlers/{nvidia,fglrx}.py: Stop setting the X.org driver and
    alternate free driver. Natty's X.org now prefers the proprietary drivers
    over the free ones when available (105_nvidia_fglrx_autodetect.patch).
    This allows X.org to fall back to the free driver if the proprietary one
    gets broken or out of sync. (LP: #522061)
  * jockey/oslib.py: Set kernel header metapackage name from currently running
    kernel flavour, and add a small test case that it is a valid package.
  * data/handlers/{nvidia,fglrx}.py: Replace custom code to install kernel
    headers with setting the needs_kernel_headers flag.
  * data/handlers/broadcom_wl.py: Set needs_kernel_headers flag. (LP: #567699)
  * jockey/oslib.py, install_packages(): python-apt recently changed
    "architecture" field of a candidate Version; where it used to say "all"
    it now has the platform name. So switch to
    candidate.record['Architecture'] to check if a package is Arch: all. This
    unbreaks installation of unsigned third-party PPD packages.

  [ Alberto Milone ]
  * data/handlers/fglrx.py:
    - Re-enable fglrx.
    - Replace tabs with whitespaces.
  * data/handlers/nvidia.py:
    - Replace tabs with whitespaces.
 -- Martin Pitt <email address hidden> Thu, 31 Mar 2011 17:29:28 +0200

Changed in jockey (Ubuntu Natty):
status: Fix Committed → Fix Released
Martin Pitt (pitti)
Changed in jockey:
status: Fix Committed → Fix Released
Revision history for this message
Richard (richpaulfahey) wrote :

Fallback test for Xorg Proprietary Drivers Testers. System did not start in GUI. Had to go to terminal (ctrl-alt-F1) and move the module back. After that everything back to normal. Same result as last week. Have a geforce 8600GT

Revision history for this message
Martin Pitt (pitti) wrote : Re: [Bug 522061] Re: Nvidia proprietary drivers fallback test failed: do not hardcode "Driver=nvidia" in xorg.conf

Richard [2011-04-02 4:36 -0000]:
> Fallback test for Xorg Proprietary Drivers Testers. System did not start
> in GUI. Had to go to terminal (ctrl-alt-F1) and move the module back.
> After that everything back to normal. Same result as last week. Have a
> geforce 8600GT

Did you install the proprietary driver after installing beta-1 and
upgrading to the latest jockey? If you already installed it earlier,
the new jockey won't help you, as it won't automatically update your
xorg.conf.

Martin
--
Martin Pitt | http://www.piware.de
Ubuntu Developer (www.ubuntu.com) | Debian Developer (www.debian.org)

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.