Full ROM Backup via ADB? Is it possible? - Galaxy S II Q&A, Help & Troubleshooting

Hi there,
Is it possible to make a full backup of my stock ROM via ADB?
I know that it was possible on SGS I9000 (something like below code)
Code:
adb shell
su
mkdir /sdcard/BackupRom
dd if=/dev/block/bml1 of=/sdcard/BackupRom/boot.bin bs=4096
dd if=/dev/block/bml2 of=/sdcard/BackupRom/pit.pit bs=4096
dd if=/dev/block/stl3 of=/sdcard/BackupRom/efs.rfs bs=4096
dd if=/dev/block/bml4 of=/sdcard/BackupRom/Sbl.bin bs=4096
dd if=/dev/block/stl6 of=/sdcard/BackupRom/param.lfs bs=4096
dd if=/dev/block/bml7 of=/sdcard/BackupRom/zImage bs=4096
dd if=/dev/block/stl9 of=/sdcard/BackupRom/factoryfs.rfs bs=4096
dd if=/dev/block/stl10 of=/sdcard/BackupRom/dbdata.rfs bs=4096
dd if=/dev/block/stl11 of=/sdcard/BackupRom/cache.rfs bs=4096
dd if=/dev/block/bml12 of=/sdcard/BackupRom/modem.bin bs=4096
tar -czvf /sdcard/BackupRom/data.tar.gz /data
I want to do this because nandroid implies modifying kernel, and ADB backup would be the cleanest way.
Thanks!!

I think its possible, but you probably need your phone to be rooted in order to do such a thing.

kaukassus said:
I think its possible, but you probably need your phone to be rooted in order to do such a thing.
Click to expand...
Click to collapse
You are right... Root is needed.
Thanks

Related

[Q] custom backup for Odin restore?

Hey
I found another post which details a way to get all of the relevant files together from your device, and then bundled into a tar, so that you can use Odin to reflash your own 'custom' backup. I have put the commands below, does anyone know how to tailor this for the SGS2 ? The \dev\block\* devices are different as when i try through adb shell or terminal emulator it doesn't recognise the devices ::
Sys:
dd if=/dev/block/stl10 of=/sdcard/factoryfs.rfs bs=4096
Kernel:
dd if=/dev/block/bml8 of=/sdcard/zImage bs=4096
Recovery:
dd if=/dev/block/bml9 of=/sdcard/recovery.bin bs=4096
(personal info)
Cache:
dd if=/dev/block/mmcblk0p3 of=/sdcard/cache.rfs bs=4096
DBData:
dd if=/dev/block/stl11 of=/sdcard/dbdata.rfs bs=4096
Data:
dd if=/dev/block/mmcblk0p1 of=/sdcard/movinand.bin bs=4096
and then to make the image for Odin to flash:
tar -H ustar -c cache.rfs dbdata.rfs factoryfs.rfs movinand.bin recovery.bin zImage > package_name.tar
md5sum -t package_name.tar >> package_name.tar
mv package_name.tar package_name.tar.md5
Any help appreciated
Thanks
I'm interested in this, too!
hi sea_salt !
I got the commands from another post:
dd if=/dev/block/mmcblk0p1 of=/sdcard/p1-EFS.img bs=4096
dd if=/dev/block/mmcblk0p4 of=/sdcard/p4-PARAM.img bs=4096
dd if=/dev/block/mmcblk0p5 of=/sdcard/p5-KERNEL.img bs=4096
dd if=/dev/block/mmcblk0p8 of=/sdcard/p8-MODEM.img bs=4096
dd if=/dev/block/mmcblk0p9 of=/sdcard/p9-FACTORYFS.img bs=4096
dd if=/dev/block/mmcblk0p12 of=/sdcard/p12-HIDDEN.img bs=4096
I have tried them using adb shell and they work .
The question is how do i get them now into a .tar/.md5 so that Odin can flash them ?
spoonflames said:
hi sea_salt !
I got the commands from another post:
dd if=/dev/block/mmcblk0p1 of=/sdcard/p1-EFS.img bs=4096
dd if=/dev/block/mmcblk0p4 of=/sdcard/p4-PARAM.img bs=4096
dd if=/dev/block/mmcblk0p5 of=/sdcard/p5-KERNEL.img bs=4096
dd if=/dev/block/mmcblk0p8 of=/sdcard/p8-MODEM.img bs=4096
dd if=/dev/block/mmcblk0p9 of=/sdcard/p9-FACTORYFS.img bs=4096
dd if=/dev/block/mmcblk0p12 of=/sdcard/p12-HIDDEN.img bs=4096
I have tried them using adb shell and they work .
The question is how do i get them now into a .tar/.md5 so that Odin can flash them ?
Click to expand...
Click to collapse
hey this sounds great. thanks for your reply!
Does EFS, PARAM, KERNEL, MODEM, FACTORYFS, HIDDEN contain ALL stuff of the sgs2-phone's-rom and data, so that it can be used to completetely backup the device?
but I suppose that these adb-commands only work when you already have a root-kernel, or not?
are there the same commands to use adb to restore all this stuff?

