I have a question here. Recently the LG G PRO 2 android handphone received OTA update. If I let the OTA run. After OTA updated, if I still want to re-install Philz Touch Recovery, is that mean the latest newer file provided by OTA update will be overwrite when I re-install the recovery that released 1 yr ago?
Below is the command that will install the files if I re-install the recovery. I dont know if these file important or not if replaced by recovery installation. I have no idea the purpose of these files. Please advice.
What I hope is to make sure latest stable file running on my phone.
adb shell su -c "dd if=/sdcard/img/recovery.img of=/dev/block/platform/msm_sdcc.1/by-name/recovery"
adb shell su -c "dd if=/sdcard/img/aboot.img of=/dev/block/platform/msm_sdcc.1/by-name/aboot"
adb shell su -c "dd if=/sdcard/img/boot.img of=/dev/block/platform/msm_sdcc.1/by-name/boot"
adb shell su -c "dd if=/sdcard/img/dbi.img of=/dev/block/platform/msm_sdcc.1/by-name/dbi"
adb shell su -c "dd if=/sdcard/img/laf.img of=/dev/block/platform/msm_sdcc.1/by-name/laf"
adb shell su -c "dd if=/sdcard/img/persist.img of=/dev/block/platform/msm_sdcc.1/by-name/persist"
adb shell su -c "dd if=/sdcard/img/rpm.img of=/dev/block/platform/msm_sdcc.1/by-name/rpm"
adb shell su -c "dd if=/sdcard/img/sbl1.img of=/dev/block/platform/msm_sdcc.1/by-name/sbl1"
adb shell su -c "dd if=/sdcard/img/tz.img of=/dev/block/platform/msm_sdcc.1/by-name/tz"
adb shell su -c "dd if=/sdcard/img/modem.img of=/dev/block/platform/msm_sdcc.1/by-name/modem"
Related
I am on aospCM's rom for my Hero and as such the market has some problems. To fix it, s0be found a way to do it. The commands are such:
1. adb shell
2. su
3. mkdir /cache/download
4. chown system:cache /cache/download
5. chmod ug+rwx /cache/download
6. chmod a+x /cache/download
Click to expand...
Click to collapse
I don't need step 3 since the directory exists.
Since I am flashing nightlies (or near nightlies as the case may be) typing all of these commands gets super tedious. I figured there has to be a way to do this in a .bat from Windows.
I have adb worked into my system shell (did this so I could use the SendTo menu to push to my phone) and I came up with this:
Code:
@echo off
adb connect 192.168.1.66
echo Time to fix the market
pause
adb shell su
adb shell chown system:cache /cache/download
adb shell chmod ug+rwx /cache/download
adb shell chmod a+x /cache/download
echo Done
pause
This didn't work, nor did a few iterations previous to it where I was taking out the repetitive 'adb shell' commands. I don't know enough about batch/dos programming to get this to work, so I am turning to the community. Help please?
i think you must need superuser permision
not "adb shell" try "adb shell -c"
dateno1 said:
i think you must need superuser permision
not "adb shell" try "adb shell -c"
Click to expand...
Click to collapse
Does that mean I need to put "adb shell -c" on each line? Just once?
just replace 'adb shell' to 'adb shell su -c' and retry
dateno1 said:
just replace 'adb shell' to 'adb shell su -c' and retry
Click to expand...
Click to collapse
Got it! Thanks!
I got it to work too (well, I think anyway). If anyone's interested, here's my code (and if anyone sees any problems, let me know!):
Code:
@echo Begin s0be's market fix
@echo off
PAUSE
adb connect 192.168.1.66
adb shell "su -c 'sleep 1'"
adb start-server
@echo on
@echo Working...
@echo off
SET /P ANSWER=Create /cache/download?
echo (y/y): %ANSWER%
if /i {%ANSWER%}=={y} (goto :yes)
goto :no
:yes
adb shell "su -c 'sleep 2'"
@echo Creating Market Directory in Cache
@echo off
adb shell "su -c 'mkdir /cache/download'"
goto :no
:no
adb shell "su -c 'sleep 2'"
@echo Assigning Logical Link
@echo off
adb shell "su -c 'chown system:cache /cache/download'"
adb shell "su -c 'sleep 2'"
@echo Setting Permissions for Logical Link
@echo off
adb shell "su -c 'chmod ug+rwx /cache/download'"
adb shell "su -c 'chmod a+x /cache/download'"
adb shell "su -c 'sleep 2'"
@echo asop Market Fix complete!
PAUSE
RVDigital gave me some help as well
nathanielray said:
Does that mean I need to put "adb shell -c" on each line? Just once?
Click to expand...
Click to collapse
thank you very much, after so many years after your publication, I am now in 2020 also helped a lot)))) Hello from Russia with love )))
Excellent! It also came in handy for me. Thank you!
I'm trying to extract boot, recovery, system from my Rogers Notes, and need some clarification. Do I need to be rooted first? When I try now, I cannot access /dev/block to extract any image.
It seems all the root methods available somehow modifies the kernel or recovery or system, which kinda makes it impossible to extract stock images?
Help please
I have used adb to shell into the Note and extracted the various images. I'm looking for stock Rogers images. The ones DAGr8 posted still has the Telus brand on them.
c:\> adb shell
$ su
# dd if=/dev/block/mmcblk0p24 of=/sdcard/system.img
# dd if=/dev/block/mmcblk0p22 of=/sdcard/recovery.img
# dd if=/dev/block/mmcblk0p8 of=/sdcard/boot.img
# exit
c:\> adb pull /sdcard/system.img
c:\> adb pull /sdcard/recovery.img
c:\> adb pull /sdcard/boot.img
ha! i'm on the boat, i'm trying to extract all the original stuff before going crazy on it
just a few min ago i PMed DAGr8 for details
seems like you beat him to it
i know the radio was already done
so i'll just do those 3 mentioned above
firefly9 said:
c:\> adb shell
$ su
# dd if=/dev/block/mmcblk0p24 of=/sdcard/system.img
# dd if=/dev/block/mmcblk0p22 of=/sdcard/recovery.img
# dd if=/dev/block/mmcblk0p8 of=/sdcard/boot.img
# exit
c:\> adb pull /sdcard/system.img
c:\> adb pull /sdcard/recovery.img
c:\> adb pull /sdcard/boot.img
Click to expand...
Click to collapse
firefly9 said:
I have used adb to shell into the Note and extracted the various images. I'm looking for stock Rogers images. The ones DAGr8 posted still has the Telus brand on them.
c:\> adb shell
$ su
# dd if=/dev/block/mmcblk0p24 of=/sdcard/system.img
# dd if=/dev/block/mmcblk0p22 of=/sdcard/recovery.img
# dd if=/dev/block/mmcblk0p8 of=/sdcard/boot.img
# exit
c:\> adb pull /sdcard/system.img
c:\> adb pull /sdcard/recovery.img
c:\> adb pull /sdcard/boot.img
Click to expand...
Click to collapse
Once I get adb running do I just input the above commands into the command prompt?
Does the "adb pull" command just copy the images from the device or does it remove them?
Sorry for the basic adb questions. I've always had Nexus phones so I'm not sure if things work differently on other phones.
Once in the shell on the device, denoted by the "$" prompt, enter the commands outlined. After the "dd" commands have been completed, enter "exit" (twice, actually) and then the "adb pull" commands to copy the images from the device to you local computer. The images are copied so they will remain on the device until you delete them.
i find this easier...
adb shell dd if=/dev/block/mmcblk0p13 of=/sdcard/amss.bin
adb shell dd if=/dev/block/mmcblk0p17 of=/sdcard/mdm.bin
adb shell dd if=/dev/block/mmcblk0p24 of=/sdcard/system.img
adb shell dd if=/dev/block/mmcblk0p22 of=/sdcard/recovery.img
adb shell dd if=/dev/block/mmcblk0p8 of=/sdcard/boot.img
adb pull /sdcard/amss.bin
adb pull /sdcard/mdm.bin
adb pull /sdcard/system.img
adb pull /sdcard/recovery.img
adb pull /sdcard/boot.img
So I kinda messed up on my bootloader unlocked p769 and updated to v20f with no root on accident. However, I've decided that I want to go back to cm10.1 on jellybean v20d. How do I accomplish this? I don't have recovery or anything now. What's the easiest way to do this? Thanks
If anyone could help I'd be very grateful!
nfilipac said:
If anyone could help I'd be very grateful!
Click to expand...
Click to collapse
http://forum.xda-developers.com/showthread.php?t=2338816 root your phone
Download and copy following to the sdcard :
http://forum.xda-developers.com/showpost.php?p=40441852 (unzip p1.zip)
https://www.dropbox.com/s/gw74cg1ntwmwlij/cwmtouch.img
http://forum.xda-developers.com/showthread.php?t=2355816 cm10.1 for p769
from your computer:
Code:
adb shell su -c busybox dd if=/sdcard/external_sd/p1.bin of=/dev/block/mmcblk0p1
adb shell su -c busybox dd if=/sdcard/external_sd/p2.bin of=/dev/block/mmcblk0p2
adb shell su -c busybox dd if=/sdcard/external_sd/cwmtouch.img of=/dev/block/mmcblk0p4
adb reboot recovery
or phone
Code:
su
busybox dd if=/sdcard/external_sd/p1.bin of=/dev/block/mmcblk0p1
busybox dd if=/sdcard/external_sd/p2.bin of=/dev/block/mmcblk0p2
busybox dd if=/sdcard/external_sd/cwmtouch.img of=/dev/block/mmcblk0p4
reboot recovery
wipe data/cache/dalvik
install cm10.1
Lelus said:
http://forum.xda-developers.com/showthread.php?t=2338816 root your phone
Download and copy following to the sdcard :
http://forum.xda-developers.com/showpost.php?p=40441852 (unzip p1.zip)
https://www.dropbox.com/s/gw74cg1ntwmwlij/cwmtouch.img
http://forum.xda-developers.com/showthread.php?t=2355816 cm10.1 for p769
from your computer:
Code:
adb shell su -c busybox dd if=/sdcard/external_sd/p1.bin of=/dev/block/mmcblk0p1
adb shell su -c busybox dd if=/sdcard/external_sd/p2.bin of=/dev/block/mmcblk0p2
adb shell su -c busybox dd if=/sdcard/external_sd/cwmtouch.img of=/dev/block/mmcblk0p4
adb reboot recovery
or phone
Code:
su
busybox dd if=/sdcard/external_sd/p1.bin of=/dev/block/mmcblk0p1
busybox dd if=/sdcard/external_sd/p2.bin of=/dev/block/mmcblk0p2
busybox dd if=/sdcard/external_sd/cwmtouch.img of=/dev/block/mmcblk0p4
reboot recovery
wipe data/cache/dalvik
install cm10.1
Click to expand...
Click to collapse
Thank you very much, that's exactly what I was looking for! however, there's just a little problem... when i open superuser to see if it rooted properly, I get "There is no SU binary installed, and SuperSU cannot install it. This is a problem!" I've tried both the method you linked and this method http://forum.xda-developers.com/showthread.php?t=2173465 but i get the same results. I've rooted before, but i dont know what I'm doing wrong this time!
EDIT: Figured it out I'm a noob. Thanks!
Before 4.0 and 4.0
* Need IT's Rooted Device *
1. adb shell su -c "mount"
2. adb shell su -c "cat /proc/mtd
Now show list of your system img where stay
example : boot.img = /dev/block/mtdblock7
so you can pull out from there .. here ..
3. adb shell su -c "chmod 777 /dev/block/mtdblock7"
4. adb shell su -c "dd if=/dev/block/mtdblock7 of=/storage/sdcard0/boot.img"
(of=/storage/sdcard0/ .. this location may b change you can look at "mount" )
-----------------------------------------------------------------------------------------
After 4.1 or mmc
1. adb shell su -c "mount"
2. adb shell su -c "cat /cache/recovery/last_log"
Now show list of your system img where stay
example : boot.img = /dev/block/mmcblk0p7"
so you can pull out from there .. here ..
3. adb shell su -c "chmod 777 /dev/block/mmcblk0p7"
4. adb shell su -c "dd if=/dev/block/mtdblock7 of=/storage/sdcard0/boot.img"
(of=/storage/sdcard0/ .. this location may b change you can look at "mount" )
For someone dont' know
thanks all ...
I can't find any info on whether or not it's imperative , or possible to back up efs on this device. I typically always back them up when I am rooted bc it's my biggest fear in somehow getting corrupted or lost, and not having anyway to restore. There doesn't seem to be a topic anywhere on These boards (DNA) so I'm thinking it's either impossible to lose or very easy to restore lol. Anyone know for Sure ?
adb shell su -c "cat /proc/partitions"
adb shell su -c "cat /proc/emmc"
adb shell su -c "mkdir /sdcard/img"
adb shell su -c "dd if=/dev/block/platform/msm_sdcc.1/mmcblk0p18 of=/sdcard/img/radio_config.img"
adb shell su -c "dd if=/dev/block/platform/msm_sdcc.1/mmcblk0p22 of=/sdcard/img/modem_st1.img"
adb shell su -c "dd if=/dev/block/platform/msm_sdcc.1/mmcblk0p23 of=/sdcard/img/modem_st2.img"
mkdir efsbak
adb pull -p /sdcard/img/radio_config.img .\efsbak
adb pull -p /sdcard/img/modem_st1.img .\efsbak
adb pull -p /sdcard/img/modem_st2.img .\efsbak