heimdall: flash stock system on 32-bit Linux - Galaxy S 4 Q&A, Help & Troubleshooting

I have 32-bin Linux notebook and need to reflash stock.
heimdall can't open large image files on 32-bit OS:
Code:
heimdall flash --SYSTEM ~/tmp/system.img --verbose
ERROR: Failed to open file "/root/tmp/system.img"
I tried to recompile heimdall with "-D_FILE_OFFSET_BITS=64"
Now I got new error:
Code:
Uploading SYSTEM
0%
1%
ERROR: Failed to unpack received packet.
ERROR: Failed to confirm end of file transfer sequence!
ERROR: SYSTEM upload failed!
Then I tried to reduce size of system.img
I removed some packages from system.img
New size of system.img is less 2GB new.
But heimdall still produced the last error
Code:
Uploading SYSTEM
0%
1%
ERROR: Failed to unpack received packet.
ERROR: Failed to confirm end of file transfer sequence!
ERROR: SYSTEM upload failed!
heidmall version is 1.4.0

Related

Flashing failes everytime I try to flash. Rsdlite error included

This was my first time.
I did all what was required.
But when I started the flash through RSD lite after just 1 min it showed me FAIL
It went from 1% to 100% once, and then it showed FAIL
Now when I unplugged the USB and remove the battery and insert it back again it automaticaly goes into bootloader and then I tried to flash again which gave me same result.
This is my phone status.
The screen shows
Code Corrupt
Battery OK
OK to Program
Trasnfer Mode:
USB
This is what the Rsdlite Error log file has.
22:32:29, May 13, 2012
Line: 537
ERROR: AP Die ID: 1140010e560368010000dcff0200
22:32:29, May 13, 2012
Line: 544
ERROR: BP Die ID: 0000000000000000000000000000
22:32:29, May 13, 2012
Line: 551
ERROR: AP Public ID: 785fdd0a961a8e4b1e6a0497d703ee271d20c5c0
22:32:29, May 13, 2012
Line: 558
ERROR: BP Public ID: 0000000000000000000000000000000000000000
22:32:29, May 13, 2012
Line: 709
ERROR: Phone[0000]: Error erasing subscriber unit. Device API Error: 0xE0030040 Command: ERASE
File: D:\GitProjectsReleases\hdt_windows_flash\flash\code\flashdll\ErasingOp.cpp
Device ID: 0
22:32:29, May 13, 2012
Line: 1195
ERROR: Phone[0000]: Flash failed.
File: D:\GitProjectsReleases\hdt_windows_flash\flash\code\flashdll\PST_FP_FlashThread.cpp
Device ID: 0
22:32:29, May 13, 2012
Line: 610
ERROR: Flash failure: Phone[0000]: Error erasing subscriber unit. Device API Error: 0xE0030040 Command: ERASE (Error Code: e0030040),
Detailed Error Details: Direction of the Error=2000, Command Value=100000, Code Group Number=No Codegroup
File: D:\GitProjectsReleases\hdt_windows_flash\flash\code\flashdll\FlashHdlr.cpp
Device ID: 0
Click to expand...
Click to collapse
Please someone reply asap.
use the recommened rsdlite version...i have seen many other version of rsdlite gives such errors..i actually dont remember the exact version ..haven't used it for a while..
do a search in this forum..
All the best
I have read few other places and it said to use RSDLITE 4.9, which I did.
try version 3.4.8 if m not wrong..
Which one do you used for flashing?
i think the above version only..i have recommended the same version to many people and it works like a charm in past..search this forum for rsdlite stable version by experience of people..
I did successfully flash my Defy+ with RSDLite v5.6 (search the forum or google)
Maybe there's something wrong with your sbf-file? Just a wild guess, don't know if the error message tells actually something different...
Thanks for your time guys. I was trying to flash on my Desktop with no avail.
Tried on my lappy and Bingo its all done perfectly.
Happy I have finally upgraded to CM7 its really nice and fast.

Can someone help me?

I have a Lg G2 from verizon and im trying to root it with ioroot20 i watched the video on how to do it enable develper and usb debugging and connect your phone to a pc and for verizon choose ethernet and when i run the root bache file it works for a bit and at the endit says Mounting system, pushing su binary and installing SuperSu.
error: device not found
error: device not found
error: device not found
error: device not found
error: device not found
error: device not found
error: device not found
error: device not found
error: device not found
Rebooting final time.
error: device not found
***************************************************
***************************************************
***************************************************

