Intro: Installing an NVIDIA Graphics Driver on Ubuntu (9.04)
I decided to put this together because I've had to do this multiple times and simply searching via Google and forums has never given me straight up directions that worked. Read through all the steps before trying this.
One never knows if there will be strange differences based on having different hardware or settings. If you try this and get it to work another way, please post a comment describing what you did. For reference, the system I'm using is an AMD 64-bit machine with an NVIDIA GeForce G210.
This will probably work on any Ubuntu distro provided that it is current enough.
DISCLAIMER: If this happens to render your computer incapable of displaying anything useful on your monitor, I am not responsible. Be prepared with a backup of your X-server configuration file and a live CD to undo the changes that the installer file made. If replacing the X-server configuration file with your backup does not solve the problem, you'll have to look up another solution and complete the process on your own because I am too lazy to do it here.
That being said, installing the driver fixed the above problem for me when Ubuntu decided to be completely incompatible with my graphics card, which I had to remove before completing this process.
Step 1: Determine Which NVIDIA Device You Have - Skip This If You Know
Again, if you know which graphics card you have, skip this step because it's unfortunately not as straightforward as it might seem. If you know how to do this (perhaps through your windows device manager on another partition) go for it. This will assume that your graphics card is plugged into a PCI slot and not on-board.
All commands will be preceded with a colon and should be typed without quotation marks.
Open a terminal and type: "lspci"
Below is a screenshot of what I got when I did this.
Look for "VGA compatible controller" or "Display controller." This should show you the device's ID number. Mine happens to be 0a60. To find out what this translates to , I did a Google search which came up with this helpful forum post (see pictures): http://forum.notebookreview.com/gaming-software-graphics-cards/490809-nvidia-geforce-ion-quadro-198-05-whql-drivers-ms-update-released.html
This showed me that I have an NVIDIA GeForce 210.
Step 2: Download the Driver Installer From NVIDIA
Go to NVIDIA's driver download page ( http://www.nvidia.com/Download/index5.aspx?lang=en-us ).
Select your model - this again may not seem straightforward, but it's not that hard to figure out. After I discovered that I have a GeForce 210, I guessed (correctly) that it was 200 series, which allowed me to pick the GeForce 210 from the next drop down list. Select the proper operating system and language and hit search. At the next page, hit the green download button, then agree and download, and save the installer to an easy place to access - I recommend your desktop. You will need to navigate to it via command line or remember the whole pathname.
(Click the "i" in the top left corner of the pictures to see them in their original sizes.)
Step 3: Run the Installer
In order to run the installer, you need to exit the X server (the process that takes care of the graphical part of your OS) and run it via a command line.
Write the commands you need down if you can't see this on another computer because you will need to exit your session.
Log out of all users and get back to the login screen where you should have a list of options. This is usually in the bottom corner, but can be in a different place depending on which login GUI you have set up. I did the following:
Log out... > Log out > options (from the bottom left corner) > select session... > Failsafe terminal > Change session
and then logged in normally.
This should take you to a small terminal. From here, you will need to exit the X server using the following command: "sudo /etc/init.d/gdm stop"
NOTE: if you have kubuntu, the above should be: "sudo /etc/init.d/kdm stop"
(These stand for GNOME or K desktop manager if you are curious)
This should take you to a different looking terminal.
At this point, you should navigate to the location of the installer file. If you are not familiar with the command line, I hope you saved the file to your Desktop because the terminal should default there.
Use the following command, replacing "NVIDIA-Linux-x86_64-256.35.run" with the name of your file: "sudo sh NVIDIA-Linux-x86_64-256.35.run"
(if you are nor familiar with tab completion, type: "sudo sh NV" and then hit tab for the computer to complete the name for you, assuming you only have one file beginning with NV.)
Once you hit enter, just follow the directions. Make sure to have the installer update your X-server configuration file for you (hit the yes button when it asks). Hopefully it will tell you that the driver was successfully installed at the end.
Step 4: Restarting Your X Server
NOTE: The alternative is to reboot: "sudo reboot"
NOTE: You may need to change the type of session back to run X script or GNOME for the next time you log in.
Now you should be back at a terminal prompt. Type the following, replacing "gdm" with "kdm" if you have Kubuntu: "/etc/init.d/gdm start"
Obviously, this will restart your x server. It should take you back to the standard login screen. It should have the correct resolution. If not, log in normally, go to System > Preferences > NVIDIA X Server Settings and change it to what you need.