I have a Nexus 4 that was soft bricked during an OTA update. I have tried to flash several factory images to it and every time it gave me the error "FAILED (data transfer failure (Value too large for defined data type))". When I tried to flash Occam 4.4 it seemed to finish without any problems. Now when I try to boot it up it doesn't get past the Google screen. I have left it on the Google screen for over an hour and tried wiping the cache and factory reseting it but it is still stuck on the Google screen. Also I tried to flash Occam 4.4 again but the same error displayed when I tried. The bootloader on the phone is unlocked. Can anyone help me either with getting past the Google screen or re-installing Occam on it? I run Windows 7 and Ubuntu 16.04

Note USB De-bugging is not activated

2 Answers 2


Regarding the message FAILED (data transfer failure (Value too large for defined data type)), in my case the issue was resolved using another USB cable (first one was from a Samsung Galaxy tablet, second one from a Nexus 7 tablet)

  • I ended up switching computers which solved the problem. Sep 16, 2016 at 16:17

I was using adb from an Armv7 device and trying to sideload a ROM, where I got this error (adb sideload ROM).

Frustrated, I tried pushing the ROM (adb push ROM and make sure the phone is NOT in the sideload state) and got the exact same error.

This turned out to be the fault of the USB driver, and was nothing to do with adb nor the ROM.

I have heard that USB 2 ports are better for flashing, but my laptop only has USB 3 ports.

So what could I do?

Well, the android shell provided by TWRP contains the cat command. So I split -b 100M <ROM.ext> rom-parts- on my laptop, to split the ROM into several parts, and then did adb push rom-parts-* /sdcard/.

This transferred the files fine. I could then do adb shell to get access to the android shell on the device, and then did cat rom-parts-* > <ROM.ext> and then verified it was the same file by doing an md5sum or sha256sum and comparing with the original file online.

In TWRP I was then able to install the image easily.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .