A Long Guide on Dual-Booting Ubuntu 18.04.2 LTS and Windows 10 on the Dell XPS 15 9560
By: Bored College Student
Tags: Windows 10, Dual Boot, Xps 15 9560, Ubuntu

Part 5: Improving Battery Life

If you’ve perused Reddit where people discuss Linux on the XPS, you know that battery life is pretty bad. This is usually because the dual graphics card setup of the XPS doesn’t play too well with Linux to begin with. It gives the 1050 power even though it uses the integrated Intel graphics for your display. As a result, power draw at idle could be like 20W which is insane.

To fix that, we’re going to use 3 pieces of software:

TLP Power Management PowerTOP Nvidia PRIME

Another piece of software some people recommend is Bumblebee which lets you use the 1050 only when you really need it. I never plan on using my 1050 while in Linux so I didn’t bother, but you can search up guides for it.

We’re going to start out battery improvement techniques by editing the boot options again (I promise this is the last time). Go back to the GRUB_CMDLINE_LINUX_DEFAULT line within /etc/default/grub and add acpi_rev_override=1 after splash and before nouveau.modeset=0. So now your line should look like this:

GRUB_CMDLINE_LINUX_DEFAULT=“quiet splash acpi_rev_override=1 nouveau.modeset=0”

Save your changes and run:

sudo update-grub

This makes sure grub is aware of these new boot options and will use it one the next boot. Once you’ve done that, you can start installing the software I listed above using the commands below:

sudo apt-get update

sudo apt-get install tlp tlp-rdw powertop

sudo tlp start

sudo powertop

Once you run the last command, your terminal window should go blank for a little bit before loading up PowerTOP. Make sure your laptop is unplugged before you do so. If your laptop is plugged in, PowerTOP won’t be able to report a battery discharge rate so you have to exit PowerTOP, unplug your laptop and re-enter PowerTOP. PowerTOP should report a discharge rate anyhwere from 8 to 12W. This means, with the 97WHr battery like mine, you should get between 8 and 12 hours of battery life at idle or with light web browsing.

Now with TLP and PowerTOP running, we can get to Nvidia PRIME. Within Ubuntu, press the super key (the Windows key on the keyboard) and search for Software and Updates. Go over to the Additional Drivers Tab and your 1050 drivers should load up. Select nvidia-driver-390 and follow the steps.

At one point during the installation of the Nvidia driver, you will be asked to enter a Secure Boot password. This is because we didn’t disable Secure Boot earlier. Enter a Secure Boot password and write it down somewhere for now. You’ll need it afterwards. Once the Nvidia driver installs, you can reboot the system. Before GRUB loads, you should see a dark blue screen with the text Shim UEFI key management at the top. Press any key and select Enroll Key in the list of 4 options. Continue until it asks for a password. Enter the secure boot password from before and continue. Ubuntu should boot up normally and your Nvidia card should be working. To make sure your Nvidia drivers are installed correctly, run:

nvidia-smi

You should get an output that has your driver version as well as your Nvidia card listed. If you get any other output, it probably means your Nvidia driver wasn’t installed correctly. This means you have to purge remove any Nvidia package that was installed and reinstall the driver.

If the driver was installed correctly, you’ll probably notice a significantly higher power draw now. Anywhere from 15 to 25W. That is because our 1050 is now getting power. To stop this, run:

sudo prime-select intel

This will tell the system to disable the 1050 and power on the Intel graphics on the next boot. So reboot your system and your power draw should have reduced down to 8–12W again.