May 1, 2010 · General · Email This Post

Sponsored Link
If you are trying to install nVidia drivers from their website you might receive the following error

ERROR: Unable to load the kernel module ‘nvidia.ko'.  This happens most frequently when this kernel module was built against the wrong or improperly configured kernel sources, with a version of gcc that differs from the one used to build the target kernel, or if a driver such as rivafb/nvidiafb is present and prevents the NVIDIA kernel module from obtaining ownership of the NVIDIA graphics device(s), or NVIDIA GPU installed in this system is not supported by this NVIDIA Linux graphics driver release.

To fix the above error message use the following procedure

1) Download Newest Nvidia drivers from here

2) Open module blacklist as admin

gksudo gedit /etc/modprobe.d/blacklist.conf

Add these lines and save:

blacklist vga16fb
blacklist nouveau
blacklist rivafb
blacklist nvidiafb
blacklist rivatv

3) Uninstall any previously installed Nvidia drivers:

sudo apt-get --purge remove nvidia-*

4) Reboot your computer

5) When an error message pops up saying that Ubuntu cannot load Nvidia drivers, choose Exit to terminal (Exit to console)

6) Login and cd to the directory where you saved your file

7)Install drivers

sudo sh NVIDIA-Linux-x86_64-195.36.24-pkg2.run

8)Start GDM

sudo service gdm start

Full Credit goes here

Sponsored Link

Incoming search terms:

Related posts

