The purpose of this tutorial is to install the NVIDIA drivers on Ubuntu Linux on optimus system ( Intel + Nvidia) and switch from a opensource Nouveau driver to the proprietary Nvidia driver. Follow along with our step by step instructions below to install NVIDIA drivers on Ubuntu.
1. Nvidia Graphic Install
Go to Activities >> Software & Updates >> Additional Drivers.
Apply changes and reboot the system post the installation and then validate the driver installation by going again to the Additional Drivers tab.
2. Install Nvidia Prime
sudo apt-get install nvidia-prime
Then you will have Nvidia X Server Settings in Dash. And there you can find PRIME profiles.
Everytime you wanna switch to Intel vga, just type using this command
sudo prime-select intel
Switch back to nvidia
sudo prime-select nvidia