Can a GSM user get me these partiton dumps?

dd if=/dev/block/mmcblk0p4 of=/mnt/sdcard/mmcblk0p4.img
dd if=/dev/block/mmcblk0p5 of=/mnt/sdcard/mmcblk0p5.img
dd if=/dev/block/mmcblk0p13 of=/mnt/sdcard/mmcblk0p13.img
dd if=/dev/block/mmcblk0p28 of=/mnt/sdcard/mmcblk0p28.img
dd if=/dev/block/mmcblk0p29 of=/mnt/sdcard/mmcblk0p29.img
dd if=/dev/block/mmcblk0p30 of=/mnt/sdcard/mmcblk0p30.img
all of these are blank or almost blank for me and tis causing my 3g not to work..
if someone can dump them and upload, i'd be really happy
usual command is adb shell
su
dd if=/dev/block/mmcblk0p4 of=/mnt/sdcard/mmcblk0p4.img
dd if=/dev/block/mmcblk0p5 of=/mnt/sdcard/mmcblk0p5.img
dd if=/dev/block/mmcblk0p13 of=/mnt/sdcard/mmcblk0p13.img
dd if=/dev/block/mmcblk0p28 of=/mnt/sdcard/mmcblk0p28.img
dd if=/dev/block/mmcblk0p29 of=/mnt/sdcard/mmcblk0p29.img
dd if=/dev/block/mmcblk0p30 of=/mnt/sdcard/mmcblk0p30.img
mmcblk0p5 has the cid and imei and mmcblk0p13 says SkaBHT231V208772 other files are empty for me
ercineker said:
mmcblk0p5 has the cid and imei and mmcblk0p13 says SkaBHT231V208772 other files are empty for me
Click to expand...
Click to collapse
thank u!

Need help Jtag unbrick Project SCH-R530M

i there,
I'm working at creating a solution for JTAG repair on the SGS III USC model and I'm in need of a SCH-R530M SBL dumps and a few other zones. I need a rooted user to simply perform the following command from a terminal on the phone, or while using ADB SHELL under the su user. Once at the command line issue this command, then simply upload the files which end up on your sdcard to me here. That's it!
Thanks in advance!
Code:
dd if=/dev/block/mmcblk0p2 of=/sdcard/sbl1 bs=4096
dd if=/dev/block/mmcblk0p3 of=/sdcard/sbl2 bs=4096
dd if=/dev/block/mmcblk0p4 of=/sdcard/sbl3 bs=4096
dd if=/dev/block/mmcblk0p5 of=/sdcard/aboot bs=4096
dd if=/dev/block/mmcblk0p6 of=/sdcard/rpm bs=4096
dd if=/dev/block/mmcblk0p7 of=/sdcard/boot bs=4096
dd if=/dev/block/mmcblk0p8 of=/sdcard/tz bs=4096
dd if=/dev/block/mmcblk0p9 of=/sdcard/pad bs=4096
dd if=/dev/block/mmcblk0p10 of=/sdcard/param bs=4096
dd if=/dev/block/mmcblk0p18 of=/sdcard/recovery bs=4096
tomy1986.nt said:
i there,
I'm working at creating a solution for JTAG repair on the SGS III USC model and I'm in need of a SCH-R530M SBL dumps and a few other zones. I need a rooted user to simply perform the following command from a terminal on the phone, or while using ADB SHELL under the su user. Once at the command line issue this command, then simply upload the files which end up on your sdcard to me here. That's it!
Thanks in advance!
Code:
dd if=/dev/block/mmcblk0p2 of=/sdcard/sbl1 bs=4096
dd if=/dev/block/mmcblk0p3 of=/sdcard/sbl2 bs=4096
dd if=/dev/block/mmcblk0p4 of=/sdcard/sbl3 bs=4096
dd if=/dev/block/mmcblk0p5 of=/sdcard/aboot bs=4096
dd if=/dev/block/mmcblk0p6 of=/sdcard/rpm bs=4096
dd if=/dev/block/mmcblk0p7 of=/sdcard/boot bs=4096
dd if=/dev/block/mmcblk0p8 of=/sdcard/tz bs=4096
dd if=/dev/block/mmcblk0p9 of=/sdcard/pad bs=4096
dd if=/dev/block/mmcblk0p10 of=/sdcard/param bs=4096
dd if=/dev/block/mmcblk0p18 of=/sdcard/recovery bs=4096
Click to expand...
Click to collapse
Reported your other thread - Reporting this one. USE THE APPROPRIATE DEVICE FORUM. One of the simplest rules!
Thread Closed.
OP Please follow the rules about double posts... Also please post in the correct sections.

