Ubuntu – How to change proprietary video driver using the command line

driversgraphicsnvidiavideo

My laptop computer has a Nvidia video card and runs Ubuntu 12.04 LTS 64-bit. During an upgrade yesterday it seemed as a new Nvidia driver version 304 (if I remember correct) was installed. After upgrade and reboot, I opened the Additional Driver tool and found that the Nvidia driver version 304 was in use. So far so good.

However, the Additional Driver tool also reported that there existed a Nvidia driver version 319 and that this driver version was recommended. I then selected to change to this recommended driver, the driver was downloaded and installed, I rebooted the system and ended up with a black screen and a command shell.

How to change proprietary Nvidia video driver using the command line and revert back to the previous version that worked on my system?

(A second question: How can it be that a video driver that apparently does not work was recommended?)

Best Answer

Ubuntu 12.04 (for later versions, see other answers)

You can use jockey-text to disable and enable Nvidia drivers in Ubuntu.

For example:

  • Run jockey-text --list to get the list of available options.

  • Run sudo jockey-text -d xorg:nvidia_304 to remove the 304 driver.

  • Run sudo jockey-text -e xorg:nvidia_304 to enable the same driver.

  • Run jockey-text --help to see the help manual.