Somebody got a boot.img file from the X2? I don't even know if it's possible yet.
Thanks
Yes when you do a nandroid backup it will make a boot.img file. Look at your sdcard location in the folder where you make your backups.
magneticzero said:
Yes when you do a nandroid backup it will make a boot.img file. Look at your sdcard location in the folder where you make your backups.
Click to expand...
Click to collapse
I've made multiple backups and that's the first place I looked since system.img is there. Maybe I'm just dumb lol. If anyone can provide one, please pm me
Sent from my DROID X2 using XDA App
jconner05 said:
Somebody got a boot.img file from the X2? I don't even know if it's possible yet.
Thanks
Click to expand...
Click to collapse
I tried posting this earlier...
I'M NOT 100% SURE THIS IS THE CORRECT WAY
I think that the X2's partition layout is the same as the atrix. That being said, boot.img is in /dev/block/mmcblk0p10 and recovery.img is in /dev/block/mmcblk0p11.
Using split_bootimg.pl I managed to get an un-corrupt ramdisk from both and a supposed kernel from them too, but from what I read this script doesn't extract the actual kernel due to some corruption from using dd.
THIS MIGHT NOT BE CORRECT
Here is what I did on Ubuntu (windows should work too):
adb shell
$ su
# dd if=/dev/block/mmcblk0p10 of=/mnt/sdcard-ext/boot.img
# dd if=/dev/block/mmcblk0p11 of=/mnt/sdcard-ext/recovery.img
# exit
$ exit
adb pull /mnt/sdcard-ext/boot.img /YOUR/DIRECTORY
adb pull /mnt/sdcard-ext/recovery.img /YOUR/DIRECTORY
cd /YOUR/DIRECTORY
perl ./split_bootimg.pl boot.img
perl ./split_bootimg.pl recovery.img
You should now have a ramdisk for both that can be mounted in Ubuntu and explored and a supposed kernel, but I think it's corrupt like I said.
IFI AM INCORRECT, SOMEONE SAY THE CORRECT ANSWER
I'd like to know too
Hope I helped.
Sent from my DROID X2 using XDA App
Yeah you're right, there isnt a boot.img made...my bad
dragonzkiller said:
I tried posting this earlier...
I'M NOT 100% SURE THIS IS THE CORRECT WAY
I think that the X2's partition layout is the same as the atrix. That being said, boot.img is in /dev/block/mmcblk0p10 and recovery.img is in /dev/block/mmcblk0p11.
Using split_bootimg.pl I managed to get an un-corrupt ramdisk from both and a supposed kernel from them too, but from what I read this script doesn't extract the actual kernel due to some corruption from using dd.
THIS MIGHT NOT BE CORRECT
Here is what I did on Ubuntu (windows should work too):
adb shell
# su
$ dd if=/dev/block/mmcblk0p10 of=/mnt/sdcard-ext/boot.img
$ dd if=/dev/block/mmcblk0p11 of=/mnt/sdcard-ext/recovery.img
$ exit
# exit
adb pull /mnt/sdcard-ext/boot.img /YOUR/DIRECTORY
adb pull /mnt/sdcard-ext/recovery.img /YOUR/DIRECTORY
cd /YOUR/DIRECTORY
perl ./split_bootimg.pl boot.img
perl ./split_bootimg.pl recovery.img
You should now have a ramdisk for both that can be mounted in Ubuntu and explored and a supposed kernel, but I think it's corrupt like I said.
IFI AM INCORRECT, SOMEONE SAY THE CORRECT ANSWER
I'd like to know too
Hope I helped.
Sent from my DROID X2 using XDA App
Click to expand...
Click to collapse
Thanks! I'm at work, but will try this when I get home!
Sent from my DROID X2 using XDA App
Guys, I wouldn't go screwing with the boot.img on the X2. It has a locked bootloader, just like the X and Droid 2. You're going to have to SBF.
Moved to proper forum.
Jewremy said:
Guys, I wouldn't go screwing with the boot.img on the X2. It has a locked bootloader, just like the X and Droid 2. You're going to have to SBF.
Click to expand...
Click to collapse
Yea, I understand. We won't get anywhere if no one tries, though. I'm willing to take the risk.
Sent from my DROID X2 using XDA App
It is a locked bootloader, and the boot.img is also in the sbf that you already have. This is where I got the init.rc out of the ramdisk from for 2nd-init.
edgan said:
It is a locked bootloader, and the boot.img is also in the sbf that you already have. This is where I got the init.rc out of the ramdisk from for 2nd-init.
Click to expand...
Click to collapse
Hmm... Interesting. I'll take a look when I get home from work.
Sent from my DROID X2 using XDA App
edgan said:
It is a locked bootloader, and the boot.img is also in the sbf that you already have. This is where I got the init.rc out of the ramdisk from for 2nd-init.
Click to expand...
Click to collapse
True. But an SBF is hard to work with. I did get the kernel commands from it though. Surprisingly there's not that many.
Sent from my DROID X2 using XDA App
dragonzkiller said:
I tried posting this earlier...
I'M NOT 100% SURE THIS IS THE CORRECT WAY
I think that the X2's partition layout is the same as the atrix. That being said, boot.img is in /dev/block/mmcblk0p10 and recovery.img is in /dev/block/mmcblk0p11.
Using split_bootimg.pl I managed to get an un-corrupt ramdisk from both and a supposed kernel from them too, but from what I read this script doesn't extract the actual kernel due to some corruption from using dd.
THIS MIGHT NOT BE CORRECT
Here is what I did on Ubuntu (windows should work too):
adb shell
$ su
# dd if=/dev/block/mmcblk0p10 of=/mnt/sdcard-ext/boot.img
# dd if=/dev/block/mmcblk0p11 of=/mnt/sdcard-ext/recovery.img
# exit
$ exit
adb pull /mnt/sdcard-ext/boot.img /YOUR/DIRECTORY
adb pull /mnt/sdcard-ext/recovery.img /YOUR/DIRECTORY
cd /YOUR/DIRECTORY
perl ./split_bootimg.pl boot.img
perl ./split_bootimg.pl recovery.img
You should now have a ramdisk for both that can be mounted in Ubuntu and explored and a supposed kernel, but I think it's corrupt like I said.
IFI AM INCORRECT, SOMEONE SAY THE CORRECT ANSWER
I'd like to know too
Hope I helped.
Sent from my DROID X2 using XDA App
Click to expand...
Click to collapse
I managed to pull of a file that looks like it may be a boot.img. I'm going to work with it some and see. Thanks for the help!!
Related
It is a wise idea to backup the /pds partition of your Atrix. It is /dev/block/mmcblk0p3. It holds very important information unique to the phone, like the wifi and bluetooth mac addresses. We still don't fully understand it, but it can resolve issues with the touchscreen not taking input properly. This has happened to a number of people, and now that everyone can have the unlock, I am sure people will do things that will cause the same problem.
Steps:
1. Pick your favorite method: adb, ssh, terminal emulator, etc
2. Become root if not already, REQUIRED
3. dd if=/dev/block/mmcblk0p3 of=/tmp/pds.img
4. Pick your favorite method to get the file off the phone: scp, sd card, etc
The file should be about 2mb. Keep it in a safe place.
edgan said:
It is a wise idea to backup the /pds partition of your Atrix. It is /dev/block/mmcblk0p3. It holds very important information unique to the phone. We still don't fully understand it, but it can resolve issues with the touchscreen not taking input properly. This has happened to a number of people, and now that everyone can have the unlock, I am sure people will do things that will cause the same problem.
Steps:
1. Pick your favorite method: adb, ssh, terminal emulator, etc
2. Become root if not already, REQUIRED
3. dd if=/dev/block/mmcblk0p3 of=/tmp/pds.img
4. Pick your favorite method to get the file off the phone: scp, sd card, etc
The file should be about 2mb. Keep it in a safe place.
Click to expand...
Click to collapse
Everyone can't have the Unlock... Bell is denied for now.
This is sweet though. Thanks for the tip.
Can Root Explorer be used to do this?
no pds is mounted but root exp sees an empty partition, btw would be possible to know which files exactly are in the directory?
me and others messed up this partition using tenfar's recovery, now we have problem with temp throttling, i guess (cpu reaches only 50% of max freq)
Once you go through steps 1 to 3, you can go to /tmp in root explorer and copy pds.img file to sdcard or wherever you want to copy the pds file
Uhhh, is this still possible to back up after unlocking and flashing the 2.3.4 build?
Sent from my MB860 using XDA App
neer2005 said:
Uhhh, is this still possible to back up after unlocking and I flashing the 2.3.4 build?
Sent from my MB860 using XDA App
Click to expand...
Click to collapse
I don't see any reason why you wouldn't be able to.
Screwed up my PDS on my old Atrix. Made sure to immediately back mine up when I got a new one too lol
Backed up the pds file to my ext-sd card using adb shell and got a 2.00mb file. Is this right?
Thanks for the info!
yes
now share it
Thanks I just make a backup image... but how do you restore it?
dd if=/tmp/pds.img of=/dev/block/mmcblk0p3
edgan said:
It is a wise idea to backup the /pds partition of your Atrix. It is /dev/block/mmcblk0p3. It holds very important information unique to the phone. We still don't fully understand it, but it can resolve issues with the touchscreen not taking input properly. This has happened to a number of people, and now that everyone can have the unlock, I am sure people will do things that will cause the same problem.
Steps:
1. Pick your favorite method: adb, ssh, terminal emulator, etc
2. Become root if not already, REQUIRED
3. dd if=/dev/block/mmcblk0p3 of=/tmp/pds.img
4. Pick your favorite method to get the file off the phone: scp, sd card, etc
The file should be about 2mb. Keep it in a safe place.
Click to expand...
Click to collapse
i cant seem to find the file once i created it!
ok, seems simple enough, but stupid question... can someone explain the commands "dd=" and "of=".
I was able to see the file @ dev/block with winscp but how do I convert it to a .img file, etc.
Thanks for your help.
samcripp said:
i cant seem to find the file once i created it!
Click to expand...
Click to collapse
It's in /tmp.
I suggest people use this command:
*MicroSD Installed*
dd if=/dev/block/mmcblk0p3 of=/sdcard-ext/pds.img
*No MicroSD Installed*
dd if=/dev/block/mmcblk0p3 of=/sdcard/pds.img
These commands will create the pds.img file in the root directory of your MicroSD or your Internal SD card respectively.
What is pdf partition?
I believe and if I am wrong I am sure someone will correct me but
dd = I'm not sure
if = input file
of = output file
dd essentially takes a disk and copies it.
Sent from my MB860 using Tapatalk
Not to sound newbish, but I am, I keep getting Cannot Open for Read: Permission Denied
Could someone assist? Thanks.
Realized:
SU is what I needed to type, methinks...will try.
Worked:
Yeah, once I put SU and got that done, it worked out.
_Dennis_ said:
I believe and if I am wrong I am sure someone will correct me but
dd = I'm not sure
if = input file
of = output file
dd essentially takes a disk and copies it.
Sent from my MB860 using Tapatalk
Click to expand...
Click to collapse
From Wikipedia: "dd is a common Unix program whose primary purpose is the low-level copying and conversion of raw data............. dd can also be used to copy regions of raw device files, e.g. backing up the boot sector of a hard disk, or to read fixed amounts of data from special files like /dev/zero or /dev/random.[4]"
So, I am a n00b on using adb (etc..) so I will explain the way I did it using adb.
1. Make sure you have adb.exe installed on your computer and connect the phone to the computer. (I got my adb.exe from the Gladroot script. Here is a link: http://goo.gl/jHiJc)
2. Open a command window
3. Browse to the directory where the adb.exe is and type the following (press enter after each line):
adb shell
su
dd if=/dev/block/mmcblk0p3 of=/sdcard-ext/pds.img
Now, if you DON'T have a SDcard in your phone, take out the "-ext" from that last line.
The file (pds.img) should now be in either the internal sdcard or on your physical sdcard, as nexxusty described.
I hope that helps some as it took me a while to learn this.
Sorry if this is too noob for some, but I started from zero knowledge of this
garekinokami said:
Not to sound newbish, but I am, I keep getting Cannot Open for Read: Permission Denied
Could someone assist? Thanks.
Click to expand...
Click to collapse
Only thing I can think of is if you didn't give ADB superuser permission. You have to physically click allow on the phone after you type "su". Could that be it?
wirednix said:
Only thing I can think of is if you didn't give ADB superuser permission. You have to physically click allow on the phone after you type "su". Could that be it?
Click to expand...
Click to collapse
Lol Yes. 10 Char.
Aye I know what it IS....not what dd MEANS lol. Thank you for the guide.....I completed this in terminal emulator.
This basically (for right now) the stock kernel image with some tweaks to init.
-unsecure boot.img-(perma- rooted adb shell)
-adb remount(mount /system r/w)
-init.d support added in for init scripts(survive after reboot)
-ext4 filesystem mount tweaks-/system/data/cache(faster I/O)
(Actually have a full ext2 version for,****s and giggles, but it boots into the encryption error screen, so cant release that. May have a fix though)
-mem and cache tweaks coming soon
still working on the actual kernel, will release that next, still have lots of work to do
boot.img MD5- fca41dba8f4699b67fd461a1632b65cf
MAKE BACKUP FIRST
You will not have issues if you wipe data, chances are youll be fine if you dont, but if anything starts acting up just wipe data, then install boot.img
This is the actual boot.img and for now has to be flashed with adb with these EXACT commands--
Code:
adb push boot.img /sdcard/
adb shell
su
dd if=/sdcard/boot.img of=/dev/block/mmcblk0 seek=3968 bs=4096 count=2048
reboot
#Thanks Diamondback and friends for offsets
This is not the ideal way to flash this, but i can not get the blob file to staging partition to actually write the image. Im pretty sure its an issue with the signature of the blob file, so if someone wants to pack this into a blob id be glad test it and then update the OP.
My primes been using this boot.img for a few days, along with one other. Flash at your own risk.
NOT COMPATIBLE WITH CM-9
di11igaf said:
This basically (for right now) the stock kernel image with some tweaks to init.
-unsecure boot.img-(perma- rooted adb shell)
-adb remount(mount /system r/w)
-init.d support added in for init scripts(survive after reboot)
-ext4 filesystem mount tweaks-/system/data/cache(faster I/O)
(Actually have a full ext2 version for,****s and giggles, but it boots into the encryption error screen, so cant release that. May have a fix though)
-mem and cache tweaks coming soon
still working on the actual kernel, will release that next, still have lots of work to do
boot.img MD5- fca41dba8f4699b67fd461a1632b65cf
MAKE BACKUP FIRST
You will not have issues if you wipe data, chances are youll be fine if you dont, but if anything starts acting up just wipe data, then install boot.img
This is the actual boot.img and for now has to be flashed with adb with these EXACT commands--
Code:
adb push boot.img /sdcard/
adb shell
su
dd if=/sdcard/boot.img of=/dev/block/mmcblk0 seek=3968 bs=4096 count=2048
reboot
#Thanks Diamondback and friends for offsets
This is not the ideal way to flash this, but i can not get the blob file to staging partition to actually write the image. Im pretty sure its an issue with the signature of the blob file, so if someone wants to pack this into a blob id be glad test it and then update the OP.
My primes been using this boot.img for a few days, along with one other. Flash at your own risk.
Click to expand...
Click to collapse
Great! I'm not the only one who as this problem. For what ever reason I too cannot get the blob to write.
I've tried running the blobpack -s to sign the blob but after trying to write it to the staging partition its a no go.....
EDIT: how are you working on the kernel if it has not been released yet?? JW, not trying to say your not but it would be cool if someone found a way to edit a compiled kernel.
MasterZen88 said:
Great! I'm not the only one who as this problem. For what ever reason I too cannot get the blob to write.
I've tried running the blobpack -s to sign the blob but after trying to write it to the staging partition its a no go.....
EDIT: how are you working on the kernel if it has not been released yet?? JW, not trying to say your not but it would be cool if someone found a way to edit a compiled kernel.
Click to expand...
Click to collapse
ICS kernel source is on the global download site.
Doktaphex said:
ICS kernel source is on the global download site.
Click to expand...
Click to collapse
Correct but thats an older source code V9.4.2.7 right?
MasterZen88 said:
Correct but thats an older source code V9.4.2.7 right?
Click to expand...
Click to collapse
True, I don't know how much they have changed since then. Surely they need to be releasing new source pretty quickly to be in compliance with the license. I don't know enough about that side of things though.
prime has a BLOBSIGN signature in the first 28 bytes of the blob files for prime.
you just need to copy those 28bytes from an existing blob file that works.
this is of course only working on a unlocked prime. then the BLOBSIGN signature is not checked, so anything can be pasted in front of it.
Rayman will update the packblob to include the signature later on.
MasterZen88 said:
Great! I'm not the only one who as this problem. For what ever reason I too cannot get the blob to write.
I've tried running the blobpack -s to sign the blob but after trying to write it to the staging partition its a no go.....
EDIT: how are you working on the kernel if it has not been released yet?? JW, not trying to say your not but it would be cool if someone found a way to edit a compiled kernel.
Click to expand...
Click to collapse
I'm confused. I thought after our PMs you had it flashing just fine?
Sent from my Galaxy Nexus using Tapatalk
jermaine151 said:
I'm confused. I thought after our PMs you had it flashing just fine?
Sent from my Galaxy Nexus using Tapatalk
Click to expand...
Click to collapse
Yes it flashed but later I realize non of my settings/changes took effect.
When I stated it work, I had took the stock kernel/initramfs from asus blob, extracted, made no changes at all, recompile like we talked about in our PM's then flashed it. It work but then after I made changes, recompiled. Non of my changes took effect.
Again Jermaine you have been a BIG help. and can only hope one day I can return the favor!!!
jermaine151 said:
I'm confused. I thought after our PMs you had it flashing just fine?
Sent from my Galaxy Nexus using Tapatalk
Click to expand...
Click to collapse
MasterZen88 said:
Yes it flashed but later I realize non of my settings/changes took effect.
When I stated it work, I had took the stock kernel/initramfs from asus blob, extracted, made no changes at all, recompile like we talked about in our PM's then flashed it. It work but then after I made changes, recompiled. Non of my changes took effect.
Again Jermaine you have been a BIG help. and can only hope one day I can return the favor!!!
Click to expand...
Click to collapse
Flashing blobs does NOT always work. No idea why yet. Directly dd'ing the boot.img to the right place works BETTER than flashing a blob in some cases...
Asus really screwed up with this Unlocker thing....
MasterZen88 said:
Yes it flashed but later I realize non of my settings/changes took effect.
When I stated it work, I had took the stock kernel/initramfs from asus blob, extracted, made no changes at all, recompile like we talked about in our PM's then flashed it. It work but then after I made changes, recompiled. Non of my changes took effect.
Again Jermaine you have been a BIG help. and can only hope one day I can return the favor!!!
Click to expand...
Click to collapse
No problem. I'm surprised it didn't work for you after you made changes.
Diamondback said:
Flashing blobs does NOT always work. No idea why yet. Directly dd'ing the boot.img to the right place works BETTER than flashing a blob in some cases...
Asus really screwed up with this Unlocker thing....
Click to expand...
Click to collapse
Flashing them to staging seems to work perfectly for me. That's how I made my insecure boot.blob and flashed it. It doesn't matter whether you're on unofficial CWM or Official since if you start your updater-script with unmounting staging, it doesn't hurt anything if staging wasn't mounted. Then you can either dd the blob to mmcblk0p4 or you can directly flash it via:
Code:
package_extract_file("boot.blob", "/dev/block/mmcblk0p4");
I have not found an occasion where this didn't work. You need to make sure that you don't add any --cmdline parameters when you mkbootimg or you will get a bootloop. Staging is definitely the safest way to flash to any partitions on the Prime.
MasterZen88 said:
Correct but thats an older source code V9.4.2.7 right?
Click to expand...
Click to collapse
The kernel versions seem to be the same with the latest .15 build as the previous one. I wonder if they just recompiled the same source and that's why the host name changed to Mercury.
EDIT: I'm going to pack this kernel into a flashable blob and attach it here.
jermaine151 said:
No problem. I'm surprised it didn't work for you after you made changes.
Flashing them to staging seems to work perfectly for me. That's how I made my insecure boot.blob and flashed it. It doesn't matter whether you're on unofficial CWM or Official since if you start your updater-script with unmounting staging, it doesn't hurt anything if staging wasn't mounted. Then you can either dd the blob to mmcblk0p4 or you can directly flash it via:
Code:
package_extract_file("boot.blob", "/dev/block/mmcblk0p4");
I have not found an occasion where this didn't work. You need to make sure that you don't add any --cmdline parameters when you mkbootimg or you will get a bootloop. Staging is definitely the safest way to flash to any partitions on the Prime.
Click to expand...
Click to collapse
Hmm.. not sure whats going on but I did use this command
Code:
mkbootimg --kernel boot.img-kernel.gz --ramdisk newramdisk.cpio.gz -o newboot.img
To recompile the boot.img then used the new blobtoolsv2 to repack the blob
Code:
blobpack -s kernelblob blob.LNX newboot.img
I know staging is unmounted because I'm using your updater-script
jermaine151 said:
Flashing them to staging seems to work perfectly for me. That's how I made my insecure boot.blob and flashed it. It doesn't matter whether you're on unofficial CWM or Official since if you start your updater-script with unmounting staging, it doesn't hurt anything if staging wasn't mounted. Then you can either dd the blob to mmcblk0p4 or you can directly flash it via:
Code:
package_extract_file("boot.blob", "/dev/block/mmcblk0p4");
I have not found an occasion where this didn't work. You need to make sure that you don't add any --cmdline parameters when you mkbootimg or you will get a bootloop. Staging is definitely the safest way to flash to any partitions on the Prime.
Click to expand...
Click to collapse
if you copy the blob, while p4 is mounted to staging in cwm, you will have a problem when you reboot, as the filesystem umount, and that cause a small change to the mounted filesystem, to indicate it is umounted normally. and the p4 partition becomes invalid.
so it can easily become a problem if p4 is mounted.
at least thats how i experienced the problem when seen initially.
Dexter_nlb said:
if you copy the blob, while p4 is mounted to staging in cwm, you will have a problem when you reboot, as the filesystem umount, and that cause a small change to the mounted filesystem, to indicate it is umounted normally. and the p4 partition becomes invalid.
so it can easily become a problem if p4 is mounted.
at least thats how i experienced the problem when seen initially.
Click to expand...
Click to collapse
That's why I said to always add an unmount("/staging"); to the top of your script. The attached flashable zip works perfectly on the official CWM; staging is not mounted by default, but I told the script to unmount it anyway in case someone with the unofficial CWM tries to flash it. If it's already unmounted, the script just continues.
Anyone may use this as a template for consistently flashing a kernel to staging.
MasterZen88 said:
Hmm.. not sure whats going on but I did use this command
Code:
mkbootimg --kernel boot.img-kernel.gz --ramdisk newramdisk.cpio.gz -o newboot.img
To recompile the boot.img then used the new blobtoolsv2 to repack the blob
Code:
blobpack -s kernelblob blob.LNX newboot.img
I know staging is unmounted because I'm using your updater-script
Click to expand...
Click to collapse
Hmm... That all looks good. What happens after you attempt to flash this and what changes did you make to the ramdisk?
EDIT: Hey, I just re-read your PM. It sounds like you're editing the wrong file in the ramdisk. To make an insecure boot image, you should be editing init.rc, NOT init.cardhu.rc.
Here's a great guide to follow. It's the same procedure for the Prime as the original Transformer:
http://forum.xda-developers.com/showthread.php?t=1193737
jermaine151 said:
Hmm... That all looks good. What happens after you attempt to flash this and what changes did you make to the ramdisk?
EDIT: Hey, I just re-read your PM. It sounds like you're editing the wrong file in the ramdisk. To make an insecure boot image, you should be editing init.rc, NOT init.cardhu.rc.
Here's a great guide to follow. It's the same procedure for the Prime as the original Transformer:
http://forum.xda-developers.com/showthread.php?t=1193737
Click to expand...
Click to collapse
Okay that makes sense. One f my changes was to default.prop for insecure boot.img
Code:
ro.secure=0
This did not show after I flashed. But I will try again in a couple hour's once my workload calms down... SysAdmin life is not easy...lol
MasterZen88 said:
Okay that makes sense. One f my changes was to default.prop for insecure boot.img
Code:
ro.secure=0
This did not show after I flashed. But I will try again in a couple hour's once my workload calms down... SysAdmin life is not easy...lol
Click to expand...
Click to collapse
LOL! I meant to say default.prop and not init.rc. I totally understand. I used to be a SysSdmin too. Now I moved more towards the networking side of things. Much more calm.
jermaine151 said:
LOL! I meant to say default.prop and not init.rc. I totally understand. I used to be a SysSdmin too. Now I moved more towards the networking side of things. Much more calm.
Click to expand...
Click to collapse
Would love to be on that side of the tracks. I'm banging my head against the wall right now trying to figure out how to implement Microsoft System Center Service Manager 2010 and on top of that one of our Citrix Broker boxes went down last night... Not a funny day at all. But I'll keep this thread about Android...for now....
No, unfortunately flashing a blob does not always do the same as dd'ing boot.img directly. We recently had a case were someone lost root access. the only way to recover was to directly dd a boot.img.
Flashing the SAME boot.img via blob did not work (nor did any other blob we tested)
So blob flashing obviously has some quirks....
Diamondback said:
No, unfortunately flashing a blob does not always do the same as dd'ing boot.img directly. We recently had a case were someone lost root access. the only way to recover was to directly dd a boot.img.
Flashing the SAME boot.img via blob did not work (nor did any other blob we tested)
So blob flashing obviously has some quirks....
Click to expand...
Click to collapse
I just haven't see that issue flashing any of my blobs and CM9 is using the same method and it's working. Who knows.
jermaine151 said:
I just haven't see that issue flashing any of my blobs and CM9 is using the same method and it's working. Who knows.
Click to expand...
Click to collapse
We only had it one time too, but one time is enough to scare me further
This whole blob stuff just is crap
So... a lot of us are stuck on a certain firmware and need to get off of it. A solution to us all (hopefully), is a program called "bspatch" (usually comes with bsdiff). We have a boot.img file (compiled android img) and a boot.img.p (from an OTA update, zip, which we know 100% works and people have updated with the OTA zip).
We need bspatch to stop checking for corruption like it does now and to just force the patch to go. This would help save a lot of users stuck on firmware and we would all appreciate a point in the right direction.
We tried compiling the source of bspatch from many sites, but none seem to compile correctly or even run. We get them to run from binary pre-compiled versions, but those won't help us since it sees the patch as corrupt.
If we can get boot.img from the 6.12.181 fastboot files to patch with the boot.img.p from an ICS like the most current (6.16.206 as of 5/20/2012) we can make a fastboot files that is flashable onto someone stuck on 6.14.84 so they can upgrade to 206 with Moto Recovery.
Also if this magically can be done by the help of the XDA community, we can create a boot.img from 6.12.181 patched with a 4.0.3 boot.img.p (like from 84 or 85, since 79 and below aren't flashable on newer ICS), we can also have a root method for 4.0.4 like the GSM users have.
Best of luck to those who try to help with this!
http://www.daemonology.net/bsdiff/
https://launchpad.net/ubuntu/+source/bsdiff/4.3-10ubuntu1/+build/2960721
Files(s): http://rombot.droidhive.com/ROMs/spyder/BspatchProject.zip
alt link: http://www.filefactory.com/file/1xj6eh1mocz7/n/BspatchProject_zip
Note: My friend tried this already and we got Pre-flash validation errors when trying to fastboot it. Just throwing this idea out there.... best of luck.
EDIT: Added as an attachment.
Thanks to dhacker29 for trying this idea out first
Err.. Doesn't the /system/bin/applypatch can do this already??
I've always used it to patch OTA manualy..
example usage:
Code:
applypatch boot.img boot_new.img [B]X Y Z[/B]:boot.img.p
where
Code:
[B]X[/B] is the target(boot_new.img) sha1sum
[B]Y[/B] is the target(boot_new.img) new size
[B]Z[/B] is the source(boot.img) sha1sum
Obviously it will failed the cert test,
if the patch(boot.img.p) is not intended for the base(boot.img)
Information can be extracted from OTA update-script
example
assert(apply_patch("MTD:boot:8388608:5fff8425560eb 1002b467062de2b355b45090ad7:8388608:2997ddb421e1d4 4b026410339e343f60b3bb65bd",
"-", 2997ddb421e1d44b026410339e343f60b3bb65bd, 8388608,
5fff8425560eb1002b467062de2b355b45090ad7, package_extract_file("patch/boot.img.p")));
Click to expand...
Click to collapse
X = 2997ddb421e1d44b026410339e343f60b3bb65bd
Y = 8388608
Z = 5fff8425560eb1002b467062de2b355b45090ad7
easily done via adb
Code:
adb.exe push boot.img /tmp/
adb.exe push boot.img.p /tmp/
adb.exe shell /system/bin/applypatch /tmp/boot.img /tmp/boot_new.img X Y Z:/tmp/boot.img.p
adb.exe pull /tmp/boot_new.img
whirleyes said:
Err.. Doesn't the /system/bin/applypatch can do this already??
I've always used it to patch OTA manualy..
example usage:
Code:
applypatch boot.img boot_new.img x y z:boot.img.p
where
Code:
x is the target(boot_new.img) sha1sum
y is the target(boot_new.img) new size
z is the source(boot.img) sha1sum
Obviously it will failed the cert test,
if the patch(boot.img.p) is not intended for the base(boot.img)
Click to expand...
Click to collapse
I can confirm that applypatch does have at least some success in patching a boot.img once you can figure out the information required from updater-script found in the OTA you are trying to make fastboot images for. I patched the file obtained by
Code:
dd if=/dev/block/mmcblk1p14 of=/sdcard-ext/b/boot.bin
on a 6.12.181 successfully using the code
Code:
applypatch ./boot.bin ./boot.bin.2 dd9310794842a4908aff55979a9fe97f825e8748 8388608 8e21cfa5d9be4dd08427b079fbff9a80d6e04560:boot.img.p
the code i ripped apart from 6.16.206 is
Code:
assert(apply_patch("MTD:boot:8388608:8e21cfa5d9be4dd08427b079fbff9a80d6e04560:8388608:dd9310794842a4908aff55979a9fe97f825e8748",
"-", dd9310794842a4908aff55979a9fe97f825e8748, 8388608,
8e21cfa5d9be4dd08427b079fbff9a80d6e04560, package_extract_file("patch/boot.img.p")));
to figure out the apply patch code i looked at the info above and compared it to this
[qoute]adb shell applypatch
usage: applypatch <src-file> <tgt-file> <tgt-sha1> <tgt-size> [<src-sha1>:<patch> ...]
or applypatch -c <file> [<sha1> ...]
or applypatch -s <bytes>
or applypatch -l
Filenames may be of the form
MTD:<partition>:<len_1>:<sha1_1>:<len_2>:<sha1_2>:...
to specify reading from or writing to an MTD partition.[/quote] and with a little trial and error got it to work
EDIT
Let me be clear the patched boot.bin.2 does flash perfectly fine. no preflash validation failure.
Anyone on 6.16.206 want to do me a favor and do?
Code:
dd if=/dev/block/mmcblk1p15 of=/sdcard-ext/b/recovery.bin
and email/upload it to me? I'll hit the thanks button </bribe>
SilentViper said:
EDIT
Let me be clear the patched boot.bin.2 does flash perfectly fine. no preflash validation failure.
Anyone on 6.16.206 want to do me a favor and do?
Code:
dd if=/dev/block/mmcblk1p15 of=/sdcard-ext/b/recovery.bin
and email/upload it to me? I'll hit the thanks button </bribe>
Click to expand...
Click to collapse
I asked on the DroidRZR thread for 6.16.206 if anyone could do it, let's see
Edit: By the way which version boot.img is patched and flashable, and could we get a copy?
This is what a user at DroidRzr got when he tryed:
dd if=/dev/block/mmcblk1p15 of=/sdcard-ext/b/recovery.bin
[quote name='Fixter' timestamp='1337690349' post='46825']
Doing it right now Matt.
PS: Cannot Open for Read: Permission Denied
Also, I have root. Let me check now. I forgot to restore root.
Update 2: Cannot Open for Write: No such file or Directory. I copy pasted it, so I know it's right.
[/quote]
dimitri407 said:
This is what a user at DroidRzr got when he tryed:
dd if=/dev/block/mmcblk1p15 of=/sdcard-ext/b/recovery.bin
[quote name='Fixter' timestamp='1337690349' post='46825']
Doing it right now Matt.
PS: Cannot Open for Read: Permission Denied
Also, I have root. Let me check now. I forgot to restore root.
Update 2: Cannot Open for Write: No such file or Directory. I copy pasted it, so I know it's right.
Click to expand...
Click to collapse
[/QUOTE]
He might need to do
Code:
mkdir /sdcard-ext/b
He might need to do
Code:
mkdir /sdcard-ext/b
[/QUOTE]
http://www.mediafire.com/?iihwd669mdxg740
Recovery.bin from DR user Fixter from 206.
Enjoy!
dimitri407 said:
This is what a user at DroidRzr got when he tryed:
dd if=/dev/block/mmcblk1p15 of=/sdcard-ext/b/recovery.bin
[quote name='Fixter' timestamp='1337690349' post='46825']
Doing it right now Matt.
PS: Cannot Open for Read: Permission Denied
Also, I have root. Let me check now. I forgot to restore root.
Update 2: Cannot Open for Write: No such file or Directory. I copy pasted it, so I know it's right.
Click to expand...
Click to collapse
[/QUOTE]
Finally, some headway,
But I have a question is in regards to the DD command (kinda off topic but not really). How do you know that p15 is associated with recovery.bin, well at least for Droid Razr XT912-Verizon. I have some tools that show symlinks in an android file browser, but I am looking for a Linux command as well.
Been trying to find access to the devtree partition as well as cdrom, recovery, cdt.bin (p18=true), and now in this case, boot. I found all but devtree. Any ideas,
X
Open the recovery.img in a hex editor and the partitions are listed at the top.
mattlgroff said:
He might need to do
Code:
mkdir /sdcard-ext/b
Click to expand...
Click to collapse
http://www.mediafire.com/?iihwd669mdxg740
Recovery.bin from DR user Fixter from 206.
Enjoy!
Click to expand...
Click to collapse
AWESOME. I successfully flashed that to my secondary razr that i am playing with these updates on. I used this plus my custom patched boot.bin.2 to successfully boot into recovery. but im currently stuck there because no OTAs will flash from that, and my /system partition isn't the right version, nor anything else for that matter. now I need the rest of the /dev/block files from 206 :/
i'm going to have to figure something out quick
Couldn't you just extract the files from the .206 zip file that you need? Unless if I am missing something of course... just one thought I had on this.
No, those are patch files. To make a fastboot package I need the block dumps
Sent from my DROID RAZR using XDA
SilentViper said:
No, those are patch files. To make a fastboot package I need the block dumps
Sent from my DROID RAZR using XDA
Click to expand...
Click to collapse
Makes sense. Hopefully someone running .206 could provide that to you. Sadly I'm unable to as I'm on .203 on my RAZR. Bummer.
Project Success.
http://www.droidrzr.com/index.php/t...m-icsbut-not-back-to-gb-6148485-616203204206/
Great job to everyone involved!
mattlgroff said:
Project Success.
http://www.droidrzr.com/index.php/t...m-icsbut-not-back-to-gb-6148485-616203204206/
Great job to everyone involved!
Click to expand...
Click to collapse
Awesome! mind posting just the fastboot commands? I tried interpreting the .bat but haven't had much experience with .BATs and am not entirely sure what you are doing
DemoManMLS said:
Makes sense. Hopefully someone running .206 could provide that to you. Sadly I'm unable to as I'm on .203 on my RAZR. Bummer.
Click to expand...
Click to collapse
Not anymore you're not!
Sent from the bottom of my fart
SEMI success. We wanna get us back on the path, not on a later ICS build. This might be okay if it works with the OTA, but...
[TSON] said:
SEMI success. We wanna get us back on the path, not on a later ICS build. This might be okay if it works with the OTA, but...
Click to expand...
Click to collapse
Why wouldn't they be able to use this strategy again and use img file from official ota?
Sent from my DROID SPYDER using Tapatalk 2
Knowing Moto...
[TSON] said:
Knowing Moto...
Click to expand...
Click to collapse
I feel like update is pretty close . I would be impressed if they patched it that quickly
Sent from my DROID SPYDER using Tapatalk 2
I've tried using twrp and cwm to backup my system image but i havent been able to, with twrp i had system.ext4.win when i backed up only the system. Is their a tool or do i need to do it with adb ?
Thanks!
could you specify your phone/tablet model?
fantamedo said:
could you specify your phone/tablet model?
Click to expand...
Click to collapse
Galaxy s3
First make a full nandroid backup in CWMR, then on your phone navigate to mint/sdcard/clockworkmod then copy the folder of the backup you made (It should be the date of the backup by default) and transfer it to your computer. Once you transfer it to your computer open the backup folder and inside should be the system.img file.
You can also type these commands in terminal emulator to get your system.img:
Code:
su
dd if=/dev/block/mmcblk0p14 of=/mnt/sdcard/system.img bs=4096
Then just transfer the system.img from your sdcard to your computer. Let me know if you still have questions.
Sent from my SCH-I535 using xda premium
It didn't work with cwmr but I haven't tried out the terminal command
Sent from my SCH-I535 using xda premium
CovXX said:
It didn't work with cwmr but I haven't tried out the terminal command
Sent from my SCH-I535 using xda premium
Click to expand...
Click to collapse
Like I said try out the terminal command I suggested and let me know how it goes .
Sent from my SCH-I535 using xda premium
shimp208 said:
First make a full nandroid backup in CWMR, then on your phone navigate to mint/sdcard/clockworkmod then copy the folder of the backup you made (It should be the date of the backup by default) and transfer it to your computer. Once you transfer it to your computer open the backup folder and inside should be the system.img file.
You can also type these commands in terminal emulator to get your system.img:
Code:
su
dd if=/dev/block/mmcblk0p14 of=/mnt/sdcard/system.img bs=4096
Then just transfer the system.img from your sdcard to your computer. Let me know if you still have questions.
Sent from my SCH-I535 using xda premium
Click to expand...
Click to collapse
thanks man, just the command i was looking for, and it works like a charm.. :good:
So how about for a Razr M XT907 ? I ran the term command, but the img size was wayyy too small.
Find out what your system partition is and change command accordingly
Sent from my Nexus 4 using xda premium
livinginkaos said:
So how about for a Razr M XT907 ? I ran the term command, but the img size was wayyy too small.
Click to expand...
Click to collapse
You can find out your which partition your /system partition is by running the following commands either from terminal or adb shell as the root user:
Code:
ls -l /dev/block/platform/{your_platform_name_here}/by-name
For example on my Nexus 10 the platform name is "dw_mmc.0" so the command would look like:
Code:
ls -l /dev/block/platform/dw_mmc.0/by-name
To figure out your platform name first cd into the platform directory then list the contents of the platform directory to figure out what your platform name is:
Code:
cd /dev/block/platform/
ls
After you have then figured out what your platform name is you can run the command:
Code:
ls -l /dev/block/platform/{your_platform_name_here}/by-name
Once you have figured out your system partition you can dump it to your phones storage by running a command similar to:
Code:
cat /dev/block/block_of_system_partition > /mnt/sdcard/system.img
Let me know if you still have questions .
Awesome guys ! Thanks a bunch.
OK, so I have gotten the img. I've done it both ways with the dd and the cat. The image size comes up close to 1.5Gb. I know this is too large. The fastboot img file is normally in the 800-900 Mb range. Am I missing something here?
livinginkaos said:
OK, so I have gotten the img. I've done it both ways with the dd and the cat. The image size comes up close to 1.5Gb. I know this is too large. The fastboot img file is normally in the 800-900 Mb range. Am I missing something here?
Click to expand...
Click to collapse
Have you installed any additional system apps or placed any other files in the system folder? Because if you have modified the /system folder contents the file size will be greater then the normal 800-900 MB file range you listed since that file size if for an unmodified completely stock /system image.
Actually not really. I had done an erase data, roll back fxz, root, update and cache/dalvik wipe. Was trying to get a somewhat clean system.img
shimp208 said:
You can find out your which partition your /system partition is by running the following commands either from terminal or adb shell as the root user:
Code:
ls -l /dev/block/platform/{your_platform_name_here}/by-name
For example on my Nexus 10 the platform name is "dw_mmc.0" so the command would look like:
Code:
ls -l /dev/block/platform/dw_mmc.0/by-name
To figure out your platform name first cd into the platform directory then list the contents of the platform directory to figure out what your platform name is:
Code:
cd /dev/block/platform/
ls
After you have then figured out what your platform name is you can run the command:
Code:
ls -l /dev/block/platform/{your_platform_name_here}/by-name
Once you have figured out your system partition you can dump it to your phones storage by running a command similar to:
Code:
cat /dev/block/block_of_system_partition > /mnt/sdcard/system.img
Let me know if you still have questions .
Click to expand...
Click to collapse
When we come to Android 5.0 ages, we have new problems:
Method1 Using the dd we really can get the system.img, but in my 8994 device with busybox 1.23.1, it will 2.5GB fixed size, same as the system partition size.
so what I can found it works is , use sparsecoverter in this forum http://forum.xda-developers.com/showthread.php?t=2749797, we can remove the sparse bytes and make it a 1.4GB around and fastboot back to devices, that works fine, NOTE, that is not from dd nandroid backup. not from who only have TWRP and CWM backups;.
Method2 Using TWRP/CWM system.ext4.win/data.ext4.win, we can use
tar -xvf /storage/sdcard1/twrp/backup/abcd/2015-03-29-09-00-00/system.ext4.win
tar -xvf /storage/sdcard1/twrp/backup/abcd/2015-03-29-09-00-00/data.ext4.win
to gotten a folder, I run this on my target device under adb root and adb shell, but it will have many errors, tar remote link .... function not implement, so I think we need a cygwin according this post, but next step since Android 4.0 should be make_ext4fs, which will need a special build to avoid Permission Denied. which I still not success to finish it.
so, if Android successful tar -xvf and make_ext4fs story, please share here, thank you very much!
any news to help me forward?
I want to dump boot.img for flashing my kernel .
I've navigated in/dev/block/platform/sprd-sdhci.3/by-name folder
but there isn't boot.img . Have you given me advices? thanks you.
Is there a boot partition? It could also be named Kernel in some devices. You have to have root and use dd command.
adb shell
su
dd if=/.../by-name/boot (or kernel) of=/sdcard/boot.img
Sent from my KYOCERA-C6745 using Tapatalk
RealWelder said:
Is there a boot partition? It could also be named Kernel in some devices. You have to have root and use dd command.
adb shell
su
dd if=/.../by-name/boot (or kernel) of=/sdcard/boot.img
Click to expand...
Click to collapse
I have dumped it and see that its size is 15MB. But when i see boot.img in flashable rom files ,its size is only 5 MB.I'm wondering if that kernel file is also same as boot.img.
Nuttapat007 said:
I have dumped it and see that its size is 15MB. But when i see boot.img in flashable rom files ,its size is only 5 MB.I'm wondering if that kernel file is also same as boot.img.
Click to expand...
Click to collapse
When you dd it copies the entire partition size, including blank space. Totally normal. The new one wasn't done with dd command so the blank space isn't shown.
Sent from my KYOCERA-C6745 using Tapatalk
RealWelder said:
When you dd it copies the entire partition size, including blank space. Totally normal. The new one wasn't done with dd command so the blank space isn't shown.
Click to expand...
Click to collapse
Thanks you