≡ Menu

Debian Linux 6: Install Nvidia Proprietary Unix Driver

The NVIDIA Linux proprietary unified drivers supports various features such as 3d rendering, opengl and much more. This post covers installing and configuring NVIDIA’s proprietary graphic card driver in Debian Linux version 6.x amd64.

Why use proprietary Unix driver?

You will get full 3D acceleration support. This allows you to use the following applications with 3D and OpenGL under Linux:

  1. Games such as PlanetPenguin Racer, Extreme Tux Racer, Neverball, and many more.
  2. Linux video editing application such as cinelerra and others.
  3. Use 3d desktop effect provided by compiz – a compositing window manager for the X Window System. It use 3D graphics hardware to create fast compositing desktop effects for window management.

Let us see, how to install NVIDIA Drivers in Debian Linux.

Step # 1: Install compilers and required tools on Debian for Nvidia

First, install build-essential and kernel headers package:
# apt-get install build-essential linux-headers-$(uname -r)

Step # 2: Disable nouveau driver on Debian

Open source drivers for NVIDIA hardware are included in the standard Linux distributions. You need to disable nouveau driver. Create a file as follows disable-nouveau.conf:
# vi /etc/modprobe.d/disable-nouveau.conf
Append the following code:

# Disable nouveau
blacklist nouveau
options nouveau modeset=0

Save and close the file.

Step # 3: Download nvidia driver for Debian Linux