[Q] Semi-Bricked Device Fix

So, prior to my stupidity, I made a system.img dump via dd
However, after my stupidity (tried flashing some lib files....), I am now stuck with only stock recovery mode, or download mode.
How can I flash back my system.img? I tried in download mode with heimdall... but it fails with
Code:
[email protected]:/media/MediaTwo/MyRom# heimdall flash --verbose --no-reboot --SYSTEM system.img
Heimdall v1.4.0
Copyright (c) 2010-2013, Benjamin Dobell, Glass Echidna
http://www.glassechidna.com.au/
This software is provided free of charge. Copying and redistribution is
encouraged.
If you appreciate this software and you would like to support future
development please consider donating:
http://www.glassechidna.com.au/donate/
Initialising connection...
Detecting device...
Manufacturer: "Sasmsung"
Product: "MSM8960"
length: 18
device class: 2
S/N: 0
VID:PID: 04E8:685D
bcdDevice: 0100
iMan:iProd:iSer: 1:2:0
nb confs: 1
interface[0].altsetting[0]: num endpoints = 1
Class.SubClass.Protocol: 02.02.01
endpoint[0].address: 82
max packet size: 0010
polling interval: 09
interface[1].altsetting[0]: num endpoints = 2
Class.SubClass.Protocol: 0A.00.00
endpoint[0].address: 81
max packet size: 0200
polling interval: 00
endpoint[1].address: 01
max packet size: 0200
polling interval: 00
Claiming interface...
Attempt failed. Detaching driver...
Claiming interface again...
Setting up interface...
Initialising protocol...
WARNING: Control transfer #1 failed. Result: -9
WARNING: Control transfer #2 failed. Result: -9
WARNING: Control transfer #3 failed. Result: -9
WARNING: Control transfer #4 failed. Result: -9
WARNING: Control transfer #5 failed. Result: -9
WARNING: Control transfer #6 failed. Result: -9
ERROR: Failed to receive handshake response. Retrying...
Protocol initialisation successful.
Beginning session...
Some devices may take up to 2 minutes to respond.
Please be patient!
Session begun.
Downloading device's PIT file...
PIT file download successful.
Uploading SYSTEM
0%
1%
ERROR: Failed to unpack received packet.
ERROR: Failed to confirm end of file transfer sequence!
ERROR: SYSTEM upload failed!
Ending session...
Releasing device interface...
Re-attaching kernel driver...
so I tried creating an update.zip that I could sideload flash in stock recovery, but that fails as well with
Code:
E: footer is wrong
E: signature verification failed
If I could get into adb shell, I'd be set... all I'd have to do is dd the system.img back (been there done that in SafeStrap), but when I try adb shell in stock recovery I just get "error: device not found", and in sideload mode, I get "error: closed"
Please help? :crying:
kevp75 said:
So, prior to my stupidity, I made a system.img dump via dd
However, after my stupidity (tried flashing some lib files....), I am now stuck with only stock recovery mode, or download mode.
How can I flash back my system.img? I tried in download mode with heimdall... but it fails with
Code:
[email protected]:/media/MediaTwo/MyRom# heimdall flash --verbose --no-reboot --SYSTEM system.img
Heimdall v1.4.0
Copyright (c) 2010-2013, Benjamin Dobell, Glass Echidna
http://www.glassechidna.com.au/
This software is provided free of charge. Copying and redistribution is
encouraged.
If you appreciate this software and you would like to support future
development please consider donating:
http://www.glassechidna.com.au/donate/
Initialising connection...
Detecting device...
Manufacturer: "Sasmsung"
Product: "MSM8960"
length: 18
device class: 2
S/N: 0
VID:PID: 04E8:685D
bcdDevice: 0100
iMan:iProd:iSer: 1:2:0
nb confs: 1
interface[0].altsetting[0]: num endpoints = 1
Class.SubClass.Protocol: 02.02.01
endpoint[0].address: 82
max packet size: 0010
polling interval: 09
interface[1].altsetting[0]: num endpoints = 2
Class.SubClass.Protocol: 0A.00.00
endpoint[0].address: 81
max packet size: 0200
polling interval: 00
endpoint[1].address: 01
max packet size: 0200
polling interval: 00
Claiming interface...
Attempt failed. Detaching driver...
Claiming interface again...
Setting up interface...
Initialising protocol...
WARNING: Control transfer #1 failed. Result: -9
WARNING: Control transfer #2 failed. Result: -9
WARNING: Control transfer #3 failed. Result: -9
WARNING: Control transfer #4 failed. Result: -9
WARNING: Control transfer #5 failed. Result: -9
WARNING: Control transfer #6 failed. Result: -9
ERROR: Failed to receive handshake response. Retrying...
Protocol initialisation successful.
Beginning session...
Some devices may take up to 2 minutes to respond.
Please be patient!
Session begun.
Downloading device's PIT file...
PIT file download successful.
Uploading SYSTEM
0%
1%
ERROR: Failed to unpack received packet.
ERROR: Failed to confirm end of file transfer sequence!
ERROR: SYSTEM upload failed!
Ending session...
Releasing device interface...
Re-attaching kernel driver...
so I tried creating an update.zip that I could sideload flash in stock recovery, but that fails as well with
Code:
E: footer is wrong
E: signature verification failed
If I could get into adb shell, I'd be set... all I'd have to do is dd the system.img back (been there done that in SafeStrap), but when I try adb shell in stock recovery I just get "error: device not found", and in sideload mode, I get "error: closed"
Please help? :crying:
Click to expand...
Click to collapse
Can't use heimdall or stock recovery because it isn't a signed file and stock recovery doesn't allow adb shell. Your only option is to reflash unless you have Safestrap.
Sent from my SGH-I337 running GPE
DeadlySin9 said:
Can't use heimdall or stock recovery because it isn't a signed file and stock recovery doesn't allow adb shell. Your only option is to reflash unless you have Safestrap.
Sent from my SGH-I337 running GPE
Click to expand...
Click to collapse
I had SafeStrap, but not aymore... only stock recovery and download mode.
Is there a Odin/Heimdall flashable version of SafeStrap floating around somewhere that I have not seen?
kevp75 said:
I had SafeStrap, but not aymore... only stock recovery and download mode.
Is there a Odin/Heimdall flashable version of SafeStrap floating around somewhere that I have not seen?
Click to expand...
Click to collapse
Is it really my only option to go back, Odin flash NB1, upgrade to NC1, install SELinux Mode Changer and SafeStrap, then restore my system.img from within SafeStrap?
I have my data "files" backed up as an image (which I'll need to un-image, because it's too big for my Fat32 SDCard clocking in at 8.7G LOL), but I can adb push those back in as well...
I'm going to end up doing this, but I would like to keep this open in case another solution comes along....
kevp75 said:
Is it really my only option to go back, Odin flash NB1, upgrade to NC1, install SELinux Mode Changer and SafeStrap, then restore my system.img from within SafeStrap?
I have my data "files" backed up as an image (which I'll need to un-image, because it's too big for my Fat32 SDCard clocking in at 8.7G LOL), but I can adb push those back in as well...
I'm going to end up doing this, but I would like to keep this open in case another solution comes along....
Click to expand...
Click to collapse
unfortunately I had to odin back... but up and running
Rockin' it from my Smartly GoldenEye 35 NF1 (muchas gracias:* @iB4STiD @loganfarrell @muniz_ri @Venom0642 @ted77usa @rebel1699* @iB4STiD) ~ 20GB free cloud https://copy.com?r=vtiraF
Check me out online @ http://kevin.pirnie.us
Yes I know to reflash but having reflashed for 10+ times and being returned the similar errors, these errors are probably the USB hw problems, and not likely to be phones-sided. The root solution is to renew the USB tethers, even the Macs.
DeadlySin9 said:
Can't use heimdall or stock recovery because it isn't a signed file and stock recovery doesn't allow adb shell. Your only option is to reflash unless you have Safestrap.
Click to expand...
Click to collapse

