Flashing Sailfish to Xperia XA2 fails. Troubleshooting.

Jolla Care -

The following issue has been observed to happen on Ubuntu computers (version 18.04 at least) sometimes when installing Sailfish X to an Xperia XA2 device via a USB3 port.  It is not clear where the culprit is, and if it would only happen with Ubuntu 18.04.

We present a workaround for it in this help article.


The problems

The failures typically hit when using a USB3 port on Ubuntu 18.04 computer (we are not yet aware of this in other environments).

A)  Flashing starts but later fails

Soon after starting the script to flash Sailfish X to an Xperia XA2 the following can happen and appear at the computer terminal:

$ ./flash.sh
Detected Linux
Searching device to flash..
Found 1 devices: CQ3000XMTM
Fastboot command: fastboot -s CQ3000XMTM
Flashing boot_a partition..
Sending 'boot_a' (17772 KB) FAILED (remote: 'unknown command')
Finished. Total time: 0.001s


B) Flashing fails to start

  $ ./flash.sh
Detected Linux
Searching device to flash.. Found 0 devices: Incorrect number of devices connected. Make sure there is exactly one device connected in fastboot mode.


How to avoid the problem

1) Check if there is a USB2 port [1]  on your computer or on the USB hub you are using. Connect your phone to the USB2 port for flashing.

2) If your USB hub has only USB3 ports, then connect the hub to PC with a USB2 data cable, and XA2 to the hub with any USB data cable ("USB C-type" in the XA2 end) [2].

3) If there are only USB3 ports available, then this problem can be worked around in the following way on the PC:

- Force USB3 ports to USB2 mode temporarily (note that the 2nd command below is long - be sure to copy all of it)

sudo su
lspci -nn | grep USB | cut -d '[' -f3 | cut -d ']' -f1 | xargs -I@ sudo setpci -H1 -d @ d0.l=0

- Install Sailfish X to your Xperia XA2 now.


In the end of a successful flashing session this script will write to the terminal:

Flashing completed.
Remove the USB cable and bootup the device by pressing powerkey.


Cleaning up

Restart your computer now to bring the USB3 ports to their normal mode. Alternatively, give the following reverting command:

sudo su
lspci -nn | grep USB | cut -d '[' -f3 | cut -d ']' -f1 | xargs -I@ sudo setpci -H1 -d @ d0.l=1


What if the problem persists

Contact Jolla customer support again (file a new ticket if you do not have a ticket open yet).

Force your XA2 to the fastboot mode (blue LED), give the command below, and attach the output to your ticket, please.

fastboot getvar all



[1]  USB 3.0 Connectors are different from USB 2.0 connectors - they are usually (but not always) coloured blue on the inside in order to distinguish them from the 2.0 connectors. Check the specifications of your PC.

[2]  Make sure that your USB cable is a data cable (all 4 lines connected) and not just a charging cable. You can test this by copying a file over the cable from the PC to the phone or vice versa.



Have more questions? Submit a request
Powered by Zendesk