Overclock.net banner

Need help installing Nvidia drivers on ubuntu 14.04 (Pulling my hair out)

1K views 15 replies 7 participants last post by  Shrak 
#1 ·
Hi all

im in need of desperate help, I am a complete ubuntu noob I dont know what anything means or does. I have been following this guide from blademaster:

NVIDIA Drivers

1) For the following graphics cards:

GTX 660 Ti

GTX 670

GTX 680

GTX 690

GTX 760

GTX 770

Install ForceWare 319.76 -- later drivers have performance issues with GK104 when folding (last updated 6/8/2014)

For other graphics cards download the latest stable drivers ForceWare 340.24 (last updated 6/8/2014)

2) Disable the GUI of your operating system with the following command

sudo service gdm stop

3) Press CTRL + F1 to get a prompt to insert your Ubuntu username and password and log in

4) Run the following command

cd Downloads; chmod +x NVIDIA*; sudo sh NVIDIA*

It will most likely complain about nouveau (the open source nVidia drivers) being installed and therefore fail to install. Answer "yes" to all the prompts

5) Run the following command

sudo apt-get remove --purge nvidia*; sudo reboot

6) When it finishes rebooting, disable the GUI once again

sudo service gdm stop

7) login and enter this command

cd Downloads; sudo sh NVIDIA*

8) Answer "yes" to all of the questions

9) When it finishes installing, run the following command to reactivate your GUI

sudo service gdm start

Now your graphics card(s) should be ready to fold.

I run into problems once I attempt to complete step 4, I get the error message "unable to load the kernal module 'nvidia.ko'. This happens most frequently when the kernal module was built against the wrong or improperly configured kernal sources....etc etc".

I can get around this problem by typing -k $ (uname) at the end of the code, this allows me to install the driver, but then when I continue after step 4 I get the error message "You are trying to install on X server" or something similar. Again, I managed to somehow get around this by frankly googling X server and trying loads of different commands until it works...

But finally another problem surfaces, I manage to get the driver installed but my ubuntu just loads to a black screen, all I can do is ctrl+alt+f1/f2/f3 to type more commands in. I think its something to do with lightdm service but im not sure.

Could someone help please?

thank you
 
See less See more
#3 ·
Ok just to check the driver is being loaded at boot can you:

Code:

Code:
lspci -k | grep -A 3 -i VGA
This will show what driver is currently loaded. Also if you type dmesg, check for any errors pertaining to NVIDIA, if you want you could post it here but there will be a lot and I am also presuming your not typing this from that computer so at this point I wouldn't bother. If it shows nouveau or anything other than nvidia you will probably have to redo your initramfs.

Another command you could use to get information on the nvidia driver would be:

Code:

Code:
modinfo `modprobe -R nvidia`
Although I just think you have to regenerate your xorg.conf, this is as easy as:

Code:

Code:
sudo nvidia-xconfig
 
#7 ·
FYI for Installing Nvidia Closed source on Ubuntu or Mint I just did this. Remember these are cutting edge repos though.

sudo add-apt-repository ppa:xorg-edgers/ppa
sudo apt-get update
sudo apt-get install nvidia-340 (optional see below)

To remove:

sudo apt-get remove nvidia-340

Alternatively don't do the last line but after the update Look in your 'Drivers' section or additional Drivers section and select the one you want from the list.

((btw i appreciate op your wanting the older driver))
 
#8 ·
I have another problem now.

I think I'm getting it all installed but when it comes to starting the lightdm service again nothing happens just a blank screen?

Any ideas?
 
#9 ·
How much do you know your way around Unix stuff?

You could log into another virtual console using Ctrl-Alt-F1, F2, F3, etc. while there's that black screen on the console where the X server runs. Then go see if Ubuntu has the X server's output written into a log file somewhere in /var/log, see what's going on in that file at the end.
 
#11 ·
Remove all of your Nvidia packages.

Code:

Code:
sudo apt-get remove --purge nvidia-*
Then update your sources

Code:

Code:
sudo apt-get update
Then you should just have to run

Code:

Code:
sudo apt-get install nvidia-319-updates nvidia-settings
Of course reboot after all of this, nvidia-settings is what you will use to adjust your GPU settings.

You should not have to download them and manually compile them yourself unless you need something special which it doesn't seem you do.
 
#12 ·
OP, make sure you have:
build-essential dkms
Installed.
 
#13 ·
#14 ·
Quote:
Originally Posted by $ilent View Post

Thanks which part of my problem will that solve?
Building the kernel module automatically when there's a kernel update.
You'd have to run the installation again though if you didn't have dkms installed before.
 
#16 ·
Are you really answering "Yes" to all the prompts without reading what they say like the instructions say? That may be the first problem here.

And instead of using wildcards in the commands I would personally just use tab completion to insure it's triggering the proper file ( in case you have multiple files starting with "NVIDIA", you would then be triggering all of them with the wildcard ).

Swap to a different TTY

Code:

Code:
## 1 is normally where X is started from and 7 being where it runs from usually, you can use 2 through 6;
Ctrl+Alt+F2
Stop the LightDM service

Code:

Code:
sudo service lightdm stop
Remove any currently installed nvidia drivers ( fresh installs shouldn't have any, so you can skip this );

Code:

Code:
sudo apt-get purge nvidia*
Change the files permission to be executable

Code:

Code:
## In this case it should be something along the lines of; NVIDIA-Linux-*-319.76.run ( The wildcard here being the architecture ( x86 or X86_64 ) )
sudo chmod +x ~/Downloads/NVIDIA-Linux-*-319.76.run
Execute the file to begin installation

Code:

Code:
## In this case it should be something along the lines of; NVIDIA-Linux-*-319.76.run ( The wildcard here being the architecture ( x86 or X86_64 ) )
sudo sh ~/Downloads/NVIDIA-Linux-*-319.76.run
Read the prompts given and answer correctly, don't just blindly answer "Yes" to them all. If all goes well It should then install the driver, and set the module ( you can always ` sudo modprobe nvidia ` ) and then start the lightdm service again, or just reboot and it should start.
 
This is an older thread, you may not receive a response, and could be reviving an old thread. Please consider creating a new thread.
Top