How do I use ubuntu-device-flash with the BQ Aquaris E4.5 and Aquaris E5

For production Ubuntu Phone devices, adb has been disabled in recovery, and this affects ubuntu-device-flash operation.

You must supply a recovery image with adb enabled, which ubuntu-device-flash will use temporarily while doing its work:

  • For BQ Aquaris E4.5 Ubuntu Edition (aka krillin), use recovery-krillin.img
  • For BQ Aquaris E5 Ubuntu Edition (aka vegetahd), use recovery-vegetahd.img

ubuntu-device-flash can then be supplied with the --recovery-image argument, eg:

ubuntu-device-flash touch --channel ubuntu-touch/stable/bq-aquaris.en --bootstrap --recovery-image path/to/downloaded/recovery.img

Note that when the command prompts you with:

Expecting the device to be in the bootloader... waiting

You can put a Aquaris E4.5 and Aquaris E5 in the 'bootloader' by holding down Power + Volume Up for a few seconds, releasing the Power button when the red LED lights as the machine reboots, and then selecting 'fastboot' from the device's boot menu.

unknown flag `recovery-image'

If you get this error, that means you are still using an older version of ubuntu-device-flash. Please install the latest version using the ppa

sudo add-apt-repository ppa:phablet-team/tools
sudo apt-get update; sudo apt-get upgrade

Another reason for failure to enter recovery might be unsufficient privileges for the usb device of the ubuntu computer.

I tried John's flash command but still got a "Failed to enter Recovery" error. The solution came to me when I booted the device into fastboot mode, flashed the recovery image with the fastboot command and booted this image. Unless I had a file "/etc/udev/rules.d/80-persistent-usb.rules" with the contents:

SUBSYSTEM=="usb", ACTION=="add", SYSFS{idVendor}=="2a47", MODE="0666", SYSFS{idProduct}=="*"

on my ubunutu computer I was not able to access the device running the recovery kernel.

After I added this file, I could "adb shell" and enter the recovery system. And also after that change, John's command worked as expected. My ubuntu computer runs a somewhat modified Linux but based on ubuntu 14.04.