[Q] Can't restore back to stock rom - Android Q&A, Help & Troubleshooting

I made backup with cwm before installing custom rom. And then, accidentally, once again I made backup of the rom. So I deleted the latest backup from file manager. Now I want to revert back to stock but when i choosing the backup file its saying 'md5 Checksum mismatched'.
I searched about this and get across a thread about this problem (link)
I followed mentioned commands in thread using adb:
adb shell
# cd /sdcard/clockworkmod/backup/2010-06-29.20.22.53
# rm nandroid.md5
# md5sum *img > nandroid.md5
Now on the last command adb saying that 'md5sum not found'. cant figure out the problem.
One post I saw somewhere told me to install busybox and try command '# busybox md5sum *img > nandroid.md5'. But that also gone in vain.

Related

Something is wrong

I wanna install a custom ROm on my lg optimus one but something goes wrong. I installed z4root and rooted the phone. Then i installed terminal emulator and typed the specific code starting with su .The phone restarted and i pressed and kept pressing the 3 buttons (power+vol. down+home) but no menu apeared. I did the procedure 10 times but the menu didn't apeared. Am i doing something wrong or my pfone is brocken?
Did u copy paste all commands at once?
I did it manually tiping it by hang on my phone. I didn't coppy the text from my computer.
seems you didnt unzip the two recovery image files. Check it.
I unzipped all the files the image file, the recovery file, everithing. And i coppyedboth the zipped and the unzipped files
I checked it again and i have ony one recovery file and not 2... Which is the second recovery file?
Read this, I just instructed another user on how to upgrade to version 1.2 of the custom recovery. You should install it too. You will find links to the two files and the commands to type in the terminal.
Good luck!
flash_image.zip ??
I have flash_image zipped and unzipped
Use this: http://forum.xda-developers.com/showthread.php?t=971245
when i type the code it says:
$ su
# mount -o remount,rw -t yaffs2 /dev/block/mtdblock1 /system
# cat /sdcard/flash_image > /system/bin/flash_image
cannot create system/binflash_image: read-only file system
# chmod 755 /system/bin/flash_image
# mv /system/etc/install-recovery.sh /system/etc/install-recovery.sh.bak
# mount -o remount,ro -t yaffs2 /dev/block/mtdblock1 /system
# flash_image recovery /sdcard/LGp500-recovery-v12.img
# reboot recovery
Use what I told you and forget about those lines !
Try copy paste each command one by one....
I did just like here: http://forum.xda-developers.com/showthread.php?t=971245 but an error apeared: "windows cannot find groot.exe". I saw that there was anotxer member with the same problem but i didn't understood how to fix it.
try copy paste from stock browser on phone to terminal

[Q] Backup App Data using "tar" command

