Nvidia problem: freeze computer 14.04 x64 [closed]

I had a similar kind of issue with my laptop. It use to freeze after almost every 15 minutes. The default nouveau driver was not compatible with my Nvidia GTX 950M graphics card. I installed the driver directly from nvidia website but end up in the login loop kind of issue. Please refer to this Nvidia graphics card driver installed led to login loop

Finally I followed these steps:

sudo apt-get purge nvidia*  
sudo reboot 

sudo add-apt-repository ppa:graphics-drivers/ppa
sudo apt-get update
sudo apt-get install nvidia-358
sudo reboot

as your ubuntu is freezing - either do Ctrl+Alt+F1 and issue the following commands or simply login into text single user mode while grub2 loading(press e and edit the kernel params to add single ...) and then execute these commands.

and was able to get this fixed. Got into issue with the unity desktop and then fixed that also.

Please make sure that if you went to the nividia website and installed the driver from there(N*.run) - you must un-install this by going to /usr/bin/nvidia-installer. There should be something like nvidia-install(link to uninstall). Run that one and follow all the instructions. You should install the nvidia drivers from the ppa repository after cleaning up(purging the previous nvidia install). There is a bug in ubuntu and any time there is any issue in terms of installing the nvidia driver - you will end up with login loop.