- There are two modes of this installation
- Install Ubuntu to only use NVIDIA GPU. Intel HD doesn't work in this mode but everything works really well in this setting and you don't have to install bumblebee and all
- Install bumblebee to switch between NVIDIA and Intel GPU as required to save battery power(also it's life). Using this you will need to use optirun to make any program run using GPU and Cuda. This can be problematic in certain scenarios as the optirun library uses lots of old libraries which creates conflict with newer programs(like pip)
Steps:
- Download Ubuntu 16.04 amd64 iso image
- Download Rufus for Windows. We will use this to create the bootable flash drive.
- Start Rufus and choose to create 'GPT for UEFI boot partition'
- Goto BIOS/System (or BIOS/Boot) and change the order of boot devices to give USB-HDD/USB higher priority than HDD. You will have to disable 'Fast Boot' and 'Secure Boot'. Then save changes and reset.
- When at the Grub menu, highlight
Try Ubuntu without installing
and presse
. Go to the line withquiet splash
in it and addacpi=no nouveau.modeset=0
and pressF10
. - Ubuntu will boot from live-usb now.
- Following partitioning is required when you are trying to install Ubuntu on a disk with GPT partition connected to a UEFI system.1
- Following partitions are must for a proper installation
EFI
: A 250MB ~ 1GB partition of typeefi
. Position this at the beginning of the disk (or atleast within the first 100GB). This is automatically mounted at /boot/efiswap
: Should be of size as big as the RAM[root] \
: Can be of any size. Recommended file system - ext4
- If you are installing the system on a external HDD (USB-HDD) it is recommended that the external HDD is empty.
- Edit
/etc/default/grub
file to change the following value,GRUB_CMDLINE_LINUX_DEFAULT="acpi=off nouveau.modeset=0 i915.modeset=1 quiet splash"
- Then run
sudo update-grub
- Restart your system. Now you wouldn't need to add the acpi=no etc. options in the GRUB menu.
Next you should update your repositories and packages by running,
sudo apt-get update
sudo apt-get upgrade
sudo apt-get dist-upgrade
sudo apt-get autoremov
Restart your system once and verify it's working properly at this point.
Now we start the process to get Nvidia drivers installed on the system, but before we do that, we need to remove nouveau and nvidia-current(if any) drivers as it may conflict with newer nvidia drivers. Press Alt + Ctrl + F1
to access consoles. Stop the Xserver and remove any existing installs of Nvidia, nouveau etc.
sudo service lightdm stop
sudo apt-get remove --purge nvidia*
sudo apt-get remove --purge bumblebee*
sudo apt-get --purge remove xserver-xorg-video-nouveau*
To Blacklist nouveau, add the following lines to /etc/modprobe.d/blacklist.conf
blacklist nouveau
blacklist lbm-nouveau
alias nouveau off
alias lbm-nouveau off
options nouveau modeset=0
Disable gpu-manager.service, as it has a tendency to overwrite xorg.conf and result in black screen on boot.
sudo vi /etc/init/gpu-manager.conf
Comment these start on settings ; GPU Manager ruins our work
# start on (starting lightdm
# or starting kdm
# or starting xdm
# or starting lxdm)`
task
exec gpu-manager --log /var/log/gpu-manager.log
Create initramfs sudo update-initramfs -u -k all
. Now restart your PC once.
- Download CUDA 8.0 ga2 release local installer .deb file
- Run
dpkg -i cuda-8.0-ga2-xx.deb
sudo apt-get update
sudo apt-get install cuda-8.0
Now restart you system. Once you get in you should be able to use your GPU and CUDA