1. Check out our app, Forums for Android! Download and leave feedback here!

When I try to flash via fastboot system.img to YU Yuphoria I get the FAILED (remote: flash write

Discussion in 'Android Rooting' started by atulsam, Sep 10, 2016.

  1. atulsam

    atulsam Member
    Thread Starter
    16

    Sep 10, 2016
    10
    8
    16
    Male
    C:\Users\SAM\Desktop\New folder\Yu_Yuphoria_YU5010_V2_V2_12.10.12\Firmware>fastboot -i 0x2A96 flash system system.img
    target reported max download size of 268435456 bytes
    erasing 'system'...
    OKAY [ 0.018s]
    sending sparse 'system' 1/4 (261218 KB)...
    OKAY [ 8.737s]
    writing 'system' 1/4...
    ***FAILED (remote: flash write failure)***
    finished. total time: 9.167s
     

    Advertisement

    nazry idris likes this.
  2. scary alien

    scary alien not really so scary
    Moderator
    2,138

    Mar 5, 2010
    22,053
    23,001
    2,138
    Male
    space alien ;)
    Indy
    Is your bootloader unlocked?

    I've seen that write failure (or similar) for three different circumstances:

    1. Locked bootloader
    2. Hardware issue (normal failure due to long-term use)
    3. Hardware issue (known failure due to water exposure--although the write failures were (are) intermittent)

    Your output does seem to indicate a partial write (flash) operation started to work, but that's not conclusive.

    If your bootloader is unlocked (verify with fastboot getvar unlocked command, should output "unlocked: yes" if unlocked), then other than retrying the flashing operation, not sure what to tell you...:(

    If your bootloader is locked, then you'll obviously have to unlock it first, eh? :)
     
    iowabowtech likes this.
  3. atulsam

    atulsam Member
    Thread Starter
    16

    Sep 10, 2016
    10
    8
    16
    Male
    Thanks for your reply,
    I executed fastboot -i 0x2A96 oem unlock before flashing.
    I also checked fastboot getvar unlocked so result is following
    >fastboot getvar unlocked
    unlocked:
    finished. total time: 0.002s

    And one more thing when I flashed cache , userdata , recovery , boot. It is all fine, there is no error.
    But this error occurs only when i tried to flash system.
    My Phone was stopped working due some decryption error and internal memory is showing as 0Mb in TWRP.
    I had followed my threads but no luck.
     
    scary alien likes this.
  4. scary alien

    scary alien not really so scary
    Moderator
    2,138

    Mar 5, 2010
    22,053
    23,001
    2,138
    Male
    space alien ;)
    Indy
    Can you post the output from a fastboot getvar all command? (and/or fastboot -i 0x2A96 getvar all)

    It's still not clear that your bootloader is actually unlocked given the output that you got from the fastboot getvar unlocked command...you might also need the "-i 0x2A96" USB vendor id option that you used for the unlock command you posted above.

    I don't think it's unusual that you're seeing failures on the system flash operation since that transfers the most data since it's a larger partition.
     
    iowabowtech likes this.
  5. atulsam

    atulsam Member
    Thread Starter
    16

    Sep 10, 2016
    10
    8
    16
    Male

    Attached Files:

    scary alien likes this.
  6. scary alien

    scary alien not really so scary
    Moderator
    2,138

    Mar 5, 2010
    22,053
    23,001
    2,138
    Male
    space alien ;)
    Indy
    Thanks @atulsam--that was perfect!

    Unfortunately, I've seen that (the write/flash errors on /system) before on several Nexus 7 tables (both 2012 and 2013 versions) without any obvious fix :(.

    I've also see it on a Nexus 5 that experienced water damage, but that problem has been intermittent and I've been able to try multiple times and eventually get it to flash--but knowing it's got a problem, I'm not surprised when I encounter issues.

    Is this an older device perhaps that's finally seeing hardware issues? :thinking:
     
    iowabowtech likes this.
  7. atulsam

    atulsam Member
    Thread Starter
    16

    Sep 10, 2016
    10
    8
    16
    Male
    This device is from july 2015, so i can say that not too much old. It does not seems to be hardware issue because boot, recovery, cache , userdata is flashing successfully. But only problem occurs in system.
    Have you gone through the image which i posted earlier. Have you found something unusual.
     
    gustavo Woltmann likes this.
  8. scary alien

    scary alien not really so scary
    Moderator
    2,138

    Mar 5, 2010
    22,053
    23,001
    2,138
    Male
    space alien ;)
    Indy
    Well, eMMC memory errors or failures can happen anywhere and just because one operation is successful (like the cache flashing of only 5MB of data) doesn't mean that you won't or couldn't see that error in another place.

    You're also trying to flash 255MB of data for your 'system' flashing operation--a much larger amount that encompasses more area and possibilities to encounter a bad area of memory.

    The "FAILED" message is pretty clear: "flash write failure", so it's either a still locked bootloader issue or a hardware issue from my standpoint and understanding...:(
     
    iowabowtech likes this.
  9. atulsam

    atulsam Member
    Thread Starter
    16

    Sep 10, 2016
    10
    8
    16
    Male
    See this output
    >>fastboot oem device-info
    ...
    (bootloader) Device tampered: false
    (bootloader) Device unlocked: true
    (bootloader) Charger screen enabled: true
    (bootloader) Display panel:
    OKAY [ 0.007s]
    finished. total time: 0.007s

    I think the device is unlocked.
    Anyway thanks to you. I am still looking for the solution. If I got the solution I'll get back to you.
     
    #9 atulsam, Sep 11, 2016
    Last edited: Sep 11, 2016
    scary alien likes this.
  10. gustavo Woltmann

    gustavo Woltmann New Member
    5

    Sep 11, 2016
    2
    0
    5
    Male
    Make sure your bootloader is unlocked
     
  11. scary alien

    scary alien not really so scary
    Moderator
    2,138

    Mar 5, 2010
    22,053
    23,001
    2,138
    Male
    space alien ;)
    Indy
    Yeah, that's been discussed multiple times here...and the OP just confirmed in his last/most recent post that his bootloader is unlocked.
     
  12. iowabowtech

    iowabowtech root@android:/ #
    1,493

    May 2, 2010
    12,169
    8,667
    1,493
    Making the Establishment nervous
    Iowa|USA
    I've run across this as well on other devices. Seems to be a fastboot limitation due to the large size of system on some devices as @scary alien mentioned already. Make sure you're updated to the most recent fastboot binary as older ones have this problem way more frequently. If you're not up to date, that's step one, then retry.

    If you're on the newest and it still doesn't work, I'd recommend rooting if you're not already, get your partition table or better yet, locate your path to the system partition in the format of dev/block/xxx/xxx/by-name and then use the dd utility to write system via adb root shell. It seems to power through large write functions better than fastboot. I've had success using that method in lieu of a fastboot when incurring the same error as yourself.
     
    atulsam and scary alien like this.
  13. Jfalls63

    Jfalls63 Well-Known Member
    818

    May 15, 2015
    3,258
    2,257
    818
    Male
    Electrician
    Satsuma,Alabama
    Granted that I'm new to fastboot devices, I have been learning/ flashing a few Motorola devices.
    Found and have been using mfastboot. Supposedly mfastboot will flash much larger system files than standard fastboot.
    Not sure if this is the problem but couldn't hurt to try.
     
    iowabowtech and scary alien like this.
  14. scary alien

    scary alien not really so scary
    Moderator
    2,138

    Mar 5, 2010
    22,053
    23,001
    2,138
    Male
    space alien ;)
    Indy
    ^^^ Oooh, great idea guys!

    Thank you! :)
     
    Jfalls63 likes this.
  15. atulsam

    atulsam Member
    Thread Starter
    16

    Sep 10, 2016
    10
    8
    16
    Male
    Thanks for your advice. Actually, my system file size is approximately 1 Gb. So think this error is due to max size . and the max size of fastboot 256 MB . can you pls tell me how to increase max size of fastboot.
     
  16. scary alien

    scary alien not really so scary
    Moderator
    2,138

    Mar 5, 2010
    22,053
    23,001
    2,138
    Male
    space alien ;)
    Indy
    What makes you think that the max (file?) size for fastboot is 256 MB?
     
  17. atulsam

    atulsam Member
    Thread Starter
    16

    Sep 10, 2016
    10
    8
    16
    Male
    I read some threads where it was mentioned that by default max size is 256 MB to flash. But my system image is around 1GB so maybe that's why am getting the error. Can you suggest another method to flash system.img file.
    when i execute this command.
    >fastboot -S 1024M flash system system.img
    erasing 'system'...
    OKAY [ 0.848s]
    sending 'system' (1027359 KB)...
    FAILED (remote: data too large)
    finished. total time: 1.608s

    This data too large error is showing. So what may be the problem.
     
    #17 atulsam, Sep 17, 2016
    Last edited: Sep 17, 2016
  18. atulsam

    atulsam Member
    Thread Starter
    16

    Sep 10, 2016
    10
    8
    16
    Male
    Thanks for your suggestion. I also tried mfastboot but no luck. My system.img is 1GB in size.
     
  19. scary alien

    scary alien not really so scary
    Moderator
    2,138

    Mar 5, 2010
    22,053
    23,001
    2,138
    Male
    space alien ;)
    Indy
    Ah, I have seen that one before (and I don't think you had mentioned a size issue w/regard to that message)...

    I did (finally!) find a version of the fastboot source that actually contains that error "FAILED (remote: data too large)" message:


    and found a site that suggests download the latest version of fastboot.exe from the Android SDK, which I've done and attached to this post (it's inside the .zip file since we can't post .exe files directly here)

    The size of the system.img file that you posted in the first post was 261218 KB, so perhaps you should be specifying the "-S 2048M" size option/argument to fastboot instead of "-S 1028M"?

    Try both that and the new fastboot that I've attached and let us know.

    Cheers!
     

    Attached Files:

    Jfalls63 likes this.
  20. manthanshah16

    manthanshah16 New Member
    5

    Sep 24, 2016
    1
    0
    5
    Male
    Bangalore
    exactly issue i'm facing and tried all above but no help.. someone please help :(
     
  21. scary alien

    scary alien not really so scary
    Moderator
    2,138

    Mar 5, 2010
    22,053
    23,001
    2,138
    Male
    space alien ;)
    Indy
    @atulsam, just revisiting this real quick:

    A "fastboot getvar all" or "fastboot getvar max-download-size" should reveal the maximum size that your device can handle in a given transfer.

    My advice above to try a larger value appears to be opposite of what you'd actually want to do--trying a smaller size should give fastboot more of a chance to transfer the file in palatable chunks, so trying a size like fastboot -S 512M flash system system.img would have more of a chance of being successful.

    @manthanshah16, see if thise helps you, too.

    Cheers!
     
    Jfalls63 likes this.
  22. Mani Sankar

    Mani Sankar New Member
    5

    Jan 2, 2017
    1
    0
    5
    @atulsam I am also facing the same issue. Have you found out the solution?
     
  23. samujjwal kashyap

    samujjwal kashyap New Member
    16

    Feb 10, 2017
    3
    2
    16
    Male
    @atulsam @scary alien I am also experiencing the same issue on my YUPHORIA 5010 device. TWRP 3.0.2.0 is loaded on the device and that shows 0 MB internal storage. Unable to mount system, data, cache partitions....says invalid arguments. No fastboot mode. My understanding is when there is no internal memory or the system partition detected, where would it flash the system.img file. Is there a utility that we could use to recover the internal memory first? If we can get to mount the partitions, the default commands will flash the system.img as well.

    Please help.
     
  24. scary alien

    scary alien not really so scary
    Moderator
    2,138

    Mar 5, 2010
    22,053
    23,001
    2,138
    Male
    space alien ;)
    Indy
    Welcome to AF, @samujjwal kashyap -- sorry to hear you're also have similar issues to the guys above...:(

    I'm not sure what else or more I can add, since I don't actually have this device--I was just chiming-in with some generic fastboot information that I thought might be helpful.

    Hopefully one of the others will reply back! :)
     
    samujjwal kashyap likes this.
  25. atulsam

    atulsam Member
    Thread Starter
    16

    Sep 10, 2016
    10
    8
    16
    Male
    I didn't find any solution, Service center replaced motherboard. They said it is hardware issue.
     

Share This Page

Loading...