• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!
  • Fill out your device list and let everyone know which phones you have!    Edit Your Device Inventory

[TOOL] Backup & Restore EFS on OnePlus 3

Search This thread

juliusedward

Senior Member
Aug 10, 2010
336
148
OnePlus One
OnePlus 3
Backup & Restore EFS on your OnePlus 3[Root Needed]

To Backup:
1) Enable USB Debugging Settings -> Developer Options -> USB Debugging.
If Developer Options not found, go to Settings -> About Phone and tap the build number rapidly 6-7 times till a toast comes up saying 'You're now a developer' . You will now see 'Developer Options' above About Phone in settings.
2) Download the attachment, extract it to a folder, connect your phone to PC through ADB, double click on 'BACKUP EFS.bat'. When it says 'Press any key...' just press any key on your keyboard! You'll see 'modemst1.bin' & 'modemst2.bin' files in the same folder where you extracted the ZIP, make more copies and backup of it! That's your EFS!
DONE!
Backup tested on OnePlus 3 OxygenOS version 3.1.2

To Restore:
1) Connect your phone in fastboot mode to PC, place your 'modemst1.bin' & 'modemst2.bin' in the extracted folder, double click on RESTORE EFS.bat'.

DONE!

I could not find any tool so far and apps from Play store fail to create a backup for OnePlus 3. So I have re-used the tool created by @Paresh Kalinani for OnePlus One and modified it to extract for OnePlus 3.

Credits:
@Paresh Kalinani for creating this simple tool for OnePlus One
@Signor Rossi for providing the partition information
@ahmadhas for testing restore
 

Attachments

  • EFS-Backup-Restore-OnePlus3.zip
    2.3 MB · Views: 4,149
Last edited:

kadett-k2

Senior Member
Feb 6, 2009
366
34
It doesnt work for me :(

I dont have rooted phone. Is that problem?
 

Attachments

  • efs.jpg
    efs.jpg
    39.6 KB · Views: 1,348
Last edited:

android_fury

Senior Member
Dec 24, 2014
131
43
For those running Linux, it's a lot easier

Don't even bother with the Windows tool. All it takes to backup the files is a working ADB connection and two commands:

This copies the info and creates the two files.
Code:
adb shell su -c "dd if=/dev/block/sdf1 of=/storage/self/primary/modemst1.bin bs=512"; adb shell su -c "dd if=/dev/block/sdf2 of=/storage/self/primary/modemst2.bin bs=512"

This copies the files to your current directory in the CLI.
Code:
adb pull /storage/self/primary/modemst1.bin; adb pull /storage/self/primary/modemst2.bin

I wasn't even able to get ADB to work in Windows. I installed the OP3 USB drivers, systemwide ADB/Fastboot tool, and still couldn't get it to work. I can see the phone fine in Windows, but ADB just refused to work. I then decided to inspect the BACKUP EFS.bat and RESTORE EFS.bat files to see what they were doing and it was just the two commands I posted here. If you're running Linux, don't waste your time fighting Windows to get this to work.

Restoring is the nearly the same. Run the following commands after connecting the phone via ADB.

Open a terminal in the directory where you saved the files you generated before and run this to copy them to the internal storage:
Code:
adb push modemst1.bin /storage/self/primary/modemst1.bin; adb push modemst2.bin /storage/self/primary/modemst2.bin

Then run this to flash the backups to the phone:
Code:
adb shell su -c "dd if=/storage/self/primary/modemst1.bin of=/dev/block/sdf1 bs=512"; adb shell su -c "dd if=/storage/self/primary/modemst2.bin of=/dev/block/sdf2 bs=512"


Damn, I love Linux.
 

JumboMan

Senior Member
Aug 3, 2013
561
219
Pink City
You can also backup your efs partition using terminal emulator. The guide can be found in oneplus.net forum.

Sent from my ONEPLUS A3003 using Tapatalk

@Naman Bhalla also posted terminal emulator method here on xda.
To backup you don't require pc ,just run given commands in terminal...but to restore you requires pc(as per Naman bhalla thread).
I have question in my mind that if it's possible to backup then why we can't restore backup just reversing command in terminal
 

Striatum_bdr

Senior Member
May 29, 2011
4,650
2,176
Marseille
what you mean by official TWRP.
is it possible to restore efs backup with TWRP.. if possible then plz tell me...i would like to know how to do this
Just like you backup and restore anything in twrp.
In backup screen you have EFS choice.
Then in restore screen you select the folder containing efs backup and voila...

Trivial.
 

JumboMan

Senior Member
Aug 3, 2013
561
219
Pink City
Just like you backup and restore anything in twrp.
In backup screen you have EFS choice.
Then in restore screen you select the folder containing efs backup and voila...

Trivial.

I just rebooted to TWRP(Grarak's) to see is there any such option but i don't see any option to backup or restore efs backup.
Can you link TWRP that can do efs backup or restore
 

Top Liked Posts

  • There are no posts matching your filters.
  • 23
    Backup & Restore EFS on your OnePlus 3[Root Needed]

    To Backup:
    1) Enable USB Debugging Settings -> Developer Options -> USB Debugging.
    If Developer Options not found, go to Settings -> About Phone and tap the build number rapidly 6-7 times till a toast comes up saying 'You're now a developer' . You will now see 'Developer Options' above About Phone in settings.
    2) Download the attachment, extract it to a folder, connect your phone to PC through ADB, double click on 'BACKUP EFS.bat'. When it says 'Press any key...' just press any key on your keyboard! You'll see 'modemst1.bin' & 'modemst2.bin' files in the same folder where you extracted the ZIP, make more copies and backup of it! That's your EFS!
    DONE!
    Backup tested on OnePlus 3 OxygenOS version 3.1.2

    To Restore:
    1) Connect your phone in fastboot mode to PC, place your 'modemst1.bin' & 'modemst2.bin' in the extracted folder, double click on RESTORE EFS.bat'.

    DONE!

    I could not find any tool so far and apps from Play store fail to create a backup for OnePlus 3. So I have re-used the tool created by @Paresh Kalinani for OnePlus One and modified it to extract for OnePlus 3.

    Credits:
    @Paresh Kalinani for creating this simple tool for OnePlus One
    @Signor Rossi for providing the partition information
    @ahmadhas for testing restore
    4
    Tested and can confirm Backup is working.
    Does not even need to boot into fastboot :)

    Like it
    4
    Don't restore using 'RESTORE EFS.bat'
    I tried it on mine and it would not even detect my sim card. I was able to get it working by flashing the backup files through fastboot mode.
    Here are the two simple commands you have to run (without quotes) in order to restore:
    <Go to the directory where you have the backup .bin files>
    "fastboot flash modemst1 modemst1.bin"
    "fastboot flash modemst2 modemst2.bin"
    2
    Glad that I could help and thanks for the tool. Will test it later today, when I got a Computer near me

    Gesendet von meinem OnePlus 3
    2
    It works!
    I backuped it successful!

    I restored it and it works!
    Tested sim card (calling, mobile data,...)
    But i used the two commands:


    fastboot flash modemst1 modemst1.bin

    and

    fastboot flash modemst2 modemst2.bin