119 Comments to “Howto install nVIDIA drivers manually on Ubuntu 10.04 (Lucid Lynx)”

  1. kaddy says:

    Jim… can you try and run compiz or a 3d game if you got one? sometimes the hardware drivers tool says its not in use when infact it actually is… just wanna make sure… try enabling your desktop effects and see if they work or return an error..

    [Reply]

  2. fook says:

    hey I tried this but as soon as I get to step 3 I get the following error

    E: Couldn’t find package nvidia-*

    how can I get past this?

    [Reply]

  3. fook says:

    I’m running kubuntu 10.04

    [Reply]

  4. Kouros says:

    Hello there ,i appreciate your effort ,learnt alot from your Website.
    could you please guide me installing ” ati-driver-installer-10-4-x86.x86_64″ for my X1550 GCard?

    thanks in advance

    [Reply]

  5. kaddy says:

    hi fook and Kouros…. you’de probably be best going into the forums and posting your problem there…. it’s a bit hard for me to help 3 guys at once and problem solve issues for 3 seperate people at the same time… but Fook… obviously you have already removed nvidia packages.. now you have to install nvidia… the guy on this website recommends installing from nvidia website… you can, but it will cause problems down the road… use the driver from the package manager… Kouros.. I have no experience with ati driver installation.. but heres a link that will help you. http://ubuntuforums.org/showpost.php?p=9062521&postcount=158

    [Reply]

  6. Fish says:

    This PPA solved everything yesterday afternoon
    https://edge.launchpad.net/~ubuntu-x-swat/+archive/x-updates :-)

    [Reply]

  7. anamtamrin says:

    I don’t understand step no. 6 and I can’t follow step no. 7.
    it said “sh: Can’t open NVIDIA-Linux-x86_64-195.36.24-pkg2.run”
    any idea?
    sorry a newbie.

    [Reply]

  8. Jim C. says:

    EUREKA!

    Note that this information was stuff I had to do AFTER using kaddy’s method for getting the right drivers set up.

    Reached a point where I was seeing gray squares and then not much else. This was basically another known problem.

    In essence, on the Sony Vio VPCF115FM with the Geforce 330M, a.k.a. GT330M , X can’t load the EDID file unless it is loaded explicitly in the xorg.conf.

    These two sites were very helpful. Don’t use the file extracted from Windows in the first link, though. It didn’t work for me. I just used that first link to help me figure out the proper form of the xorg.conf file. The second link tells you where the edid file lives on Linux.

    http://ubuntuforums.org/showthread.php?t=1396811

    http://www.nvnews.net/vbulletin/showthread.php?t=149043

    I’ll post the actual xorg.config that worked for me in a moment.

    [Reply]

  9. Jim C. says:

    Here’s that xorg.conf I used. :-)

    # nvidia-xconfig: X configuration file generated by nvidia-xconfig
    # nvidia-xconfig: version 1.0 (buildmeister@builder58) Fri Mar 12 02:12:40 PST 2010

    Section “ServerLayout”
    Identifier “Layout0″
    Screen 0 “Screen0″
    InputDevice “Keyboard0″ “CoreKeyboard”
    InputDevice “Mouse0″ “CorePointer”
    EndSection

    Section “Files”
    EndSection

    Section “InputDevice”
    # generated from default
    Identifier “Mouse0″
    Driver “mouse”
    Option “Protocol” “auto”
    Option “Device” “/dev/psaux”
    Option “Emulate3Buttons” “no”
    Option “ZAxisMapping” “4 5″
    EndSection

    Section “InputDevice”
    # generated from default
    Identifier “Keyboard0″
    Driver “kbd”
    EndSection

    Section “Monitor”
    Identifier “Monitor0″
    VendorName “Unknown”
    ModelName “Unknown”
    HorizSync 28.0 – 33.0
    VertRefresh 43.0 – 72.0
    Option “DPMS”
    EndSection

    Section “Module”
    Load “dbe”
    Load “extmod”
    Load “type1″
    Load “freetype”
    Load “glx”
    EndSection

    Section “ServerFlags”
    Option “Xinerama” “0”
    EndSection

    Section “Device”
    Identifier “Device0″
    Driver “nvidia”
    VendorName “NVIDIA Corporation”
    BoardName “GeForce GT 330M”
    EndSection

    Section “Screen”
    Identifier “Screen0″
    Device “Device0″
    Monitor “Monitor0″
    DefaultDepth 24
    Option “TwinView” “0”
    Option “metamodes” “nvidia-auto-select +0+0″
    Option “ConnectedMonitor” “DFP-0,DFP-1,CRT”
    Option “CustomEDID” “DFP-0:/proc/acpi/video/NGFX/LCD/EDID”
    SubSection “Display”
    Depth 24
    EndSubSection
    EndSection

    [Reply]

  10. Jim C. says:

    @anamtamrin

    Re Step 6.
    You should see a command line prompt at that point in the upper left of a mostly black screen requesting your user ID. Are you not seeing this?

    For the second part of your question, I’m guessing bad permissions? Try doing this first:

    chmod 755 NVIDIA-Linux-x86_64-195.36.24-pkg2.run

    Then run it from the command line like so:

    ./NVIDIA-Linux-x86_64-195.36.24-pkg2.run

    [Reply]

  11. Jim C. says:

    @anamtamrin

    oops, I missed a trick.

    This would probably be much better:

    sudo ./NVIDIA-Linux-x86_64-195.36.24-pkg2.run

    [Reply]

  12. david says:

    my brain hurts from following all the nvidia advice on the web. I am running older hardware with lynx, i have an onboard intel graphics and fx500 agp card in. in order for me to tell and show people that ubuntu the way…. this shouldn’t be so hard…. plug n play ??

    love ubuntu though

    [Reply]

  13. agatzebluz says:

    Works like a charm. Thanx

    [Reply]

  14. Jim C. says:

    @David: I’m sure we all agree on that, but then that is why we are messing around with an unstable release. To advise the guys doing the fixing.

    In my case, I had downloaded 10.4 by mistake but figured I would have the same problems with my bleeding edge nVidia adapater on 9.1 I was right and the work-around’s were the same also. :-) Now I am running 9.10 and am awaiting 10.4’s move out of beta.

    Speaking of mistakes, I resent it when Ubuntu make’s it hard to find the most recent stable release. They have the most recent beta pushed out there such that it is difficult to find anything else and easy to make mistakes and get the wrong version.

    [Reply]

  15. kafka says:

    Is it enough to kill X and then install nVidia drivers? I tried it without removing old driver (step 2-3), but the new driver did not appear in the hardware drivers menu.
    The problem is, that I don’t have a monitor and I have to relay on ssh/telnet. So, I’m afraid, that I couldn’t get access after removing old nVidia driver.
    Any advice?

    [Reply]

  16. Jay says:

    Hi, I did exactly what you wrote.

    After rebooting there was no message saying ‘Drivers could not be loaded, exit to terminal’ etc

    So I opened a terminal and did sudo service gdm stop

    Then proceeded installing using the CLI interface but when I ran the installer and pressed ‘Accept’ I got the exact same error message (ERROR: Unable to load the kernel module ‘nvidia.ko’…..)

    Any thoughts? This is quite an old PC with a NVidia 7600GT

    Thanks

    [Reply]

  17. erghezi says:

    when i run this command: ” sudo apt-get –purge remove nvidia-*”

    i get this error:
    ” Reading package lists… Done
    Building dependency tree
    Reading state information… Done
    E: Couldn’t find package nvidia-195-2.6.33.patch.txt”

    what’s mean latest line?

    [Reply]

  18. fowl says:

    I did the following commands and i was having an issue with Ubuntu still loading into the x server. I tried several ways to stop gdm. sudo service gdm stop and sudo /etc/init.d/gdm stop without luck. It seemed that something was not being blocked from the blacklist.

    I went into the software manager ~> installed software and typed nvidia into the search bar. I then removed everything from there. I restarted to a low resolution window and stopped gdm again. I then installed the driver and so far have not had any problems.

    Hope this helps anyone looking around for a way to install the latest driver and had similar issues. I kinda hope myself that it works out to be a lasting fix haha!

    fowl

    [Reply]

  19. Bvdp says:

    Just a quick thanks for this.

    Funny that you really need to stop X for the nvidia to install (the “real” one, that is). I’ve had no end of problems with the ubuntu-lucid nvidia stuff. Mainly, it’s very “jerky” and uses a lot of cpu. 195.36.24 is much nicer!

    Quick question: after blacklisting the drivers should one delete the entries after everything is running?

    [Reply]

  20. Jim C. says:

    Crud. I updated to the most stable version… I guess it aint so stable. Got trouble all over again with these rotten nvidia cards.

    Everything seems fine until I log in and then I get a black screen. If I restart the x server I see the nvidia logo flash. I’ve got the right settings in blacklist.conf… can’t figure out the deal.

    [Reply]

  21. Jim C. says:

    Someone just tried to send me a private message but my popup blocker nailed it. Turned off popup blocker for this site.

    [Reply]

  22. Jim C. says:

    Man is this weird. If I start using startx rather than kdm, I can get the login screen before getting the all black screen. Even weirder… If I hit Ctrl-Alt-Del I get the logout screen… but nothing else.

    Ideas anyone? I’m currently using previously mentioned ppa.

    [Reply]

  23. Athoz says:

    Really helpful it worked fine for me, but in hardware drivers can not see any of nVidia.

    [Reply]

  24. sXe says:

    Worked like a charm.

    Compal-IFL90
    Nvidia GeForce 8600M GT

    [Reply]

  25. sXe says:

    You cant see it in hardware drivers cause of step 2 in this guide. It was blacklisted so you could do an manual install of the gfx drivers instead.

    On my xubuntu 10.04 the “NVIDIA X Server Settings” was moved from
    Applications -> System
    to
    Applications -> Settings

    sXe

    [Reply]

  26. bayu says:

    thanks for the guide…
    my problem solved.

    [Reply]

  27. Jim C. says:

    Got it working again but I did a from-scratch re-install so I could improve my partitioning and use LVM. I’ve found it easy to miss steps in the nVidia installation process which is probably what caused me to get hosed up last time.

    [Reply]

  28. Jim C. says:

    Spoke to soon although I do have the GUI working fine. Now I can’t get a console login. Just a black screen. Solved this problem once before but can’t do it again to save my life. ;-)

    Again, system is Sony Viao VPCF115FM w/ GT 330M GPU.

    Tried setting GRUB_CMDLINE_LINUX_DEFAULT=”quiet splash vga=?”

    Where I’ve tried 771,793 and 795 where the ? above is.

    Here is what hwinfo reports:

    jim@blackstar:~$ sudo hwinfo –framebuffer
    02: None 00.0: 11001 VESA Framebuffer
    [Created at bios.464]
    Unique ID: rdCR.+9U5l6S7P63
    Hardware Class: framebuffer
    Model: “NVIDIA GT216 Board – 0696a290″
    Vendor: “NVIDIA Corporation”
    Device: “GT216 Board – 0696a290″
    SubVendor: “NVIDIA”
    SubDevice:
    Revision: “Chip Rev”
    Memory Size: 14 MB
    Memory Range: 0xe1000000-0xe1dfffff (rw)
    Mode 0x0300: 640×400 (+640), 8 bits
    Mode 0x0301: 640×480 (+640), 8 bits
    Mode 0x0303: 800×600 (+800), 8 bits
    Mode 0x0305: 1024×768 (+1024), 8 bits
    Mode 0x0307: 1280×1024 (+1280), 8 bits
    Mode 0x030e: 320×200 (+640), 16 bits
    Mode 0x030f: 320×200 (+1280), 24 bits
    Mode 0x0311: 640×480 (+1280), 16 bits
    Mode 0x0312: 640×480 (+2560), 24 bits
    Mode 0x0314: 800×600 (+1600), 16 bits
    Mode 0x0315: 800×600 (+3200), 24 bits
    Mode 0x0317: 1024×768 (+2048), 16 bits
    Mode 0x0318: 1024×768 (+4096), 24 bits
    Mode 0x031a: 1280×1024 (+2560), 16 bits
    Mode 0x031b: 1280×1024 (+5120), 24 bits
    Mode 0x0330: 320×200 (+320), 8 bits
    Mode 0x0331: 320×400 (+320), 8 bits
    Mode 0x0332: 320×400 (+640), 16 bits
    Mode 0x0333: 320×400 (+1280), 24 bits
    Mode 0x0334: 320×240 (+320), 8 bits
    Mode 0x0335: 320×240 (+640), 16 bits
    Mode 0x0336: 320×240 (+1280), 24 bits
    Mode 0x033d: 640×400 (+1280), 16 bits
    Mode 0x033e: 640×400 (+2560), 24 bits
    Mode 0x0345: 1600×1200 (+1600), 8 bits
    Mode 0x0346: 1600×1200 (+3200), 16 bits
    Mode 0x034a: 1600×1200 (+6400), 24 bits
    Mode 0x0360: 1280×800 (+1280), 8 bits
    Mode 0x0361: 1280×800 (+5120), 24 bits
    Config Status: cfg=new, avail=yes, need=no, active=unknown

    [Reply]

  29. Jim C. says:

    This link fixed my Black / Blank tty problem but, of course, now I have another problem.

    http://news.softpedia.com/news/How-to-Fix-the-Big-and-Ugly-Plymouth-Logo-in-Ubuntu-10-04-140810.shtml

    The nVidia xorg driver is somehow interfering with the uvesafb driver. Boot up sequence goes fine until xorg fires up then my virtual terminals get wavy as if there is an electrically noisy power tool around or someone boosting their CB radio to silly power levels.

    [Reply]

  30. Pete says:

    Good, now video is working faster, the only minor problem I see is a big Nvidia popup for less than a second during boot. I already did this Bootup/Plymouth workaround from here: http://ubuntuforums.org/showthread.php?t=1469475

    [Reply]

Leave a Reply