Nowadays many notebooks use technology Optimus, used by NVIDIA graphics cards to manage the switch between the integrated card and the dedicated card to get the maximum graphics performance when necessary and save battery instead during a common use.
For Windows, the available drivers work pretty well, while for Ubuntu and derivatives the situation is more complicated and although NVIDIA support is giving better results lately, what makes the most of Optimus technology is Bumblebee.
After installing Ubuntu on notebooks with this technology we can immediately notice that the PC heats up abnormally, which has a low autonomy (in my case in fact the battery would last at most an hour) and that the brightness is not adjustable! Furthermore, the performance will not be the best. So before doing any installation (especially video drivers), let's install Bumblebee.
To install Bumblebee you need to run the following command lines in the terminal.
First we add the repositories
sudo add-apt-repository ppa: bumblebee / stable
sudo apt-get update
and install Bumblebee on Ubuntu 13.10
sudo apt-get install bumblebee bumblebee-nvidia primus linux-headers-generic
in the cases, instead, of Ubuntu 12.04 - 13.04
sudo apt-get install bumblebee bumblebee-nvidia virtualgl linux-headers-generic
and for the LTS versions, that is the 12.04.3 we execute the following line
sudo apt-get install bumblebee bumblebee-nvidia virtualgl linux-headers-generic-lts-raring
and restart our PC. Upon restart we will notice the first changes, so we just have to update the video drivers.
Update NVIDIA drivers
To update the drivers, just execute a single line in the terminal and then modify the Bumblebbe configuration file
sudo apt-get install nvidia-319-updates nvidia-settings-319-updates
where 319 obviously represents the version. Now we just have to edit the file bumblebee.conf which can be accessed directly from the terminal by typing:
sudo nano /etc/bumblebee/bumblebee.conf
where we need to change the lines to follow
|Driver =||Driver = nvidia|
|KernelDriver = nvidia-current
||KernelDriver = nvidia-319-updates|
|LibraryPath = / usr / lib / nvidia-current: / usr / lib32 / nvidia-current||LibraryPath = / usr / lib / nvidia-319-updates: / usr / lib32 / nvidia-319-updates|
|XorgModulePath = / usr / lib / nvidia-current / xorg, / usr / lib / xorg / modules||XorgModulePath = / usr / lib / nvidia-319-updates / xorg, / usr / lib / xorg / modules|
Without this we save with Ctrl + O and leave the file with Ctrl + X and restart the computer.
NOTE: It is important to update the video drivers after each kernel update!
Run a program
Bumblebee uses bbswitch to manage the activation / deactivation of the NVIDIA dedicated card, however to start an application with the NVIDIA graphics card it is necessary to type in the terminal optirun followed by the name of the application and for more information on the command you can use optirun - help
In case you want to remove Bumblebbe, these are the commands to remove repository, application and all dependencies
sudo ppa-purge ppa: bumblebee / stable sudo apt-get purge bumblebee sudo apt-get --purge autoremove
All that remains is to enable the brightness and you can read the guide in this article.