By bbaja42

2011-04-02 08:02:31 8 Comments

In attempt to install 2.2 I've deleted all my contacts(contacts were saved on phone, not as google contacts)
I've done full nandroid backup while phone still had those contacts; however when I try restoring image; I get bootloop.
Nandroid backup contains system.img, data.img, cache.img and boot.img;

I'm wondering if I can restore only data.img to get contacts back.

I have thought of 2 other solutions:

a) make a new nandroid image of current status; verify that it's ok by doing restart; then open copy database with contacts from one backup to another.

b) open database with contacts from data.img; and manually retype 200 phone records.

Is there any smarter (quicker, easier) way??


@Izzy 2013-08-07 16:49:13

There are also several apps available helping with a partial Nandroid restore:

They all give you the opportunity to extract parts of your Nandroid backup: Apps and their data, SMS, etc., and make the procedure a little easier.

@Craig 2011-08-10 19:11:58

You can use unyaffs to decompress a backup image, and then access the data directly. Here's a guide on how to do so.

@Matthew Read 2011-08-10 20:24:26

I didn't think of unyaffs here, good call. I added a good guide I found for it.

@valentt 2011-07-25 20:46:03

I couldn't mount data.img via mount -o loop :( Also restoring old data.img resulted in Android phone being stuck at Cyanogen logo screen and not loading Android OS fully :(

I managed to extract contacts from old backup by doing this:

  1. Install the Android SDK

  2. Boot into recovery mode

  3. Make full backup of your current system via Nandroid backup

  4. Restore /data partion of your old backup

  5. Boot into recovery mode

  6. Start adb server:

for Fedora
   $ su -
   # cd ~/android-sdk/tools
   # ./adb kill-server ./adb start-server
OR for Ubuntu
   $ sudo su
   # cd ~/android-sdk/tools
   # ./adb kill-server ./adb start-server
  1. Connect to your Android phone via adb SDK command

    ./adb shell

  2. Mount /data and /sdcard partition via Recovery menu on your phone

  3. Copy contacts from your old /data partition to your /sdcard partition

   # cp /data/data/ /sdcard/contacts2.db.old
  1. Unmount /data partition

  2. Format /data partition

  3. Restore your current /data partition from backup image

  4. Backup your current contacts database

    # cp /data/data/ /sdcard/contacts2.db.current
  1. Copy your old contacts over your current one
    # cp /sdcard/contacts2.db.old /data/data/

@Matthew Read 2011-04-02 14:37:41

Mount the image in your computer (Linux) or phone, extract the contacts database, and copy it over the contacts database in the phone. You do this using a loopback device, e.g. mount -o loop /sdcard/myimage.img myimage. "myimage" is where you can view the contents afterward. The database should be data/data/

You can restore the data for a single app by copying the relevant folder in /data/data/.

@FoleyIsGood 2011-04-02 08:29:42

Clockworkmod recovery has an 'Advanced Restore' option that allows you to pick just one of the following partitions: boot system data cache sd-ext

If you don't already have it, download ROM Manager from the market and this will help you install the clockworkmod recover.

(I've no idea whether this will solve your problem, but yes you can restore the data partition! ;) )

Related Questions

Sponsored Content

1 Answered Questions

Whatsapp Backup and Restore with number change and phone change

3 Answered Questions

Nandroid Backup restore fails with error 255

  • 2015-09-19 01:35:52
  • Rapti
  • 40112 View
  • 2 Score
  • 3 Answer
  • Tags:   twrp nandroid

1 Answered Questions

Restore nandroid backup on an other phone

1 Answered Questions

Recover wiped NANdroid backup - is it possible?

1 Answered Questions

Android restore bootstrap nandroid backup after a failed rom flash

2 Answered Questions

[SOLVED] Can I restore a nandroid backup that was made on an older OS?

2 Answered Questions

[SOLVED] How to restore nandroid?

1 Answered Questions

[SOLVED] Restore contacts from nandroid backup

2 Answered Questions

Sponsored Content