answered
2019-02-10 02:00:38 +0200
It is not an answer, but too long for a comment, sorry.
I am also having a rough ride (starting with a borked USB-C cable…)
On Antergos (Arch based) I was not able to unlock the boot loader, no matter whether I used USB 2 or 3 or 3 in 2 mode.
FAILED (command write failed (Success))
finished. total time: 0.000s
Guessing it was too new software versions (Sony says somewhere platfrom-tools 26.0.2 and older would work) I tried it with a recent KDE Neon live session, which is based on Ubuntu 18.04.
With this unlocking somehow worked, but not smoothly. Instead of having a nice OK, fastboot hung. After disconnect the device I was presented with the "XA2 bootloader is unlocked screen", so it seems successful. Flashing failed however:
$ sudo bash flash.sh
Detected Linux
Searching device to flash..
Found 1 devices: CQ3000U5VE
Fastboot command: fastboot -s CQ3000U5VE
Flashing boot_a partition..
target didn't report max-download-size
sending 'boot_a' (17764 KB)...
FAILED (remote: Requested download size is more than max allowed
)
finished. total time: 0.001s
was all i got. Since someone reported it working on Ubuntu 18.10, I created another live usb stick with that and tried again. It failed differently:
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.
I looked into the flash.sh script a bit, and spotted the line that leads to this output. Essentially it is
sudo fastboot -s $SERIALNO getvar product 2>&1
So it tried this to see what it retrieves. And to my surprise it is different with each call:
ubuntu@ubuntu:~$ sudo fastboot -s CQ3000U5VE getvar product 2>&1
getvar:product FAILED (remote: unknown command)
finished. total time: 0.000s
ubuntu@ubuntu:~$ sudo fastboot -s CQ3000U5VE getvar product 2>&1
getvar:product FAILED (remote: GetVar Variable Not found)
finished. total time: 0.000s
ubuntu@ubuntu:~$ sudo fastboot -s CQ3000U5VE getvar product 2>&1
getvar:product FAILED (remote: GetVar Variable Not found)
finished. total time: 0.001s
ubuntu@ubuntu:~$ sudo fastboot -s CQ3000U5VE getvar product 2>&1
getvar:product FAILED (remote: unknown command)
finished. total time: 0.000s
ubuntu@ubuntu:~$ sudo fastboot -s CQ3000U5VE getvar product 2>&1
getvar:product FAILED (remote: GetVar Variable Not found)
finished. total time: 0.000s
ubuntu@ubuntu:~$ sudo fastboot -s CQ3000U5VE getvar product 2>&1
product: H3113
finished. total time: 0.000s
That's already very suspicious. And something seems to be odd. Now my guess is, trying it often enough, this step would be taken and maybe flashing gets started. It turns out, every fifth execution of the script indeed gets beyond this point, alas always ending up with:
Detected Linux
Searching device to flash..
Found 1 devices: CQ3000U5VE
Fastboot command: fastboot -s CQ3000U5VE
Flashing boot_a partition..
target didn't report max-download-size
Sending 'boot_a' (17764 KB)...
And getting stuck there (until disconnecting the phone). In journalctl I'll find:
Feb 09 22:33:23 ubuntu kernel: INFO: task fastboot:7346 blocked for more than 120 seconds.
Feb 09 22:33:23 ubuntu kernel: Not tainted 4.18.0-10-generic #11-Ubuntu
Feb 09 22:33:23 ubuntu kernel: "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
Feb 09 22:33:23 ubuntu kernel: fastboot D 0 7346 7321 0x00000000
Feb 09 22:33:23 ubuntu kernel: Call Trace:
Feb 09 22:33:23 ubuntu kernel: __schedule+0x29e/0x840
Feb 09 22:33:23 ubuntu kernel: schedule+0x2c/0x80
Feb 09 22:33:23 ubuntu kernel: schedule_timeout+0x258/0x360
Feb 09 22:33:23 ubuntu kernel: ? __do_page_fault+0x25a/0x4d0
Feb 09 22:33:23 ubuntu kernel: wait_for_completion_timeout+0xac/0x140
Feb 09 22:33:23 ubuntu kernel: ? wake_up_q+0x80/0x80
Feb 09 22:33:23 ubuntu kernel: usb_start_wait_urb+0x8c/0x180
Feb 09 22:33:23 ubuntu kernel: usb_bulk_msg+0xb8/0x170
Feb 09 22:33:23 ubuntu kernel: proc_bulk+0x2a7/0x350
Feb 09 22:33:23 ubuntu kernel: usbdev_do_ioctl+0x763/0x10f0
Feb 09 22:33:23 ubuntu kernel: ? do_mmap+0x38c/0x5a0
Feb 09 22:33:23 ubuntu kernel: usbdev_ioctl+0xe/0x20
Feb 09 22:33:23 ubuntu kernel: do_vfs_ioctl+0xa8/0x620
Feb 09 22:33:23 ubuntu kernel: ksys_ioctl+0x67/0x90
Feb 09 22:33:23 ubuntu kernel: __x64_sys_ioctl+0x1a/0x20
Feb 09 22:33:23 ubuntu kernel: do_syscall_64+0x5a/0x110
Feb 09 22:33:23 ubuntu kernel: entry_SYSCALL_64_after_hwframe+0x44/0xa9
Feb 09 22:33:23 ubuntu kernel: RIP: 0033:0x7fc1ab4673c7
Feb 09 22:33:23 ubuntu kernel: Code: Bad RIP value.
Feb 09 22:33:23 ubuntu kernel: RSP: 002b:00007ffeaed644b8 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
Feb 09 22:33:23 ubuntu kernel: RAX: ffffffffffffffda RBX: 0000000000004000 RCX: 00007fc1ab4673c7
Feb 09 22:33:23 ubuntu kernel: RDX: 00007ffeaed644c0 RSI: 00000000c0185502 RDI: 0000000000000004
Feb 09 22:33:23 ubuntu kernel: RBP: 000000000113d000 R08: 0000000000000003 R09: 0000000000000000
Feb 09 22:33:23 ubuntu kernel: R10: 0000000000000001 R11: 0000000000000246 R12: 000000000001c000
Feb 09 22:33:23 ubuntu kernel: R13: 0000564ae1db0d90 R14: 00007ffeaed644c0 R15: 00007fc1a964f000
Back on Antergos, trying the same, I have the same results (with and without android-udev installed). That's were I am stuck now.
I had same issues on latest Ubuntu. Flashed fine on Win10. I suspect ADB/fastboot issues and/or usb connection settings on XA2.
MyShipMyRulez ( 2018-11-13 21:29:06 +0200 )editHave you checked that your version of fastboot includes the 'set_active' command? It should look like this: $ fastboot --help | grep set_active set_active <slot> Sets the active slot. If slots are</slot>
mlohse ( 2018-11-13 22:02:48 +0200 )editMay I ask where you got the image from? On https://shop.jolla.com/downloads/ I find onyl the images for Sony Xperia X, not XA2.
grueni ( 2018-11-13 22:09:49 +0200 )edit@mlohse please see my updated post above. I guess my fastboot is supported, right?
bomo ( 2018-11-13 22:13:22 +0200 )edit@grueni, I downloaded it from exactly there, but had to buy it first for 0Euro. Then, there are downloads for all different XA2 versions.
bomo ( 2018-11-13 22:14:26 +0200 )edit