Dell Inspiron 7559 Ubuntu Linux Guide
Last updated 10 July 2018
This guide will show you how to install and configure an Ubuntu Linux 16.04/18.04 LTS distribution (Ubuntu, Lubuntu, Xubuntu, Kubuntu, Ubuntu Gnome, Ubuntu MATE) on the Dell Inspiron 7559 laptop.
Do not try to upgrade from Ubuntu 16.04 LTS to 18.04 LTS now. This might crash your OS (Crashed mine! Had to do a fresh install of Ubuntu 18.04 LTS.). Upgrade from 16.04 LTS to 18.04 LTS will be enabled late july.
DISCLAIMER This document just details the processes that I discovered through hours of trial and error to get a stable Ubuntu distribution working on my laptop. I'm not liable for any damage or adverse effects that this has on your system. Always back up your important data before doing any major work to your computer.
Table of Contents
Reading this Guide
Pre-requisites
Installation
Initial Setup
Installing the Nvidia Driver
Update Linux kernel to 4.8.5.
Installing Bumblebee
Installing Power-Management Utilities
Running Games and Applications with the Right GPU
(Optional) Installing the Intel Driver and Firmware
Known Issues
Reading this Guide
While it might seem straightforward, I just want to make sure this document's structure is absolutely clear.
Text within blue boxes indicates instructions intended only for Ubuntu Linux 18.04 LTS. The sections that were not tested with Ubuntu Linux 18.04 LTS will be explicitly stated.
Text within green boxes usually contains clarifying information and could be helpful if you're curious as to why something is the way it is.
Text within a red box like this should never be ignored as it usually contains warning information.
Text in a black box like this usually represents something typed into a terminal or a text file!
sudo apt update
Text like this usually represents something you need to select, click, or a program name to use. Something that you interact with or may see in a text file or interface.
Pre-requisites
Some experience installing an Ubuntu distribution
Installation media for said Ubuntu distribution
A Dell Inspiron 7559 laptop (duh)
Installation
Make sure Secure Boot is disabled from the BIOS.
If you intend to dual boot with Windows, make sure Window's Fast Boot is disabled.
I updated my BIOS to v1.1.8, but I don't think it is required for all of this to work as I had a successful setup following these procedures prior to doing so.
Boot from your installation media.
Highlight the Install Ubuntu entry and press e on your keyboard.
Modify the line that contains quiet splash at the end and change it to:
nomodeset i915_bpo.nomodeset=1 quiet splash
Press F10 to boot.
Proceed with the installation as normal.
Reboot.
Initial Setup
Follow Installation steps 4-6 to boot into the operating system.
Connect to a network.
If you didn't do this during the install, update your system.
sudo apt update
sudo apt upgrade
Installing the Nvidia Driver
Add the proprietary graphics drivers repository.
sudo add-apt-repository ppa:graphics-drivers/ppa
sudo apt update
Install your chosen Nvidia driver.
sudo apt install nvidia-367
Open the GRUB configuration file: /etc/default/grub.
sudo vi /etc/default/grub
Change the line that reads GRUB_CMDLINE_LINUX="" to
GRUB_CMDLINE_LINUX=
"
acpi_backlight=native acpi_osi=
"
Save your changes and close the file.
Apply the changes to GRUB. Doing this means that we no longer have to manually add kernel boot parameters to boot like we did earlier in the guide.
sudo update-grub
Switch to the Intel GPU to save power.
sudo prime-select intel
Reboot.
Update to Linux kernel 4.8.5 for better GTX 900 & Optimus support
Did not test this section with 18.04 LTS installation.
Make a directory to download the kernel files to, make sure it's empty then cd into it.
Download the Ubuntu mainline Linux kernel 4.8.5. You need the header files for amd64, all, and the image files for amd64.
wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.8.5/linux-headers-4.8.5-040805-generic_4.8.5-040805.201610280434_amd64.deb http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.8.5/linux-headers-4.8.5-040805_4.8.5-040805.201610280434_all.deb http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.8.5/linux-image-4.8.5-040805-generic_4.8.5-040805.201610280434_amd64.deb
Install the new kernel.
sudo dpkg -i *.deb
Reboot.
Installing Bumblebee
Did not test this section with 18.04 LTS installation.
Bumblebee is a program that allows "on-the-fly" GPU switching similar to what Nvidia Optimus does on Windows. Unfortunately, Nvidia doesn't exactly support this on Linux. Without Bumblebee, we can only switch GPUs and then log out/back in to change it. This results in us using the power-hungry Nvidia GPU for all applications rather than just the game or program we need it for. And like I said, if we want to change, we have to initiate the change and then log out and back in. Annoying!
Bumblebee provides the convenience of switching the GPU for us just for the given application and then powers down the beefy GPU when we're not using it. Oh, and we don't have to log out then back in. Awesome, right?
Add the Bumblebee Testing repository.
sudo add-apt-repository ppa:bumblebee/testing
sudo apt update
Install bumblebee.
sudo apt install bumblebee
Open Bumblebee's configuration file ( /etc/bumblebee/bumblebee.conf) in your preferred text editor.
sudo vim /etc/bumblebee/bumblebee.conf
Edit the line in the [bumblebeed] section that looks like Driver= and change it to:
Driver=nvidia
Change every occurence of the word nvidia-current in this file to the Nvidia driver you selected. In my case, it's nvidia-367.
If you're using vi or vim, you can just type :%s/nvidia-current/nvidia-367/g and hit enter to change all occurences of nvidia-current with nvidia-367.
Edit the line in the [driver-nvidia] section to say:
PMMethod=bbswitch
Save your changes and close the file.
Open /etc/modprobe.d/bumblebee.conf in your favorite text editor.
Append blacklist entries to match the Nvidia driver you installed to the bottom of this file.
blacklist nvidia-367
blacklist nvidia-367-updates
blacklist nvidia-experimental-367
Reboot
Verify you can use Bumblebee.
optirun glxinfo | egrep -i
'
nvidia|gtx
'
connor@connor-Inspiron-7559:~$ optirun glxinfo | egrep -i
'
nvidia|gtx
'
server glx vendor string: NVIDIA Corporation
OpenGL vendor string: NVIDIA Corporation
OpenGL renderer string: GeForce GTX 960M/PCIe/SSE2
OpenGL core profile version string: 4.5.0 NVIDIA 367.57
OpenGL core profile shading language version string: 4.50 NVIDIA
OpenGL version string: 4.5.0 NVIDIA 367.57
OpenGL shading language version string: 4.50 NVIDIA
Verify that the discrete card is now off since we aren't actively running a program with optirun.
cat /proc/acpi/bbswitch
0000:02:00.0 OFF
OPTIONAL Download and install the VirtualGL tools to benchmark your system and make sure optirun uses the correct video card. I like using glxspheres64
Installing Power-Management Utilities
Battery life isn't too bad when your brightness is a bit lower. I usually install TLP to squeeze some more time out of my Linux battery life. After you install it and verify that it's running, it's pretty hands-off from there and it'll take care of itself from then on.
You won't have the same amount of time on battery as a Macbook does, but depending on the screen brightness, I can usually make it a full day on campus with my laptop doing web browsing, word processing, or programming.
Install tlp and tlp-row.
sudo apt install tlp tlp-rdw
Make sure TLP is running in battery mode.
sudo tlp bat
Running games and applications with the proper GPU
Did not test this section with 18.04 LTS installation.
Running Steam games
Right click on the game in your Steam library and click Properties.
Click Set Launch Options.
Enter primusrun %command%.
If you already have launch options in this box, make sure that you put primusrun at the very beginning and put %command% at the very end and everything should work fine.
Play your game normally by launching it through the Steam client!
Running applications from the command line
Prefix the command with optirun. We did this earlier when we ran glxinfo.
Example:
optirun firefox
Running Wine games
Similar to running command line programs, you can just do:
optirun wine gamenamehere
(Optional) Installing the Intel Graphics Driver and Firmware
Did not test this section with 18.04 LTS installation.
This step is optional just because I followed it to quiet down some "warnings" given saying that some i915 firmware is missing or whatever. It only fixes one or two of the warnings but the other one remains even after installing it. I haven't investigated this too much to see if there's an actual benefit, but as far as I know, you won't harm anything by skipping this.
Download the Intel Graphics Driver Installer.
Install the .deb we just downloaded.
sudo dpkg -i
.deb
Run the Intel Graphics Installer for Linux program (you may need to open your dash/search for the application, it has a GUI).
Reboot.
Download the Skylake DMC and GuC graphics firmwares from Intel.
Extract the contents of the archives.
tar -xf name_of_downloaded_file_here
Go into the extracted folders one at a time and install the firmwares.
sudo bash ./install.sh --install
Reboot
Known Issues
The Brightness Function keys don't work
As already mentioned above, acpi_backlight=vendor setting in GRUB works well with 18.04 LTS installation and hence the brightness function keys do work.
(Possible fix!) Changing the GRUB configuration from acpi_backlight=native to acpi_backlight=vendor may fix this issue. A kind visitor to the guide mentioned that *buntu 16.10, the latest kernel, and those GRUB settings restored brightness function key functionality.
I suspect this has something to do with some weird quirk of the ACPI controls after installing the Nvidia driver. The workaround is described in the Nvidia driver setup section where we modify Grub's boot parameters. This does not regain use of the function keys, but it does allow for controlling the brightness via settings, brightness applet, or some other brightness controller application.
Bumblebee service status says it failed to load module "mouse"
Not entirely sure what this means, but it hasn't really interfered with anything.
Last updated