[Q] TWRP flashable ZIP for VS980 failed to flash under TWRP

This seems to be an old problem.
My VS980 is on TWRP v2.8.0.1, and I see there is a newer TWRP from the official site: openrecovery-twrp-2.8.1.0-vs980.zip
So I downloaded that and put it on sdcard, by "installing" this zip, the error was as follows:
Code:
Installing '/usb_otg/ROM/openrecovery-twrp-2.8.1.0-vs980.zip'...
Checking for MD5 file...
MD5 matched
I:Zip does not contain SELinux file_contexts file in its root.
I:Legacy property environment initialized.
*******************************
* TWRP Recovery by Dees_Troy *
*******************************
minzip: Extracted file "/tmp/loki.sh"
minzip: Extracted file "/tmp/loki/loki_flash"
minzip: Extracted file "/tmp/loki/loki_patch"
about to run program [/tmp/loki.sh] with 1 args
2048+0 records in
2048+0 records out
1048576 bytes (1.0MB) copied, 0.033627 seconds, 29.7MB/s
[+] loki_patch v2.1
[-] Unsupported aboot image.
run_program: child exited with status 1
script aborted: assert failed: run_program("/tmp/loki.sh") == 0
assert failed: run_program("/tmp/loki.sh") == 0
Is it because my aboot is already lokified? Or am I doing the upgrade wrong?