Visit this page to grab the latest version of nvidia driver (save it in your $HOME:
$ wget -O NVIDIA-Linux-x86_64-295.59.run http://in.download.nvidia.com/XFree86/Linux-x86_64/295.59/NVIDIA-Linux-x86_64-295.59.run
Sample outputs:

--2012-07-17 18:49:52--  http://in.download.nvidia.com/XFree86/Linux-x86_64/295.59/NVIDIA-Linux-x86_64-295.59.run
Resolving in.download.nvidia.com...,
Connecting to in.download.nvidia.com||:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 58529480 (56M) [application/octet-stream]
Saving to: `/home/vivek/NVIDIA-Linux-x86_64-295.59.run'
 0% [                                                                                     ] 5,03,684     459K/s

Step # 4: Reboot the system

You need to reboot the system and login using a single user mode or select Recovery mode at grub prompt:
# reboot
Once logged into the single user mode, remove the following package (if installed):
# apt-get --purge remove xserver-xorg-video-nouveau nvidia-kernel-common nvidia-kernel-dkms nvidia-glx nvidia-smi
Search for all installed nvidia packages and delete them (do not skip this step):
# dpkg --list | grep -i --color nvidia

Step # 4: Install the NVIDIA Drivers on Debian Linux

Make sure you are not using Xorg and/or any other graphical environment such as Gnome or KDE. If you are running Gnome stop it as follows:
# /etc/init.d/gdm3 stop
Also backup your existing /etc/X11/xorg.conf file, using the cp command:
# cp -v /etc/X11/xorg.{conf,factory}
Type the following command to install the Unix driver:
# sh /home/vivek/NVIDIA-Linux-x86_64-295.59.run
Just follow on screen instructions. Make sure you upgrade xorg.conf when promoted. Finally, reboot the system:
# reboot

How do I configure Xorg with NVIDIA driver?

Login into Gnome or KDE destktop and type the following command:
$ nvidia-settings
OR visit Gnome menus as follows:
System > Preferences > NVIDIA X Server Settings
Sample outputs:

A note about the Debian package based driver installation

NVIDIA drivers can be installed using NVIDIA’s official installer or the Debian driver packages. This post covered NVIDIA’s official installer. However, you can the Debian driver packages method as described here.

My modified xorg.conf

Following is my /etc/X11/xorg.conf:

Section "ServerLayout"
    Identifier     "Layout0"
    Screen      0  "Screen0" 0 0
    InputDevice    "Keyboard0" "CoreKeyboard"
    InputDevice    "Mouse0" "CorePointer"
    Option         "Xinerama" "0"
Section "Files"
Section "InputDevice"
    # generated from default
    Identifier     "Mouse0"
    Driver         "mouse"
    Option         "Protocol" "auto"
    Option         "Device" "/dev/psaux"
    Option         "Emulate3Buttons" "no"
    Option         "ZAxisMapping" "4 5"
Section "InputDevice"
    # generated from default
    Identifier     "Keyboard0"
    Driver         "kbd"
Section "Monitor"
    # HorizSync source: edid, VertRefresh source: edid
    Identifier     "Monitor0"
    VendorName     "Unknown"
    ModelName      "Seiko/Epson"
    HorizSync       49.8 - 74.7
    VertRefresh     40.0 - 60.0
    Option         "DPMS"
Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "Quadro FX 3800M"
    # Power settings by VG - start
    # Laptop Battery life setting by VG
    Option     "RegistryDwords" "PowerMizerLevel=0x3"
    # When on AC settings by VG
    Option "RegistryDwords" "PowerMizerLevelAC=0x3"
    # Power settings by VG - end
    #Compiz settings by VG - start
    Option "XAANoOffscreenPixmaps" "true"
    Option "AllowGLXWithComposite" "true"
    #Compiz settings by VG - end
Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    Option         "TwinView" "1"
    Option         "TwinViewXineramaInfoOrder" "CRT-0"
    Option         "metamodes" "DFP: nvidia-auto-select +0+0, CRT: nvidia-auto-select +1920+0"
    #Compiz settings by VG - start - we need to set this to 24bit
    SubSection     "Display"
        Depth       24
    #Compiz settings by VG - end
    #Compiz settings by VG - start
    Option "AddARGBGLXVisuals" "true"
    #Compiz settings by VG - end
# Dedicated "Extensions" section
Section "Extensions"
        #Compiz settings by VG - start
        Option "Composite" "enable"
        #Compiz settings by VG - end

This entry is 1 of 4 in the Debian Linux Cool Desktop Effects series. Keep reading the rest of the series:
  1. Install Nvidia Proprietary Unix Driver For 3D Effects
  2. Install and Configure Compiz Eye Candy Effects
  3. Install Emerald Windows Decorator And Theme Manager
  4. Install AWN - A MacOS X Like Panel For Gnome

Comments on this entry are closed.

  • Marco

    Is it possible to install nVidia binary driver in a VirtualBox virtual Debian? I.e. no nVidia card really available.
    I need this because I create a debian live from VM image and run it on nVidia-enabled PCs…

  • Noop.

  • Your last word in the link redirects back to the current page.

    A note about the Debian package based driver installation


    drivers can be installed using NVIDIA’s official installer or the

    Debian driver packages. This post covered NVIDIA’s official installer.

    However, you can the Debian driver packages method as described here.

  • Can you post an article about how to install the proprietary nvidia driver from the debian repos?

  • Alex

    Thanks a lot. Amazing tutorial, very well written

  • Thanks very much! Worked perfectly for me.

  • BigDaddyEllison

    I had given up on getting my Nvidia card to work with any Ubuntu based dist. Thank you for this tutorial, it helped me figure out the issue and now I finally use my NVidia card in my T530. I was resigned to using the 2D version of UIs or using theintegrated card. My sticking point was that I needed to remove all “nouvea” based packages as well. Killed KDE, but I use Cinnamon anyway. Thanks again for your great tutorials.

  • CO

    Many thanks, finally installed the official nvidia drivers.
    I don’t understand why distros force the “open” drivers and packages ie nouveau, openjdk etc.
    There was a time where distro makers begged the software/hardware makers for drivers and packages and now that they got them and linux has become much better they stab them in the back by blacklisting them and crying “ooooh but its not opensource”
    At least give the user a choice to choose what he want. That’s what really open is. Not by forcing them stuff in their throats.

  • Rombus

    Worked like a charm, thanks B-)

  • Armenio Pereira

    Thanks a lot for this precious article. I’ve been installing a few Debian versions with no success due to kdm logon failures, what pushed me to another distro… and now that I followed the tips in this page, BINGO… it’s up and running. Excellent tips!