Related
I spend all day today and can not find how can I made EFS RW. Am so hopless or it can not be done?
If you have Root Explorer, long press your copy of efs and select permissions.
Sent from my GT-I9100 using XDA Premium App
when i choose permissions it said that it can not be changed because the data system is read only
Tick the r/w tab on the top of Root Explorer when you open the program.
Sent from my GT-I9100 using XDA Premium App
i am trying to tick bit on efs folder it does nothing
the only think works id if from terminal i do
# busybox umount /efs
busybox umount /efs
# busybox mount -w /dev/block/mmcblk0p1 /e
busybox mount -w /dev/block/mmcblk0p1 /efs
after that i can delete the files from the efs and replace tham
but after couple of minutes they go back to the old versions and the efs became RO again
All this CL is too complicated. Just buy Root Explorer, much easier
mahatma said:
when i choose permissions it said that it can not be changed because the data system is read only
Click to expand...
Click to collapse
I have the same problem, Root Explorer can't change permissions.
Please help
I have now seen a number of cases of the EFS partition getting wiped / corrupted on the SGS II, leaving users with an effectively useless phone.
With this in mind, i've written a little init.d script for my ROM which backs up the EFS partition on boot if a backup does not already exist. A non intrusive safety net for users if you will.
The script just needs a suitable boot image that runs init.d, although it could easily be tacked onto the end of install-recovery.sh if that's not the case.
I'd love to encourage all developers to use this script for users' sake!
You can download the script here - http://cl.ly/2j0p0R3F07052m2T2u0e - but it's very simple, here's the code...
Code:
#!/system/bin/sh
# EFS auto backup script for Samsung Galaxy S II
# By @paulobrien - http://s2.MoDaCo.com
mount /dev/block/mmcblk0p11 /sdcard
if [ ! -f /sdcard/efs.autobackup.img ];
then
dd if=/dev/block/mmcblk0p1 of=/sdcard/efs.autobackup.img
fi
umount /sdcard
Note the manual mount / umount of sdcard is necessary because this happens late in the boot process.
Cheers!
P
Hats of to you Paul.Although I have already made a backup of my EFS folder,such a script would save MANY people from A LOT of trouble.
tolis626 said:
Hats of to you Paul.Although I have already made a backup of my EFS folder,such a script would save MANY people from A LOT of trouble.
Click to expand...
Click to collapse
i havent...never did. i think i wiped about a hundred times now and flashed and reflashed...is it possible to recover the efs folder?
haasgo said:
i havent...never did. i think i wiped about a hundred times now and flashed and reflashed...is it possible to recover the efs folder?
Click to expand...
Click to collapse
If your phone is working, it means your EFS partition is still there...
You can back it up using the many tutorials out there in the forum...
Sent from my GT-I9100 using XDA Premium App
Problem is that the users who read how to backup EFS folder fall in to two category s those that read up first and would have backed up EFS and those that only pick the manual up after something is broke .
This script would be a saver for many of the second group and big thanks to Paul and i hope devs do run with it .
jje
I would like to adapt your script for Nexus S.
Once i got the img file of efs partition, how do can a make a script for restoring thet img file to efs partition?
Or what to do with that img file?
EDIT: @ paul - One more question - how do I mount /sdcard on Nexus S through the script? mount command in the Terminal Emulator shows my /dev/blocks/vold/179:3 as mount point, but if I use that mount point in the script it won't mount the /sdcard. Any idea?
EDIT2: I got it working with this command:
mount /dev/block/platform/s3c-sdhci.0/by-name/media /sdcard
and I got the efs.autobackup.img on my sdcard.
How do I restore the efs.autobackup.img to efs partition?
Thanks Paul this is a very useful utility hope it gets sticky
May i ask what conditions these people are falling foul of getting the EFS wiped? Is it rouge roms/cwm zips, wiping to much in recovery, Odin flashing?
Curious so i may steer clear, have a backup but staying away is half the battle
paulobrien said:
You can download the script here - http://cl.ly/2j0p0R3F07052m2T2u0e - but it's very simple, here's the code...
Code:
#!/system/bin/sh
# EFS auto backup script for Samsung Galaxy S II
# By @paulobrien - http://s2.MoDaCo.com
mount /dev/block/mmcblk0p11 /sdcard
if [ ! -f /sdcard/efs.autobackup.img ];
then
dd if=/dev/block/mmcblk0p1 of=/sdcard/efs.autobackup.img
fi
umount /sdcard
Click to expand...
Click to collapse
Hi Paul, I have modified your script so that it makes a tar file, tar file keeps the permissions for the efs partition and its easier to restore. Here it is:
Code:
#!/system/bin/sh
# EFS auto backup script for Samsung Galaxy S II
# By @paulobrien - http://s2.MoDaCo.com
mount /dev/block/mmcblk0p11 /sdcard
if [ ! -f /sdcard/efs_autobackup/efs-backup.tar.gz ];
then
mkdir /mnt/sdcard/efs_autobackup
busybox tar zcvf /sdcard/efs_autobackup/efs-backup.tar.gz /efs
fi
umount /sdcard
mynamesteve said:
Thanks Paul this is a very useful utility hope it gets sticky
May i ask what conditions these people are falling foul of getting the EFS wiped? Is it rouge roms/cwm zips, wiping to much in recovery, Odin flashing?
Curious so i may steer clear, have a backup but staying away is half the battle
Click to expand...
Click to collapse
Some hit "wipe EFS" in ODIN.
It's possible to mess up a zip badly enough to wipe EFS
A normal wipe shouldn't do it, but a bad CWM build could in theory do it...
A dodgy "virus" could do it, if it were targetting rooted phones, or had a root exploit.
That's why I keep an EFS backup on my PC and off-site
brainmaster said:
Hi Paul, I have modified your script so that it makes a tar file, tar file keeps the permissions for the efs partition and its easier to restore.
Click to expand...
Click to collapse
Nope dd is much better, but safer to have both, but dd should be used with bs=4096k option.
how to restore the efs folder?
how to restore the efs folder?
Please, need to restore EFS, not sure what happened but tried installing Cognition R3 and lost my EFS, I do however have a prior efs.autobackup. Please help.
I saw a thread on the international S2 forum regarding the importance of backing up the /efs folder on the phone so you don't lose the phones imei. I was wondering if this is still a necessity on our phone as well? And if so is there a different process to do it than what they used? They used terminal commands to back it up using terminal Emulator or ADB.
This is the thread:
http://forum.xda-developers.com/showthread.php?t=1068193
Its very important..ask me..i lost my IMEI and dint have a back up of the efs folder..had to go to the store and get a new phone under warranty.
Please make a backup of it.
After 2 months, someone just had EFS corruption last week - so yes, now I think it's a good idea to back it up.
IMO it would be a good idea to image the partition too...
Entropy512 said:
IMO it would be a good idea to image the partition too...
Click to expand...
Click to collapse
Can you verify the partition? Is 0p3 the right one, or is it 0p1? I coundn't find a definitive answer by searching.
For some reason I thought it was p3, but I was wrong. It's p1:
Code:
/dev/block/mmcblk0p1 on /efs type ext4 (rw,nosuid,nodev,noatime,barrier=1,journal_checksum,data=ordered)
To back it up, get ADB working, and run the following using ADB while the phone is in CWM recovery and /sdcard is mounted (It often is not when you first enter CWM, mount it in the Mounts and Storage menu if it is not) (If you do this when the phone is running, you may back it up as it is getting written to, which could result in a bogus backup)
Code:
adb shell dd if=/dev/block/mmcblk0p1 of=/sdcard/efs_backup.img
Thanks for the verification entropy!
Sent from my SAMSUNG-SGH-I777 using XDA App
Entropy512 said:
Code:
/dev/block/mmcblk0p1 on /efs type ext4 (rw,nosuid,nodev,noatime,barrier=1,journal_checksum,data=ordered)
Click to expand...
Click to collapse
I don't know much about linux commands. Is this how you verified the partition?
Also, am I correct in assuming that if the partition is backed up, it would not be necessary to back up the efs directory using a file explorer? Or is there a reason to have both?
You can also run the command from entropy in terminal emulator on your phone. Do su first to get root and enter the dd command to do your backup.
Sent from my SGH-I777
creepyncrawly said:
I don't know much about linux commands. Is this how you verified the partition?
Also, am I correct in assuming that if the partition is backed up, it would not be necessary to back up the efs directory using a file explorer? Or is there a reason to have both?
Click to expand...
Click to collapse
I verified it by executing the following command and looking at the output:
Code:
mount
It may be easier to restore a folder backup - not sure. A partition backup is the best way to guarantee you got EVERYTHING in that partition, byte-for-byte.
That's crazy. Cause I don't understand how you learn stuff like that but thanks(aka I'm gonna go do this since I mess with my phone alot.) I followed amk28's troubles. What's the difference between efs backup pro and this mehod? They both backup images
Entropy512 said:
For some reason I thought it was p3, but I was wrong. It's p1:
Code:
/dev/block/mmcblk0p1 on /efs type ext4 (rw,nosuid,nodev,noatime,barrier=1,journal_checksum,data=ordered)
To back it up, get ADB working, and run the following using ADB while the phone is in CWM recovery and /sdcard is mounted (It often is not when you first enter CWM, mount it in the Mounts and Storage menu if it is not) (If you do this when the phone is running, you may back it up as it is getting written to, which could result in a bogus backup)
Code:
adb shell dd if=/dev/block/mmcblk0p1 of=/sdcard/efs_backup.img
Click to expand...
Click to collapse
Sent from my SAMSUNG-SGH-I777 using XDA App
Okay, so basically as the title says, I want to get back to rfs since I want to use cwm, and because ever since I flashed icy fusion I don't even get the speed benefits of ext4, even though all my partitions are supposedly still in ext4 format (weid, I know). Now I don't want to lose my data, and for some reason my Odin packages I try to make never work and just brick my device, so here is my idea. Could I make dumps of my partitions using terminal emulator, then somehow flash those using cwm? Or is it not possible? Thank You.
Sent using Tapatalk
iJimaniac said:
Okay, so basically as the title says, I want to get back to rfs since I want to use cwm, and because ever since I flashed icy fusion I don't even get the speed benefits of ext4, even though all my partitions are supposedly still in ext4 format (weid, I know). Now I don't want to lose my data, and for some reason my Odin packages I try to make never work and just brick my device, so here is my idea. Could I make dumps of my partitions using terminal emulator, then somehow flash those using cwm? Or is it not possible? Thank You.
Sent using Tapatalk
Click to expand...
Click to collapse
Well, klin's kernel works with cwm, so if you make a backup from there (or use an existing backup), rename it from .ext4 to .rfs (basically using the ext4 converting instructions in reverse), you *should* be able to get back to rfs. To answer your second question, yes, you can dump your partitions, but you would need to create an odin-flashable package with them, and dd (the command you would use) dumps retain the filesystem (so ext4 dumps are flashed as ext4, and so on).
Yes, but am I correct in thinking if I enter cwm to create a nandroid, my data partition will be wiped because of the cwm bug with ext4? What I am trying to do is make a backup without losing my data. I might just have to lose my data and restore apps with titanium backup.
Sent using Tapatalk
iJimaniac said:
Yes, but am I correct in thinking if I enter cwm to create a nandroid, my data partition will be wiped because of the cwm bug with ext4? What I am trying to do is make a backup without losing my data. I might just have to lose my data and restore apps with titanium backup.
Sent using Tapatalk
Click to expand...
Click to collapse
Klin's kernel's CWM seems to NOT wipe your data, at least in my experience, so you should be good to go if you flash it.
hanthesolo said:
Klin's kernel's CWM seems to NOT wipe your data, at least in my experience, so you should be good to go if you flash it.
Click to expand...
Click to collapse
Hmm, I didn't realize that, thanks for the tip!
Sent using Tapatalk
http://forum.xda-developers.com/showthread.php?t=1620255
Hey, I just saw this on the portal, looks like it could be a solution to the problem?
Sent using Tapatalk
Okay so, true to your word, klin's r3 doesn't have the bug. Unfortunately I now get an error when I try making a nandroid. It gets to "backing up /cache..." then gives me " Unable to find mounted volume: /cache
Error finding an appropriate handler" and immediately returns to the main menu without finishing the nandroid. Any ideas what to do? Would wiping cache be safe with this problem?
Some updates: wiping cache did nothing to fix the problem. I can dump the cache partition fine using terminal emulator and the dd command. When I use the "mount" command, cache is not listed in the partitions.
This is starting to creep me out. I think something to do with it is after flashing icyfusion going from klassic r5 with all partitions converted to ext4, I started getting rfs-like io preformance (quadrant benchmarks), even though "mount" said all partitions are still ext4.
Sent using Tapatalk
If you want to get back to rfs that bad do the following.
1. make a nandroid backup
2. change the .ext4 to rfs like when you want to convert
3. flash the total recovery method with the STOCK kernel.
4. Then flash a kernel that supports the .tar backup (klin or terrasilent)
5. restore your backup and you should be in rfs with your backup.
Me I use terrasilent and I don't lose data when I backup. Maybe when you change the .ext4 to .rfs try to unmount using the computer before the device.
Well, if you read my above posts you can see that I can't make a nandroid because of something concerning the cache partition. It cancels there. Thank you for replying!
Sent using Tapatalk
iJimaniac said:
Well, if you read my above posts you can see that I can't make a nandroid because of something concerning the cache partition. It cancels there. Thank you for replying!
Sent using Tapatalk
Click to expand...
Click to collapse
Oh didin't read the cache part... Hmm you can always make a backup of your data partition and then make a nandroid backup from terrasilent.
I am not exactly sure if it is the kernal's fault, or something messed up with partitions. I doubt terrasilent would fix it. I have also now tried restoring the cache partition from a previous nandroid, and it restores (I guess), but it still gives me the same error when backing up.
Sent using Tapatalk
Sorry for abandoning this thread, I forgot about it . Perhaps you can mount it manually? Try using the partition listed when you are booted into android to mount it eg. Mount /Dev/block/stlx. I also suppose that to fix all of this easily, you can return to stock with a pit, but you will have too have a backup of your data.
I tried and get:
# mount /Dev/block/st11
mount: can't find /Dev/block/st11 in /etc/fstab
Sent using Tapatalk
iJimaniac said:
I tried and get:
# mount /Dev/block/st11
mount: can't find /Dev/block/st11 in /etc/fstab
Sent using Tapatalk
Click to expand...
Click to collapse
its stl not st
zaclimon said:
its stl not st
Click to expand...
Click to collapse
Whoops, typo, here is direct copy/paste from terminal emulator;
$ export PATH=/data/local/bin:$PATH
$ su
# mount /Dev/block/stl11
mount: can't find /Dev/block/stl11 in /etc/fstab
#
Sent using Tapatalk
iJimaniac said:
Whoops, typo, here is direct copy/paste from terminal emulator;
$ export PATH=/data/local/bin:$PATH
$ su
# mount /Dev/block/stl11
mount: can't find /Dev/block/stl11 in /etc/fstab
#
Sent using Tapatalk
Click to expand...
Click to collapse
it's because of the caps *d*. You should write
# mount /dev/block/stl11
Same result:
$ export PATH=/data/local/bin:$PATH
$ su
# mount /dev/block/stl11
mount: can't find /dev/block/stl11 in /etc/fstab
#
Sent using Tapatalk
iJimaniac said:
Same result:
$ export PATH=/data/local/bin:$PATH
$ su
# mount /dev/block/stl11
mount: can't find /dev/block/stl11 in /etc/fstab
#
Sent using Tapatalk
Click to expand...
Click to collapse
can you send me your /etc/recovery.fstab to see if /cache is in it? and which rom are you using?
Umm, I don't have a recovery.fstab, just a "vold.fstab" and a "fstab". I am using icy fusion.
Sent using Tapatalk
How to know the mount points using terminal emulator ???
I guess i dont have mtd partition. How to check that too ?
I really wanna know my mount points
I have karbonn a21 running ics 4.0.4
Sent from my A21 using xda app-developers app
Nishchay1 said:
How to know the mount points using terminal emulator ???
I guess i dont have mtd partition. How to check that too ?
I really wanna know my mount points
I have karbonn a21 running ics 4.0.4
Sent from my A21 using xda app-developers app
Click to expand...
Click to collapse
There are a couple commands you can run:
cat /proc/mtd
That will give you the mount points if you have a mtd device. If it says not found then you know your device isn't using mtd.
Another command to find the mount points is:
mount
You can also do:
dev/block/platform
Then:
ls
Then cd into the folder for the processor kind. For example on the US version of the Galaxy S3 it's msm_sdcc.1. Then cd into the "by-name" directory and then type ls -l to list the partitions and there mount points. Let me know if you still have questions .
Sent from my SCH-I535 using xda premium
shimp208 said:
There are a couple commands you can run:
cat /proc/mtd
That will give you the mount points if you have a mtd device. If it says not found then you know your device isn't using mtd.
Another command to find the mount points is:
mount
You can also do:
dev/block/platform
Then:
ls
Then cd into the folder for the processor kind. For example on the US version of the Galaxy S3 it's msm_sdcc.1. Then cd into the "by-name" directory and then type ls -l to list the partitions and there mount points. Let me know if you still have questions .
Sent from my SCH-I535 using xda premium
Click to expand...
Click to collapse
Thank you!
I've been trying to find the mountings for my Padfone 2 for many hours untill I finally found this, and at last! something finally worked!
brother @shimp208 can u say me the mount points of boot and others from the below screenshot ............. and thanks in advance...
princemouli said:
brother shimp208 can u say me the mount points of boot and others from the below screenshot ............. and thanks in advance...
Click to expand...
Click to collapse
Please cd into the by-name directory rather then by-num then run ls -la from that directory.
Sent from my SCH-I535 using XDA Premium 4 mobile app
Looks like he only has a by-num
Try
cat /proc/mounts
Or maybe
busybox df -hm
Sent from my Nexus 4 using XDA Premium 4 mobile app
In addition to what demkantor said you can also boot your device into recovery mode, wipe your devices cache, then reboot the phone which should create a last_log file that should contain the partition names, this file can be read by running the following command:
Code:
cat /cache/recovery/last_log
brother @shimp208 i did every thing as u said but i didnt found the mount points of boot and recovery i even saw in recovery.fstab but i didnt found mnts of boot and recovery....... is there any other ideas to find them......
princemouli said:
brother @shimp208 i did every thing as u said but i didnt found the mount points of boot and recovery i even saw in recovery.fstab but i didnt found mnts of boot and recovery....... is there any other ideas to find them......
Click to expand...
Click to collapse
Can you post the full output of the cat /cache/recovery/last_log command (You can also use adb shell and copy and paste it's output)? Also did you try the commands demkantor suggested?
brother @shimp208 here is my recovery log and others............ i need mount point of boot and recovery......
princemouli said:
brother @shimp208 here is my recovery log and others............ i need mount point of boot and recovery......
Click to expand...
Click to collapse
The path to your boot partition is:
Code:
/dev/bootimg
The path to your recovery partition is:
Code:
/dev/recovery
If you wanted to dump these partitions you could run the commands from terminal emulator or adb shell as root:
Code:
cat /dev/bootimg > /mnt/sdcard/boot.img
cat /dev/recovery > /mnt/sdcard/recovery.img
Let me know if this is the information your looking for or not.