Page 1 of 5 12345 LastLast
Results 1 to 10 of 50
Discuss [Backup/Restore] system on-the-fly at the Tools - Hackint0sh.org; I've figured out a way to backup and restore the iPhone system, with the help ...
  1. #1
    Senior Professional Array n000b's Avatar

    Join Date
    Mar 2007
    Posts
    117
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    16

    Default [Backup/Restore] system on-the-fly

    I've figured out a way to backup and restore the iPhone system, with the help of iPHUC. It can restore your system (activation, 3rd party apps, ringtones, wallpapers, etc) on-the-fly. Tested on 1.0.2, 1.1.1, and 1.1.2

    This method only works when iPHUC can putfile to your phone, which normally means the phone can still enter the normal mode, you can't do this when you're stuck at 'Connect to iTunes for recovery'.

    Preparation

    1. Before the backup/restore can be done, you have to setup a device node for the system partition. Enter the following command (in SSH shell):

    mknod /var/root/Media/rdisk0s1 c 14 1

    This creates a device node in user partition, which offers you the opportunity to restore the system when it mulfunctions.

    2. Install BSD Subsystem and OpenSSH on your phone so that you can login and do fixup after a restore.

    Backup the System

    To backup the current system partition, start the iPHUC, then enter the following command:

    getfile rdisk0s1 iphone_sys_dump 314572800

    It will take about 5 minutes to finish. This command dumps the current running iPhone system partition to a file named 'iphone_sys_dump', the file is 300MB in size. The dumped partition may later be used to restore your system to the current state. So keep it in a safe place.

    Restore the System

    If for some reason your phone doesn't work properly, and it's still in normal mode (not in recovery mode), start the iPHUC, then issue the following command to restore it:

    putfile iphone_sys_dump rdisk0s1

    The above command put back the dumped partition into the phone, it'll take about 1 minute to finish. When it's done, reboot the phone immediately.

    After the reboot, some data in the system (e.g. the file count) may not be correct. We need to fix the issue using SSH. Login to your phone, then enter the following commands:

    mount -u -o ro /
    fsck

    The first command remounts the system partition in read-only mode which allows fsck to fix any possible issues. The second command does the fix. Once the fsck is done, reboot your iPhone, it's now back to the state when the dump was made.

    Your user data will not be wiped during the system restore.

    Notes

    1. Do not use the above method to restore a different firmware version other than the one currently running on your phone, you may render the phone bricked if you try it and have to do a full restore to recover, which wipes out all your data.

    2. I use this method to quickly setup a new phone. First jailbreak the phone (no activation required), then restore a backup, after that, all the previously installed stuffs are ready to run. Some applications may require extra data (normally store under /var/root/Library), such applications will not run.

    E.g. Installer checks the data files in /var/root/Library/Installer, unless you upload the required files (LocalPackages.plist, RemotePackages.plist, PackageSources.plist and TrustedSources.plist) into that folder, it will not run.
    Last edited by n000b; 11-15-2007 at 06:00 AM.



  2. #2
    The Man Array aviegas's Avatar

    Join Date
    Sep 2007
    Posts
    1,108
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    73

    Default

    I've thought about the same thing, and that can be used to create install images too.

    The putfile is much faster, so creating the image may be a pain, but after that it is quite similar to a normal restore.

    Now the challenge is to find the right iphuc command to retrive disk2, aka the user disk.

    I'm already using this method to place tons of preinstaled apps in the iPhone. Works great.

  3. #3
    Senior Professional Array n000b's Avatar

    Join Date
    Mar 2007
    Posts
    117
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    16

    Default

    Retrieving user partition is possible I think, just issue the command:

    getfile /dev/disk0s2 user_data.dmg 7805304832

    I have no idea if iPHUC can deal with that INT64 value though.

  4. #4
    Rookie Array

    Join Date
    Sep 2007
    Posts
    22
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default

    I have a stable iPhone now. Does it mean that I can backup my phone now, them mess around with it by installing whatever apps and can still revered it back to it current stable condition?

    There are many apps that I love to try but if iPhone become unstable, I'll need to retore and jailbreak... to much effort.

  5. #5
    Rookie Array

    Join Date
    Nov 2007
    Posts
    22
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Arrow

    Hi, thanks for the great guide!

    First off, I have a 4gb iphone firmware 1.0.2 which I've jailbroken and unlocked.

    I've managed to copy off my filesystem, but i do get an error, "getfile: Failed to read from remote file: 12" it gets down to "Reading 33554432 bytes, 12582912 bytes remain", then gives the error.
    I've looked at the 256mb file it produces and its not all crap so thats something. Obviously dont want to restore with it though until im sure!

    I've also tried to do it on the user data (disk0s2), but i instantly get the error "getfile: Failed to read from remote file: 12" It also states File size: 3510337536
    I then tried again with this file size (i knew the 7gb would be wrong, but figured it might do something) but got the same error.

    Any ideas? I would really like to get these files off complete so I can set up new phones quickly.

    Thanks again,
    Limpwaster
    Last edited by limpwaster; 11-16-2007 at 01:33 PM. Reason: Added extra info


  6. #6
    Rookie Array

    Join Date
    Nov 2007
    Posts
    22
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default

    sorry to bump this, but anyone have the answer?

  7. #7
    Respected Professional Array Sassha's Avatar

    Join Date
    Jul 2007
    Location
    Croatia
    Posts
    687
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    46

    Default

    OK, if u make a dump of your stable unlocked iPhone, then if u mess something up and then make a "restore" with that dump u will stay unlocked and with all your data on iPhone,right? Just making it sure....

    And will this work in this way too?:

    Messed Up iPhone-->Restore via iTunes-->Jailbreak--->Restore "dump" via iPHUC--->Unlocked iPhone with all data.

    PS. Can u run commands with Putty or Terminal in WinSCP or it has to be iPhuc?
    Last edited by Sassha; 11-26-2007 at 01:59 PM.

  8. #8
    Respected Professional Array Sassha's Avatar

    Join Date
    Jul 2007
    Location
    Croatia
    Posts
    687
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    46

    Default

    _bump_....

  9. #9
    Amazingly Knowledgeable Array

    Join Date
    Oct 2007
    Posts
    803
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    47

    Default

    My rdisk0s1 file was 0 byte.

  10. #10
    Respected Professional Array Sassha's Avatar

    Join Date
    Jul 2007
    Location
    Croatia
    Posts
    687
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    46

    Default

    Quote Originally Posted by NotFound View Post
    My rdisk0s1 file was 0 byte.
    If U're on WIN try with this iPHUC, it solved that problem for me...

    http://upload.tr0gd0r.com/uploads/iphuc-win32.zip


 

 
Page 1 of 5 12345 LastLast

LinkBacks (?)


Similar Threads

  1. System backup with OS X + Win7
    By dell10 in forum Installation
    Replies: 0
    Last Post: 03-10-2010, 12:46 AM
  2. Replies: 1
    Last Post: 06-02-2009, 10:01 PM
  3. MacNN: BackBlaze reveals web-based system backup for Mac
    By hackint0sh in forum Latest Headlines
    Replies: 0
    Last Post: 12-10-2008, 02:00 AM
  4. Replies: 37
    Last Post: 08-11-2008, 03:15 PM
  5. Replies: 0
    Last Post: 04-30-2008, 08:20 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Powered by vBulletin®
Copyright © 2014 vBulletin Solutions, Inc. All rights reserved.
Search Engine Friendly URLs by vBSEO
(c) 2006-2012 Hackint0sh.org
All times are GMT +2. The time now is 01:10 PM.
twitter, follow us!