I am working on a tool to help make updating or switching ROMs easier. Now, before you say: "Just use Titanium." I am attempting an AiO solution. Anyway, the way it is currently set up is to use an sh script via AROMA to tar a backup. I want the script to be customizable so it calls upon a text file the user can edit, called "keep.txt". This can easily be done using the tar command, however, when I use it and the subsequent sh to restore the files, I get mixed result on full restoration.
Here is an excerpt from the backup script:
Code:
#REMOVE JUNK AND WHITESPACE
sed 's/#.*//' /sdcard/NU/keep.txt > /sdcard/NU/keep-tmp.txt
cat /sdcard/NU/keep-tmp.txt | sed '/^$/d;s/[[:blank:]]//g' > /sdcard/NU/keep-tmp2.txt
#TAR CUSTOM BACKUP
tar -cvpf /sdcard/NU/Backup/Custom.tar -T /sdcard/NU/keep-tmp2.txt
# MOVING TEMP FILES TO LOG FOLDER
mv /sdcard/NU/keep-tmp.txt /sdcard/NU/Logs/keep-tmp.txt
mv /sdcard/NU/keep-tmp2.txt /sdcard/NU/Logs/keep-tmp2.txt
The first line removes all commented lines while the second removes all whitespace to allow for a cleaner input.
The second line should tar the backup appropriately keeping permissions intact (if I'm not mistaken).
The file chunk is for cleanup. Should also be noted that all folders are made at the start of install by another sh file.
An example of keep.txt can be found here: keep.txt
Here is an excerpt from the restore script:
Code:
# DELETE OG FILES
for f in $(cat /sdcard/NU/Logs/keep-tmp2.txt) ; do
rm -r $f*
rm -f $f
done
# RESTORE
tar -xvpf /sdcard/NU/Backup/Custom.tar
I've recently begun erasing the existing folders just in case... But this does not solve my problem.
The second chunk obviously restores the files.
It has had some success, but it is hit and miss. I don't want to release it and have people losing precious data.
Any input is welcome! Thanks for reading! :highfive:

[Q] Galaxy mega signal problem and EFS deleted

Hello i need help.
I have galaxy mega GT i9200, Now i have updated it to 4.4.2 and my efs is deleted i dont know how.
Not phone have no imei and signals.
I followed youtube video about touch not working it worked but signal not coming .
I updated to megafires downloaded from this site.
pls tell me what to do for signal?
Did you have any previous backups of the system?
Did you try flashing the full stock ROM via PC Odin?
Sent from my GT-I9205 using Tapatalk
Yes
AndroidSlave said:
Did you have any previous backups of the system?
Did you try flashing the full stock ROM via PC Odin?
Sent from my GT-I9205 using Tapatalk
Click to expand...
Click to collapse
No i dont have any backup.
I installed ROM from sammobil 4.4.2 after that install touch was not working then i follow youtube video, now touch works but no signals..
An EFS backup is required , I guess!
I've restored a friend's efs, but it's a bit tricky and I don't know if it will work for you.
Note that you need to be rooted.
I guess you can't mount the efs folder while in recovery?
It happens sometimes when one changes ROM, the efs partition gets corrupted and changes from ext4 to swap.
The following works for Mega I9200 running JB, on KK you may have to change all the fields with mmcblk0p10 with whatever mount point efs has on KK.
To find out about it go to dev/block/platform/msm_sdcc.1/by-name and check which number efs has, or type in adb:
su
ls -al /dev/block/platform/msm_sdcc.1/by-name
Now you are ready to repair efs, let's go!
I - Connect you phone through adb, then type:
su
dd if=/dev/block/mmcblk0p10 of=/sdcard/efs.img
mke2fs /dev/block/mmcblk0p10
mkdir /efs
mount -t ext4 /dev/block/mmcblk0p10 /efs
DO NOT REBOOT YOUR PHONE
Now your efs is mounted and don't unmount it.
Check what's inside your efs and remember it for later in case you need to go to step II:
cd /efs
Reboot, your efs is fixed.
If everything works you are done, if it doesn't it means that some files inside the efs folder are missing or corrupted so now proceed to part II to rebuild it.
II - Type the following to recreate efs content (order may change depending the case, and for example if you /efs is empty you don't need the 2 first commands):
rm /efs/FactoryApp/keystr (this will erase keystr)
rm /efs/FactoryApp/factorymode (this will erase factorymode)
mkdir /efs/FactoryApp (this will recreate the FactoryApp folder in case you don't have any it anymore, if you still have it ignore this command)
echo -n ON >> /efs/FactoryApp/keystr (this recreates keystr)
echo -n ON >> /efs/FactoryApp/factorymode (this recreates factorymode)
chown 1000.1000 /efs/FactoryApp/keystr
chown 1000.1000 /efs/FactoryApp/factorymode
chmod 0744 /efs/FactoryApp/keystr
chmod 0744 /efs/FactoryApp/factorymode
reboot
Once everything works make an efs backup:
su
dd if=/dev/block/mmcblk0p10 of=/sdcard/efs.img
To restore efs:
su
dd if=/sdcard/efs.img of=/dev/block/mmcblk0p10
Good luck!

Extract files and permissions help?

Hi guys,
I'm trying to make some changes to an android box firmware. Ultimately what I'm trying to do is extract some files from a tar.gz into a folder on the root.
I have got as far as creating the directory on the root, and having a shell script run that extracts the files to the root folder. Problem is, the files aren't appearing in my folder.
This is what I've done so far:
1. Extracted the boot image in the firmware to edit "init.rc". I've made the changes so I can make my "test" folder with 777 permissions.
In the "on init" section of init.rc I have this:
Code:
mkdir /test 777
2. I've created the following script (test.h) that runs from init.amlogic.board.rc
Code:
#!/system/bin/sh
MARK=/data/local/test
if [ ! -e $MARK ]; then
echo "test script"
busybox tar -zxf /system/test.tar.gz -C /test/
touch $MARK
echo "OK, installation complete."
fi
This is the code in the init.amlogic.board.rc
Code:
service test_copy /system/bin/test.sh
user root
group root
disabled
oneshot
on property:sys.boot_completed=1
start test_copy
Once the box has booted I can see the "test_copy" file but the tar.gz files are not in my root folder.
The last thing I need is the files from the tar.gz to be 777 permissions.
Obviously I'm a complete noob at this, hope that makes sense and someone can help?

HELP how can fix Samsung GT-S6792L can't open E:/efs/log/boot_cause

Hi , i'm new in XDA , first i want to say, excuse me if i am posting in a wrong place, i can't find the right place for make a new thread.
I have a samsung S6792L fame lite, is stuck in samsung logo i make flash of stock rom via odin , stock rom (home.tar)1 file and flash stock rom of 4 files (Boot, Pda, phone , csc); then i flash a custom recovery (TWRP 2.8.6.0 for S6790) i mount efs partition but when i try open efs folder , the phone shut down and vibrate for 3- 4 seconds. also cannot do backup of efs folder because happen the same thing (shut down)
then i flash cwm recovery but in that recovery i can't make a backup of efs folder.
i can't find the PIT file for this model , and i don't know what can i do for solve this. please help.
thanks for your time.
(excuse me for my bad english)
Backup / Restore EFS Partition
@Kevin95ME
FYI: EFS partition is an encrypted one.
Assumed the path to EFS is /dev/block/mmcblk0p3. Note: This may not be correct path. It's on you to find the correct path.
You can backup EFS to internal storage running command
Code:
dd if=/dev/block/mmcblk0p3 of=/storage/sdcard/efs.img bs=4096
or you can backup EFS to external storage running command
Code:
dd if=/dev/block/mmcblk0p3 of=/storage/extSdCard/efs.img bs=4096
in a Terminal Window what creates file efs.img
To restore the EFS partition you run either command
Code:
dd if=/storage/sdcard/efs.img of=/dev/block/mmcblk0p3 bs=4096
or command
Code:
dd if=/storage/extSdCard/efs.img of=/dev/block/mmcblk0p3 bs=4096
in a Terminal Window what depends where you saved it.
jwoegerbauer said:
@Kevin95ME
FYI: EFS partition is an encrypted one.
Assumed the path to EFS is /dev/block/mmcblk0p3. Note: This may not be correct path. It's on you to find the correct path.
You can backup EFS to internal storage running command
Code:
dd if=/dev/block/mmcblk0p3 of=/storage/sdcard/efs.img bs=4096
or you can backup EFS to external storage running command
Code:
dd if=/dev/block/mmcblk0p3 of=/storage/extSdCard/efs.img bs=4096
in a Terminal Window what creates file efs.img
To restore the EFS partition you run either command
Code:
dd if=/storage/sdcard/efs.img of=/dev/block/mmcblk0p3 bs=4096
or command
Code:
dd if=/storage/extSdCard/efs.img of=/dev/block/mmcblk0p3 bs=4096
in a Terminal Window what depends where you saved it.
Click to expand...
Click to collapse
Hi thanks for answer,
excuse me for the newbie question, but, do i run terminal window on the TWRP recovery or adb shell?
Kevin95ME said:
Hi thanks for answer,
excuse me for the newbie question, but, do i run terminal window on the TWRP recovery or adb shell?
Click to expand...
Click to collapse
Terminal Emulator is an Android app you can get off Google Play Store.
jwoegerbauer said:
Terminal Emulator is an Android app you can get off Google Play Store.
Click to expand...
Click to collapse
ok lets me try. later i tell you the result. thanks
jwoegerbauer said:
Terminal Emulator is an Android app you can get off Google Play Store.
Click to expand...
Click to collapse
my friend thanks for you support i solve the problem doing this things in this order
first
i follow your step doing backup of my efs folder , but i modify the command
dd if=/dev/block/mmcblk0p3 of=/storage/extSdCard/efs.img bs=4096 ( your command)
dd if=/dev/block/mmcblk0p3 of=/sdcard1/efs.img bs=4096 (then i wrote this) ( with your command the terminal told me " no exist such file or directory")
(sdcard1 is ExtSdCard in S6792L)
then i save that efs file in my pc
second
i use the information on this post https://forum.xda-developers.com/showthread.php?t=2204960
this line of command
su
mke2fs /dev/block/mmcblk0p3
mount -w -t ext4 /dev/block/mmcblk0p3
reboot
third
i restore efs folder following your step, but modifying the command
dd if=/sdcard1/efs.img of=/dev/block/mmcblk0p3 bs=4096
the device is now on and pass the boot logo, right now i am deactivating the factory mode because show a yellow box showing ROM information.
i will use this information for deactivate that https://forum.xda-developers.com/galaxy-s3/general/how-to-fix-efailed-to-mount-efs-invalid-t2858056
Remove factory mode:
There are different methods that we can use to remove factory mode
In my case
1. Installed custom ROM to get root access
2. Instaled kTool
3. Copy the backup of my efs into sdcard (you can use .img or tar file)
4. Open kTool and restore the efs
5. Reboot the phone
* This method is the easiest and safest method because when you are getting the efs mount error there is a chance of loosing your IMEI and some other files, in that situation the following methods will not work.
OR
1. Root your phone (Either root manually or install a custom ROM)
2. Install ES File Explorer
3. Open ES File Explorer and turn on Root Explorer
4. Navigate to /efs folder
5. Open factorymode as txt in ES Note Editor
6. Change it from OFF to ON and save
7. Reboot your phone
OR
1. Root your phone (Either root manually or install a custom ROM)
2. Install Terminal Emulator
3. Run the following commands
Code:
su
rm /efs/FactoryApp/keystr
rm /efs/FactoryApp/factorymode
echo -n ON >> /efs/FactoryApp/keystr
echo -n ON >> /efs/FactoryApp/factorymode
chown 1000.1000 /efs/FactoryApp/keystr
chown 1000.1000 /efs/FactoryApp/factorymode
chmod 0744 /efs/FactoryApp/keystr
chmod 0744 /efs/FactoryApp/factorymode
thnaks so much for your support.
excuse formy bad english ,i do my best for improve it.
by the way i do all in the Terminal Command of the TWRP recovery.

Categories

Resources