Building Android 5.1.1 from source - Compile error

Hi guys, I don't know if this is the correct section for this, of not then feel free to move it.
I'm trying to build Android 5.1.1_r38 from source on a Intel i5 mechine running Ubuntu 16.04.
After about an hour running, If gives me the following errors
Code:
external/chromium_org/third_party/yasm/source/patched-yasm/tools/genmacro/genmacro.c:90: error: unsupported reloc 43
external/chromium_org/third_party/yasm/source/patched-yasm/tools/genmacro/genmacro.c:48: error: unsupported reloc 43
external/chromium_org/third_party/yasm/source/patched-yasm/tools/genmacro/genmacro.c:55: error: unsupported reloc 43
external/chromium_org/third_party/yasm/source/patched-yasm/tools/genmacro/genmacro.c:68: error: unsupported reloc 43
clang: error: linker command failed with exit code 1 (use -v to see invocation)
build/core/host_executable_internal.mk:31: recipe for target 'out/host/linux-x86/obj32/EXECUTABLES/third_party_yasm_genmacro_x86_host_gyp_intermediates/genmacro' failed
make: *** [out/host/linux-x86/obj32/EXECUTABLES/third_party_yasm_genmacro_x86_host_gyp_intermediates/genmacro] Error 1
make: *** Waiting for unfinished jobs....
prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.11-4.6//x86_64-linux/bin/ld: error: out/host/linux-x86/obj32/EXECUTABLES/third_party_yasm_genmodule_x86_host_gyp_intermediates/third_party/yasm/source/patched-yasm/libyasm/genmodule.o: unsupported reloc 43 against global symbol stderr
prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.11-4.6//x86_64-linux/bin/ld: error: out/host/linux-x86/obj32/EXECUTABLES/third_party_yasm_genmodule_x86_host_gyp_intermediates/third_party/yasm/source/patched-yasm/libyasm/genmodule.o: unsupported reloc 43 against global symbol stderr
prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.11-4.6//x86_64-linux/bin/ld: error: out/host/linux-x86/obj32/EXECUTABLES/third_party_yasm_genmodule_x86_host_gyp_intermediates/third_party/yasm/source/patched-yasm/libyasm/genmodule.o: unsupported reloc 43 against global symbol stderr
prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.11-4.6//x86_64-linux/bin/ld: error: out/host/linux-x86/obj32/EXECUTABLES/third_party_yasm_genmodule_x86_host_gyp_intermediates/third_party/yasm/source/patched-yasm/libyasm/genmodule.o: unsupported reloc 43 against global symbol stderr
external/chromium_org/third_party/yasm/source/patched-yasm/libyasm/genmodule.c:87: error: unsupported reloc 43
external/chromium_org/third_party/yasm/source/patched-yasm/libyasm/genmodule.c:63: error: unsupported reloc 43
external/chromium_org/third_party/yasm/source/patched-yasm/libyasm/genmodule.c:174: error: unsupported reloc 43
external/chromium_org/third_party/yasm/source/patched-yasm/libyasm/genmodule.c:183: error: unsupported reloc 43
host StaticLib: third_party_yasm_genperf_libs_x86_host_gyp_32 (out/host/linux-x86/obj32/STATIC_LIBRARIES/third_party_yasm_genperf_libs_x86_host_gyp_intermediates/third_party_yasm_genperf_libs_x86_host_gyp.a)
clang: error: linker command failed with exit code 1 (use -v to see invocation)
build/core/host_executable_internal.mk:31: recipe for target 'out/host/linux-x86/obj32/EXECUTABLES/third_party_yasm_genmodule_x86_host_gyp_intermediates/genmodule' failed
make: *** [out/host/linux-x86/obj32/EXECUTABLES/third_party_yasm_genmodule_x86_host_gyp_intermediates/genmodule] Error 1
I've run apt-get update and make clobber and anything else I can think of (note: I'm quite new to ubuntu)
If you need any more info, just feel free to ask, as I'm not sure what you need to help me.
Thanks in advance.

Categories

Resources