HOW TO: Backup Your Cydia Tweaks, Settings and Sources

Discussion in 'Jailbreaking & Hacking Tutorials & How-To Guides' started by willerz2, Feb 22, 2014.

  1. willerz2
    Offline

    willerz2 iPad Addict

    Joined:
    Feb 22, 2012
    Messages:
    1,264
    Thanks Received:
    233
    Trophy Points:
    63
    Location:
    New York
    Ratings:
    +246 / 0
    This guide is rarely applicable as the only time you would really use this is if you restore your jailbroken device, which is not something you'd want to do on an A5+ device since you can't downgrade. But, if you're planning to upgrade from a jailbroken state to the latest iOS that is jailbreakable, assuming all of your tweaks and settings are transferable to the latest iOS, you can use this to retain all tweaks and MOST of their settings.

    This will work for any and all device assuming after your restore, your device is jailbreakable, meaning all iPod Touch, iPad and iPhone generations above iOS 2.0.

    If the above was a little confusing, here's a list of possible scenarios that you may find this guide useful
    • Upgrading from iOS 5.X to iOS 6.X on an iPhone 3GS or iPhone 4 (assuming you have valid blobs and APTickets for the iPhone 4)
    • Upgrading from iOS 6.X to iOS 6.X on an iPhone 3GS or iPhone 4 (assuming you have valid blobs and APTickets for the iPhone 4)
    • Upgrading from iOS 7.X to iOS 7.Y on an iPhone 4 or newer (assuming 7.Y is jailbreakable as well and is the latest iOS being signed)
    • Upgrading from pre-iOS 5.1.1 to iOS 5.1.1 on an iPad 1
    The reason this list is fairly short is because not every tweak you have installed on the previous version may be usable on the iOS threshold above it, i.e. not all iOS 6 tweaks work on iOS 7 as they may not have received an update yet, or there's an iOS 7 exclusive version of the tweak, so using this method in a case like that is not the best of moves as you'll end up with a bit of a headache to fix. But within a threshold of upgrade, this guide will work to allow you to "transfer" your tweaks and Settings over after the restore. This is a free method as opposed to using tweaks such as PKGBackup or xBackup which runs you several dollars in the Cydia store, and essentially, it does 90-95% of the same thing that they do.

    What You'll Need:
    • OpenSSH
    • MobileTerminal or an SSH Client on your computer (PuTTy for Windows, CyberDuck or Terminal for Mac OSX)
    • SSH FTP client on your computer (WinSCP for Windows, CyberDuck for MacOSX)
    • Computer
    Step 1: Establish an SSH prompt connection to your device by logging in with your SSH credentials if you're using a computer, note that we're referring the an SSH command line, not the FTP client such as WinSCP. If you're using MobileTerminal, run the command 'su root' without the apostrophes, then enter your SSH password.

    [​IMG]

    Step 2: Run the command 'dpkg --get-selections> installed-pkgs.txt' without the apostrophes. Note that you can rename the 'installed-pkgs' portion with anything, it's just a name for the text file. This contains the list of installed packages including dependencies.

    [​IMG]

    Step 3: Navigate to /var/mobile/ using iFile or an FTP client such as WinSCP or CyberDuck, and transfer/copy your created .txt file over to your computer.

    [​IMG]

    Step 4: Navigate to /etc/apt/sources.list.d/, and transfer/copy Cydia.list to your computer. Do not rename this file as this is your list of sources that you have in Cydia.

    [​IMG]

    Step 5: Backup your device using iTunes, and restore your device. Your backup will retain 90-95% of your tweak settings (not all tweak settings are transferable as they're dynamically stored rather than statically stored)

    Step 6: Re-jailbreak your device using the appropriate utility.

    Step 7: Reinstall OpenSSH and MobileTerminal. If you want to use your computer to SSH, you don't need to install MobileTerminal and will only need OpenSSH. Also reinstall APT 0.7

    Step 8: Open your SSH FTP client, establish a connection again, and navigate back to /var/mobile/ and place your .txt file back in the directory.

    [​IMG]

    Step 9: Navigate back to /etc/apt/sources.list.d/ and place Cydia.list back into the directory.

    [​IMG]

    Step 10: Open up your SSH command terminal on your computer and re-establish a connection again. If you're running MobileTerminal, again, run the command 'su root' and enter your SSH password.

    Step 11: Run the command 'dpkg --set-selections< installed-pkgs.txt' or whatever your text file's name is without the apostrophe.

    Step 12: Run the command 'apt-get dselect-upgrade' without the apostrophe. Note that in this example on my iPod, I only had 2 upgrades available because I only have 2 packages that needs updating. On a freshly restored device, the number of newly installed will most likely match that of your installed packages previously. Some packages may not install and will appear as "Not Upgraded" because you may not have that source in your Cydia.list as you removed it from the source list prior to performing this.

    [​IMG]

    Step 13: Reboot your device.

    Upon a reboot, you may have to fidget around with some setting still as not all settings are backed up using iTunes. The majority (90-95%) of all tweaks in the entire Cydia store can be backed up, so the 90-95% does not mean 90-95 of your specific list of tweaks, it means 90-95% of all tweaks available in the entire Cydia store.

    [FIN]
    Last edited: Mar 11, 2014
  2. Kerean
    Offline

    Kerean iPF Novice

    Joined:
    Nov 19, 2011
    Messages:
    89
    Thanks Received:
    1
    Trophy Points:
    8
    Ratings:
    +1 / 0
    Great guide, I'm using it right now to restore after upgrading to 7.0.6. However, I think you left out a dash between dselect and upgrade in Step 12. Took me a while before I figured out what was wrong.

Share This Page

Search tags for this page

apt cydia dpkg misc ios 7

,

copy cydia sources and tweaks using computer

,

cydia backup

,

cydia settings location

,

cydia terminal preferences storage

,

how to backup cydia tweaks ssh