Backup all partitions including EFS

For those who do not know, EFS partition containing IMEI, MEID, and other important data. Once lost, these partitions can not be recovered, because they are unique to your phone only.
Since we do not have a custom recovery yet, the only solutions to backup EFS partitions are in terminal or adb. I prefer adb because it is more easier to do.
1.Create a folder in internal sdcard named efs
2.Run these commands in adb or terminal
dd if=/dev/block/platform/msm_sdcc.1/by-name/modemst1 of=/sdcard/efs/modemst1.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/modemst2 of=/sdcard/efs/modemst2.img
3.If you want to backup all partitions on your phone create a folder named backup in internal sdcard can run these commands:
dd if=/dev/block/platform/msm_sdcc.1/by-name/aboot of=/sdcard/backup/aboot.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/boot of=/sdcard/backup/boot.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/DDR of=/sdcard/backup/DDR.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/encrypt of=/sdcard/backup/encrypt.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/fota of=/sdcard/backup/fota.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/fsc of=/sdcard/backup/fsc.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/fsg of=/sdcard/backup/fsg.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/laf of=/sdcard/backup/laf.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/misc of=/sdcard/backup/misc.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/mpt of=/sdcard/backup/mpt.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/persist of=/sdcard/backup/persist.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/rct of=/sdcard/backup/rct.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/recovery of=/sdcard/backup/recovery.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/rpm of=/sdcard/backup/rpm.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/sbl1 of=/sdcard/backup/sbl1.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/sns of=/sdcard/backup/sns.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/ssd of=/sdcard/backup/ssd.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/tz of=/sdcard/backup/tz.img
Less important partitions:
dd if=/dev/block/platform/msm_sdcc.1/by-name/abootb of=/sdcard/backup/abootb.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/cust of=/sdcard/backup/cust.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/drm of=/sdcard/backup/drm.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/eksst of=/sdcard/backup/eksst.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/factory of=/sdcard/backup/factory.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/grow of=/sdcard/backup/grow.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/modem of=/sdcard/backup/modem.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/pad of=/sdcard/backup/pad.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/rpmb of=/sdcard/backup/rpmb.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/sbl1b of=/sdcard/backup/sbl1b.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/sdi of=/sdcard/backup/sdi.img
dd if=/dev/block/platform/msm_sdcc.1/by-name/tzb of=/sdcard/backup/tzb.img
For dd commands your phone has to be rooted.
Please do not ask me how to install and use adb.
If you want to restore your original EFS partitions just run the commands below in adb ot terminal:
dd if=/sdcard/efs/modemst1.img of=/dev/block/platform/msm_sdcc.1/by-name/modemst1
dd if=/sdcard/efs/modemst2.img of=/dev/block/platform/msm_sdcc.1/by-name/modemst2
You'll have to type that whole thing out, and be VERY careful with spaces and punctuation. One wrong letter and you could hard brick your phone.
Very nice work.
I thought that EFS is only used by Samsung. Guess not.
Sent from my D620R [Stock 4.4.2]

Who can dump a image?

Hi, can someone who owns a working lg l9 device dump a bootloader image?
I prefer a P760 device but even if there are other devices it does the same.
This is the command:
Code:
dd if=/dev/block/mmcblk0 of=/sdcard/debrick.img bs=1M count=128
or
Code:
dd if=/dev/block/mmcblk0 of=/sdcard/debrick.img bs=1M count=512

Categories

Resources