Installing Ubuntu 12.04 on the HP Envy 6

2012 Sep 02 -

Shortly after starting my job at the Max Planck Institute for Radio Astronomy I received an HP Envy 6 to replace my older MSI MS1719 (GX700). The HP Envy 6 is very similar to the HP Envy 6T so the instructions listed here should work for it as well. I was able to get everything (including switchable graphics) working on Linux except the white “audio muted” LED on the keyboard and the “disable touchpad” button.

What works?

What doesn’t work?

What wasn’t tested?

The details

Before we start talking about getting Linux running, lets discuss the specs. The machine is an UltraBook class laptop so it is thin and very light. For only $800 USD, I’d say the specs are quite reasonable:

Getting Ubuntu to run on the machine took a little bit of trial and error on my behalf, but hopefully this will benefit someone else. I decided to keep a Windows partition on the machine (for gaming) so my first step was changing the way Windows is configured. First I connected a USB DVD burner and wrote out the five Windows restore DVDs in case I messed something up. Then I deleted the restore partition from the drive and created an empty extended partition into which Linux could be installed. After this, I disabled the Intel Smart Caching (this uses the SSD as a cache for frequently accessed files from the hard drive and leads to a SIGNIFICANT performance increase). This freed up 28/32 GB on the SSD. (The remaining 4GB is used by Windows’s resume functions and I haven’t figured out how to move it, but for now this is ok.)

Installing Ubuntu

Next I started the Ubuntu installer from a USB disk. To boot add the acpi_backlight=vendor option to the kernel. Because Intel Smart Caching isn’t supported in Linux, I put the main OS (i.e. “/") onto the SSD and “/home” onto the HDD. My choice in doing it this was was motivated by reading this and from some other bench-marking article (whose URL I have forgotten) which indicated you get the best performance by putting the OS files on the SSD.

In retrospect, I think I should have placed /tmp, /var/log and a few other frequently-written-to locations on the HDD (or, in the case of /tmp, in a RAM disk) to save the SSD a few thousand writes a day. Display and backlight

Once you get Ubuntu installed, the display probably won’t work correctly. If (when?) this happens, reboot into recovery mode and drop to a console. Then edit the GRUB2 boot parameters in /etc/default/grub to add acpi_backlight=vendor to the kernel parameters , as follows:

GRUB_CMDLINE_LINUX_DEFAULT="splash acpi_backlight=vendor"

Then update grup with a sudo update-grub and reboot.

Note, I’m not sure if these changes will persist after a kernel update, so keep them in mind.

Broadcom BCM4313 [14e4:4727] wireless card drivers

Getting wireless working took me quite a while to figure out. By default the brcmsmac drivers included with the kernel will be loaded. These work, but the signal strength I received from my access point was very, very bad. Installing the broadcom-kernel-source package (which at the time of this writing has version increased the signal strength considerably, but took forever to connect and tended to have horrible ping times to my router (ranging from 1ms to 9000 ms).

The lengthy connection time issue is addressed by a nice post by pof. He even includes a PPA with the updated drivers. So, I took his PPA version to get the updated driver:

sudo apt-get purge bcmwl-kernel-source
sudo add-apt-repository ppa:poliva/pof
sudo apt-get update
sudo apt-get install broadcom-sta-dkms

My problem with ping times was related to power management. As explained on Stack Overflow, all you need to do is

gksudo gedit /etc/pm/config.d/blacklist

and put the line


in it. With these two changes, the hardware switch, indicator light, and power management should function normally. If you still have problems with ping times, try manually disabling power management with

sudo iwconfig wlan0 power off

and reconnect to the AP. If this fixed the issue, see the post by jrg at the bottom of the aforementioned Stack Overflow page.

I would really suggest trying some different power settings to try to optimize power settings so battery life might be extended.

ATI Switchable Graphics

This was surprisingly easy to get working correctly. Unfortunately switchable graphics are not as clean as they are in Windows (namely automatic). In order to switch between GPUs you need to run the ATI configuration utility (either command line or the GUI) and select the other graphic device. Then, restart X (i.e. logout then login again).

Installing the drivers is quite easy. If you want to use the drivers from Ubuntu, just do this:

  1. Install ATI drivers from the restricted drivers manager
  2. Before rebooting, type the following into a terminal to rewrite the X11 configuration file: sudo aticonfig –initial -f
  3. Restart

At this point, the ATI graphics will work, but the Intel HD 3000 graphics will lack any hardware acceleration. To fix this follow step 2 instructions here paying close attention to the 32 or 64-bit instructions.

If you require the latest drivers from ATI, purge all ATI graphics-related packages from your system then install the drivers from ATI. Repeat everything after step 2 above.

Doing this I have switchable graphics working nicely. I’ve confirmed that OpenGL, OpenCL (GPU computing library), and HDMI out work when using the discrete (ATI) card. OpenGL and HDMI out when using Intel Graphics.

The card reader

The card reader does not work out of the box. You simply need some UDEV rules (see bug 971876). Until this bug is patched, do this:

sudo apt-get install dkms
sudo dpkg -i rts-bpp-dkms_1.1_all.deb
echo 'DRIVERS=="rts_bpp", ENV{ID_DRIVE_FLASH_SD}="1"' | sudo tee -a /lib/udev/rules.d/81-udisks-realtek.rules

#A note about the touchpad

Left click by either a single finger tap, or by depressing the lower portion of the touchpad. Right click is accomplished by two-finger tapping. Depressing the lower-right side of the touchpad is treated as a left click. Disable touchpad button not working

Battery life

With WIFI power management disabled and using the ATI card, I’ve consistently seen four hours of battery life. Using the Intel HD 3000 graphics I know it lasts longer (perhaps five hours total), but I haven’t extensively timed it.