Hey everyone,
this tuto has for purpose to show you how to install the Nvidia driver on your system. This tutorial is mainly for those that have two GPUs (so mostly laptop), which are the Intel integrated GPU (Low power consumption) and the Nvidia GPU (high power consumption).
The first thing you want to do is to know whether you prefer to use the nouveau open sourced driver or the nvidia proprietary driver. Make your own research to know the one you prefer and that fit best your needs.
For those that choosed the nouveau driver follow the part 1 of this guide, for the others lets go in part 2.
Part 1: Nouveau
Since the nouveau driver is already integrated to the kernel, there is only one thing to do: Install bumblebee and primus:
sudo apt update && sudo apt install bumblebee primus
To start a programm using the nvidia gpu do this:
optirun yourprogram
And you are done with the install ! To test if the install is successful run this:
optirun glxgears
You might need to reboot to make it work.
Part 2: Nvidia-driver
For those that choosed the proprietary nvidia driver, two extra step are needed.
The first thing to do is to blacklist the nouveau driver, in order to do that, you have to create this file:
sudo nano /etc/modprobe.d/blacklist-nouveau.conf
And write this in the file:
blacklist nouveau
blacklist lbm-nouveau
options nouveau modeset=0
alias nouveau off
alias lbm-nouveau off
When you are done do Ctrl+X and save it.
Then you have to run this to make the changes:
sudo update-initramfs -u
Then reboot.
Now you can install the nvidia driver:
sudo apt update && sudo apt install nvidia-driver
You can install bumblebee and primus:
sudo apt install bumblebee-nvidia primus
To run a program using the nvidia gpu, use optirun:
optirun yourprogram
To test your config, you can run this:
optirun glxgears
A reboot might be needed to make bumblebee work.
And there you are done !
You can contact me for troubleshooting or go on the wiki page of the Bumblebee project: