How To Backup efs Folder on Samsung Galaxy S and Restore nv_data.bin

Technology 2 Comments

As we all know that /efs folder keeps the sensitive and secret information of your phone such as IMEI Number and product code (which are stored in the encrypted form in nv_data.bin), Wireless devices MAC addresses and many more information. This info is secret to you and your precious device.

Sometimes, the users corrupt their secret data stored at this location when they unlock their phone or while changing the product codes.

And if you have a backup of this folder, it would be very easy for you to replace the files and folder with the corrupted one, if by chance it corrupts.

Candanga from xda has posted his method to do the same and we are presenting those steps here. The developer has tested this on his Samsung Galaxy S I9000

The foremost condition of this to work is that your phone must be rooted. Follow our below posts for this.
Rooting I9000
Rooting SGS2 I9100

The developer recommends that you should follow the below mentioned samsung galaxy s2 tips and tricks procedure with new smartphone having the Official ROM installed. But if you have flashed another ROM and its working fine then there’s no harm in backing that efs folder. You can refer this article for samsung galaxy s2 microphone problem.

Backup efs folder on SGS – Instructions

1. You need to have Terminal Emulator (that can be downloaded from Market) or ADB.

2. Please focus on the Samsung Galaxy S phone screen as it will ask you for SU permissions. In Terminal Emulator, you have to reset the app after giving the required permissions because normally it freezes.

3. For using ADB, Go to Applications –> Development and Enable USB Debugging. When you are done with the files, you need to off it so that you can get files.

su
tar zcvf /sdcard/efs-backup.tar.gz /efs (OR)
busybox tar zcvf /sdcard/efs-backup.tar.gz /efs

4. Now, you will have the file efs-backup.tar.gz in your Internal SD Card, which is a zip / tar file of ‘efs’ folder. This is your backup file of /efs folder. Congrats :)

5. You can also backup st13 under the /dev/block. It supports to recover the IMEI in case of screw-up.

su
cat /dev/block/stl3 > /sdcard/efs_dev-block-stl3.img (OR)
busybox cat /dev/block/stl3 > /sdcard/efs_dev-block-stl3.img

6. Here also, you will have this backup file in your Internal SD Card.

Restoring nv_data.bin on Samsung Galaxy S

In case by playing with nv_data.bin, your IMEI is screwed up and you are getting exceptions as below:
• Unable to download apps from Market
• Unable to lock SIM using you PIN
• Fake IMEI Number
• Some apps are downloading form Market on their own, without your permission.
• SIM card icon blinking
For all of above issues, you need to upload the fresh copy of this nv_data.bin file back to your mobile.

Instructions to restore nv_data.bin
1. Copy the file from the backup (efs-backup.tar.gz)

2. Paste the above backup file in Internal SD Card.

cp /sdcard/nv_data.bin /efs/nv_data.bin
rm -rf /efs/nv_data.bin.md5 (OR)
busybox rm -rf /efs/nv_data.bin.md5

3. Reboot your phone.

4. Most probably, now your SIM will not work and you will not be able to login into your phone. Please don’t be panic. We are with you :)

5. Pop off the SIM.

6. Boot your smartphone.

7. Run the below commands

su
busybox chown 1001:1001 /efs/nv_data.bin or
chown 1001:1001 /efs/nv_data.bin

The above commands will change the file ownership.

8. Try now :)

We are not responsible for (if any) damages. Please do at your risk.

All support is at xda thread

     
 

Author

- who has written 404 posts on TechOfWeb.

Atul is a professional blogger and techie who writes at TechOfWeb.

Subscribe to TechOfWeb feed via RSS || EMAIL || Twitter || Facebook to get instant latest tech updates.

Your Comments

2 Comments so far

  1. Oliver Rodrigues says:

    With regards to your post on EFS restore, thanks for the excellent instructions I managed to get IMEI back but noticed that it gets changed quiet frequently when I am on Gingerbread version so I downgraded my self to Froyo and I notice that the IMEI doesnt change, Could you kindly advise me so to get it working when I am on gingerbread. Does it have anything to do with bootloaders. The restore method I used is to flash via Odin and no other commands there on.

    ThanK You In advance.

  2. Benjamin says:

    Great guide!!

    Having just worked through ‘Restoring nv_data’ on my i9000 that i was forced to blat with Odin (back to Android 2.3.6) and was subsequently re-locked.

    (I also added a final step ‘Wipe Cache in Recovery’ from this other useful guide:
    http://www.communityhosting.net/sgsunlock/i9000.html – for good measure)

    Thank you, b


Share your view

Post a comment

© 2009-2013 TechOfWeb.