Posted by: reformedmusings | November 29, 2008

Upgrading/updating Kubuntu’s kernel with NVidia drivers

UPDATE Clarification:

The steps outlined below are only necessary if you installed or updated you NVidia video driver using Envy or NVidia’s direct install. If you installed your NVidia video driver using *buntu’s Restricted Driver Manager or the *buntu repositories, your video driver will automatically be updated with new kernel updates. The only reason to use Envy or NVidia’s direct installation is if you wish to use the absolute latest beta drivers from NVidia.


Even paradise has thorns on its roses. The biggest thorn in Kubuntu/Ubuntu comes when you use proprietary drivers for NVidia or ATI video cards, wireless networking cards, etc., that weren’t installed using the repositories or the Restricted Driver Manager. The fanatic “free and open” adherents don’t like to “pollute” free Linux with proprietary drivers. They prefer to live with poor video performance rather than compromise on the point. This ignores the highly competitive nature of the video card market and other realities, but I’ll skip the soap box for now.

This hits home because the video drivers (and virtualization software like VMWare Workstation) need to compile an image unique to the running kernel. When the kernel updates, the old driver image(s) will not load and so your graphical video system won’t run. K/Ubuntu isn’t smart enough to either automatically recompile the video driver image for the new kernel or to change /etc/X11/xorg.conf to use the open source video driver so that the graphics video will at least work on reboot. Instead, when you restart the system and load the newly updated kernel normally, you end up with a black screen and system lockup. I encountered this again today when updating to kernel 2.6.24-22 today. It stinks, but that’s reality.

UPDATED 11/29/2008 at 12:30 PM EST to correct the process for Gutsy and older systems.

There’s a simple way to head off the black screen. First, before restarting after updating the kernel, install Alberto Milone’s outstanding Envy Legacy or EnvyNG script, depending on what version of K/Ubuntu you’re running. In K/Ubuntu 8.04 Hardy Heron or later, you’ll find it in the Universe repository. Enable the Universe repository either in your package manager (System -> Administration -> Software Sources in Synaptic, Adept -> Manage Repositories in Adept) or manually add these lines to the /etc/apt/sources.lst file:

deb hardy universe
deb-src hardy universe
deb hardy-updates universe
deb-src hardy-updates universe

NOTE: If you are running a K/Ubuntu version older than 8.04 Hardy, you’ll have to download Envy Legacy from Alberto’s website. Once downloaded, simply install the .deb package. You can then skip down to restarting your system below.

Once the Universe repository has been added to Hardy, refresh the package list either from the package manager or from the terminal:

sudo apt-get update

Once you update the package list, install envyng-core, and either envyng-qt if running KDE or envyng-gtk if running Gnome in Hardy, either from the package manager or terminal:

sudo apt-get install envyng-core envyng-qt

Once EnvyNG or Envy Legacy is installed, you are ready to restart your system. Upon restart, chose the “recovery mode” menu item for the new kernel in GRUB. This will boot you into a text interface as root. When you receive a terminal prompt, type:

envyng -t (or envy -t for older distributions)

This will start the script in text mode. Choose to either install the NVidia or ATI driver as appropriate. Envy will take care of the housekeeping, download the latest stable drivers, compile and install them. After Envy completes, type:


The system will restart. You can now choose the default startup with the new kernel and the video should work as before.

Remember that you’ll have to use EnvyNG or Envy Legacy in recovery mode for each new kernel to which you update, at least until the K/Ubuntu team decides to implement a graceful automatic solution.


  1. […] and instructionals (and this is not directed at you Bob but generally); but when I read stuff like this, in addition to my eyes glazing over, I am reminded of those types that insisted on hanging on to […]

  2. […] For more information, refer to the blog post at Reformed Musings. […]

Leave a Reply

Please log in using one of these methods to post your comment: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s


%d bloggers like this: