Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

idevicebackup2 restore doesn't work all the time

#338

Using head from git:

$ ./idevicebackup2 -u XXXUDIDHEREXXX restore /tmp/backups --settings Backup directory is "/tmp/backups"
Started "com.apple.mobilebackup2" service on port 49237.
Negotiated Protocol Version 2.1
Reading Info.plist from backup.
Starting Restore...
Restoring system files: No
Rebooting after restore: No
Don't copy backup: Yes
Preserve settings of device: No
Remove items that are not restored: No
Backup password: No
Sending 'XXXUDIDHEREXXX/Status.plist' (189 Bytes)
Sending 'XXXUDIDHEREXXX/Manifest.plist' (2.4 kB)
Sending 'XXXUDIDHEREXXX/Manifest.mbdb' (21.6 kB)
ErrorCode 102: Error moving incomplete restore directory into place at path "/var/.backup.i" (MBErrorDomain/102). Underlying error: The operation couldn’t be completed. (Cocoa error 516.) at path "/var/.backup.i" (NSCocoaErrorDomain/516). Underlying error: The operation couldn’t be completed. File exists (NSPOSIXErrorDomain/17)..

If I get one successful restore, it's without any options (--settings, or --system), and after that succeeds, NO other restores succeed, they all give this error. IOS 6, iPad 3 and iPod Touch both.

Here's the full debug output attached.

Reported by Christien Rioux · August 15th, 2013 @ 12:02 AM

State: open
Milestone: 1.4.0 Release
Assigned to: nobody

Activity

  1. Martin S.
    Martin S.
    • State changed from new to open
    • Tag set to ios 6, ipad 3, ipod touch, idevicebackup2
    • Milestone set to 1.4.0 Release

    Looks like you have some file "/var/.backup.i" on the device still left over from a previous restore/backup run.

    Are the devices jailbroken?
    Did this happen in previous backups, too?
    Did you initial backup complete fully and successfully?

    August 19th, 2013 @ 12:17 PM

  2. Christien Rioux
    Christien Rioux

    Yes, the devices are jailbroken.

    If ssh in and rm -rf /var/.backup.i it recreates /var/.backup.i and then fails.

    The backup is complete, no errors reported.

    If I do a plain 'restore', it works once, then fails the second time.
    If I do a --system or --settings restore, it never works, the first time or any other time.

    I am willing to test any patches/builds you may have for this.

    Thanks for looking into this, let me know if you need any other information.

    --chris

    August 19th, 2013 @ 12:32 PM

  3. Christien Rioux
    Christien Rioux

    More color on this: If you reboot the device with --reboot after the restore, it continues to work the second time, even with --system and --settings and whatever.

    If you do not reboot the device, it works once, and then fails the second time. It would seem that the 'rebooting' process does something to clear out this /var/.backup.i stuff.

    October 7th, 2013 @ 06:51 PM

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.