Wiping all Cydia Tweaks without Restoring and Rejailbreaking

Discussion in 'iPhone Jailbreaking' started by willerz2, Apr 22, 2013.

  1. willerz2

    willerz2 Super Moderator Staff Member

    Joined:
    Aug 15, 2012
    Messages:
    7,659
    Likes Received:
    648
    Trophy Points:
    113
    Location:
    New York
    Update 11.21.14: SemiRestore8 has been released to support iOS 8.1 and below devices

    This guide is compatible with iOS 4.0 through 7.0.6 on all devices for ILEX R.A.T., and iOS 5.0 through 8.1 on all devices for SemiRestore8.

    So this was brought up to me this morning during work when a few of my colleagues installed incompatible tweaks and would end up stuck on the Apple logo, and since they didn't have Safe Mode, they weren't able to remove the incompatible tweak. But, since they're just stuck on the Apple logo, and they had absolutely no clue what the name of the Cydia tweak was, it's difficult to remove the tweak..... So, with that, I used their phones as lab rats to try out ILEX R.A.T. (See what I did there?)

    The Catch:
    ILEX R.A.T. WILL brick your phone if you're using Siriports. If you installed ANYTHING remotely similar to Siriports/Fake Siris, etc, etc through Cydia, and you DO NOT remove it manually, I WILL 100% GUARANTEE that you WILL brick your device. GUARANTEED. If you have a Siriport, and you plan on using ILEX R.A.T., you MUST manually remove Siriports and replace all of its associated system mods. ILEX R.A.T. and SemiRestore WILL NOT resolve system file issues as a result of using the "Erase All Contents and Settings" function in Settings.


    What's iLEX R.A.T.?

    ILEX R.A.T. stands for Remove All Tweaks. Basically this removes each and every installed app, tweak and dependency EXCLUDING the defaults from Cydia, so after you've jailbroken your device a while back, and you installed your hundreds of packages, it'll all be removed with a single command.

    What this is primarily used for is if your device ends up in a state where you cannot enter Safe Mode since you don't have it, or if your device is stuck on any screen but is still recognized by your PC, or, if your device can be placed into Safe Mode and you can't remove the tweak for some reason. The bigger use for this would be the general request of "How do I clean my device of all jailbroken apps and start over without restoring". We've all had that thought run through our minds once our devices start to act sluggish.

    So say you have an iPhone 5, and you're on 6.1.2. Your device is acting sluggish, or you're giving it to a family member because you decide that you want a fresh out of the box iPhone 5 instead of your 5 month old iPhone 5. You want to wipe all your tweaks and such so that your successor can install what they please, but because the latest iOS is not jailbreakable, you don't want to restore, and since you have every single Cydia tweak installed, it'll take you ages to delete them all manually. This will be for you.

    This will work for all devices but has a few other requirements as well that you'll have to keep in mind when using ILEX R.A.T.

    Where Do I Start?


    The tweak is simple. Simple download, install, and respring manually. It's an few KB deb, nothing huge.


    Note: After extensive testing, I highly recommend that users avoid the ILEX R.A.T. GUI. The progression of the wiping is imperfect in the GUI, so you have to first make sure that your device is not going to sleep because that will pause the progression, and that in most cases, you will not be able to see what is on your screen, so you will not be warned when you are to reboot your device. The command terminal may be slightly more work in terms of setup, but is a safer route.


    Method 1- Removing only Cydia tweaks.

    To implement the R.A.T feature, you'll need to use a single command, "rat". How do you use the command? Well we have several options
    • MobileTerminal (you can install this free from the default Cydia repos)
    • PuTTy (for Windows users)
    • Terminal (default for OS X users)
    • iFunBox (both Windows and OS X users)
    • Any other utility that allows you to run commands from your PC
    (You can download MobileTerminal and iLEX RAT from the above repository)


    Once you need the feature, simple open up any of these prompts (enabling SSH may be required for utilities like PuTTy and such), and type in 'rat'. You don't have to actually have to enter your credentials for Root access. Simply have a connection between your command terminal to your device (or simple open up MobileTerminal on your device) and type in "rat" without quotes.

    Example would be the following command line:

    And run the command. Then follow the simple instructions that crop up on your screen. Make sure you heed all warnings and read carefully. It's basically just a series of "Y" and "N" options and such.

    [​IMG]

    So to remove all tweaks, once you've ran your command, type in "1", then tap Return. It'll start to compile a list of all tweaks and such that R.A.T will remove. When it asks for do you want to remove ILEX R.A.T, you can say Y or N, that's up to you. Saying Y will not cause your device to blow up, it'll just purge itself after the process. I'd say to say N so that just to keep it there as a future contingency plan.

    Next a prompt will come up warning you that all tweaks will be installed, but your jailbreak AND unlock will be retained (so yes, UltraSn0w and the Fixer, if applicable, will stay if you're relying on them). "Y" and return again.

    R.A.T will now go through the compiled list that its made and remove all the tweaks. This process will take a few minutes or more depending on how many tweaks you have installed. It'll then ask if you want to remove all tweak settings. "Y" if you just want to wipe and start fresh, "N" if you're going to re-install the same tweaks and such.


    Summarized Instructions:


    1. Open Command Terminal
    2. Type in "rat", return.
    3. "1", return
    4. "Y" or "N", return (Y to remove R.A.T along with everything, N to keep)
    5. "Y", return
    6. "Y" or "N", return (Y to delete all user settings, N to keep all user settings)
    7. Respring/reboot

    You're done. I recommend re-springing or rebooting your device as you would be prompted to when you uninstall a tweak from Cydia that affects the system files.



    Method 2- Removing everything except your barebone jailbreak

    This method is slightly different from the first method. The first method is used to strictly remove your jailbroken tweaks and settings. Method 2 however, allows you to wipe your device BUT keep your jailbreak. For many users, they're experiencing lag, slow performance, etc, etc., and they want to restore but yet keep their jailbreak, this feature basically replicates the "Erase All Contents and Settings" in Settings.app, BUT, if your device is jailbroken, using the stock version rather than this version will result in you being issues that will require you to do a manual DFU restore, meaning you'll lose your jailbreak and will have no way of turning back for A5+ users.

    [​IMG]

    Option 12. iLEX-RESTORE: Revive, Speed Up, Clean Up.

    Basically you follow the set-up instruction like method 1, except this time, instead of choosing option '1', you choose option '12'. Resulting in the below screen

    [​IMG]

    Remember that this option will wipe your device, and keep the jailbreak/UltraSn0w that's on your device (if applicable). Type in 'Y', Enter. And it should begin. It'll take a few minutes or longer depending on what you have on your but in the end, it'll wipe your device as if you tapped on the "Erase All Content and Settings" that you normally do not tap on a jailbroken device because it will mess up your device.

    Summarized Instructions:

    1. Open Command Terminal
    2. Type in "rat", return/enter
    3. "12", return/enter
    4. "Y", return/enter
    4A. "Y" or "N", return/enter (ILEX R.A.T. will ask whether or not you want to remove MobileTerminal as well if you're using MobileTerminal)
    5. Reboot

    ---------------------------------------------------------------------------------------------------------------------------------------------

    SemiRestore (iOS 5.0 - 8.1)

    Why use SemiRestore?

    SemiRestore8 works for all iOS 5, 6, 7 and 8 devices. I've tested this on several devices including ARM64 devices as well as the iPhone 6/6+, and none of them are experiencing boot loops or Recovery loops at all. Also unlike ILEX R.A.T., SemiRestore retains your Cydia user profile (User, Hacker, Developer) so you won't have to re-set it, it will retain truly crucial packages (which ILEX R.A.T. does as well, but ILEX R.A.T. also saves some residual data in some cases), and it utilizes OpenSSH. Though it utilizes OpenSSH, you will still need to plug your device in.

    What you will need

    • OpenSSH (installed through Cydia)
    • Your password to be changed back to the default password 'alpine' if you've changed it.
    • SemiRestore for Windows || Linux
    * Theoretically it should ask for your SSH password if you've changed it, but for the sake of ensuring a smooth process, I recommend changing it back to alpine, then changing it again afterwards.

    Note: The images are that of SemiRestore7, but it looks exactly the same for SemiRestore8, just that the text is changed from 7 to 8.

    Step 1: Extract SemiRestore

    [​IMG]

    Step 2:
    Run SemiRestore (as an administrator on Windows) and connect your device

    [​IMG]

    Step 3:
    Click on the SemiRestore button

    [​IMG]

    *At this point, if your SSH password is not the default 'alpine', SemiRestore will ask for you to input your password. If you've reverted it back to 'alpine', you won't have to do anything as it will progress to the next step.

    Step 4:
    You may or may not see this step. This step occurs extremely quickly so you may not see this.

    [​IMG]

    Step 5: Do not touch your device. Your device will be locked (if your lock timer has been exceeded) or you will see your Springboard if your lock timer has not been exceeded or it has been set to Never.

    [​IMG]

    Step 6: Do not touch your device. Your device will be locked (if your lock timer has been exceeded) or you will see your Springboard if your lock timer has not been exceeded or it has been set to Never.

    [​IMG]

    Step 7: Your device will now perform a reboot. This step is the longest. Depending on how much data is on your device, this can range from 5 minutes to 30 minutes if not more.

    [​IMG]

    Step 8: You're finished. You can now reinstall your packages and restore from an iTunes backup that you've made prior to utilizing SemiRestore.

    [​IMG]




    Disclaimer:
    I DO NOT own or take ANY credit for creating these utilities, nor do I take any cred for creating other utilities that are used to implement this tweak. Also, we DO NOT endorse the ILEX RAT owner's secondary repository, nor do I recommend using it. I take NO PART in any problems that arouse when you choose to use the secondary repo or from the utilization of these utilities.
     
    Last edited: Nov 21, 2014
    • Like Like x 6
  2. got556

    got556 New Member

    Joined:
    Apr 14, 2013
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    0
    This seems very handy to keep around and appreciate you posting this.
     
  3. willerz2

    willerz2 Super Moderator Staff Member

    Joined:
    Aug 15, 2012
    Messages:
    7,659
    Likes Received:
    648
    Trophy Points:
    113
    Location:
    New York
    Updated to include option 12, which simulates the "Erase All Contents and Settings" that you normally should not and would not use on a jailbroken device, except this method will work, and will allow you to retain your jailbreak.
     
    • Like Like x 2
  4. Dthom

    Dthom New Member

    Joined:
    May 23, 2012
    Messages:
    38
    Likes Received:
    3
    Trophy Points:
    0
    Sorry if this is the wrong spot to post but when I open mobile terminal and enter rat, it says command not found
     
  5. willerz2

    willerz2 Super Moderator Staff Member

    Joined:
    Aug 15, 2012
    Messages:
    7,659
    Likes Received:
    648
    Trophy Points:
    113
    Location:
    New York
    That's because you don't have the iLEX R.A.T. Package installed
     
  6. u8muhrice

    u8muhrice New Member

    Joined:
    Jun 17, 2013
    Messages:
    6
    Likes Received:
    1
    Trophy Points:
    0
    can anyone explain this to me as if I were 5 years old?

    I just bought a used jail broken iPhone 4 from a friend and I have no idea what I am doing. All I know is that Cydia is the main ap for jail breaking. I'm trying to reformat his iPhone so I can put my own apps in. I believe my friend has iOS 1.6.1 installed on this phone.

    Can anyone tell me how to even do the first step: First you'll need to add the following repository into Cydia.

    I dont even know how to add any commands. Do i plug in my iPhone in the computer or can I do it in the Cydia app?
     
  7. willerz2

    willerz2 Super Moderator Staff Member

    Joined:
    Aug 15, 2012
    Messages:
    7,659
    Likes Received:
    648
    Trophy Points:
    113
    Location:
    New York
    Added SemiRestore, an alternative but similar method to ILEX R.A.T. This method can be done via USB or SSH, and supports Windows, Mac OSX, SSH and Linux. The UI is very Evasi0n/Absinthe-esque. A single window, with a single button.
     
  8. pdx007

    pdx007 New Member

    Joined:
    Nov 16, 2012
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    0
    I used Semi- Restore. So do I have to rejailbreak? I don't have jailbreaks in the setting menu no longer like color keyboard. Help please.
     
  9. willerz2

    willerz2 Super Moderator Staff Member

    Joined:
    Aug 15, 2012
    Messages:
    7,659
    Likes Received:
    648
    Trophy Points:
    113
    Location:
    New York
    Semi-restore does not remove your jailbreak. Cydia should still be there, and other system based utilities such as iFile are still there.
     
  10. pdx007

    pdx007 New Member

    Joined:
    Nov 16, 2012
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    0
    OK, I understand the device is still jailbroken. How do I restore the jailbroken apps that were integrated into the settings menu like color keyboard. They have all disappeared after running semi-restore. Color keyboard does not have it's own stand alone icon, so I can't access it. I have retried uninstall and reinstall.
     
  11. willerz2

    willerz2 Super Moderator Staff Member

    Joined:
    Aug 15, 2012
    Messages:
    7,659
    Likes Received:
    648
    Trophy Points:
    113
    Location:
    New York
    You have to back it up first using something like xBackup or another backup utility from Cydia. Back up your jailbroken tweaks and sources, then backup the archive onto your computer. Use Semi-Restore or ILEX R.A.T. to wipe your device. Open up Cydia, download the backup utility again (xBackup, etc), put your archived folder back into the location that you got in from on your device. Open up the utility again, and restore from the archive. It takes anywhere from 5 minutes to an hour depending on how many packages are in the archive.

    It's not that they disappeared, they were wiped, hence the title "Wiping All Cydia Tweaks"
     
    • Like Like x 2
  12. britpoper

    britpoper New Member

    Joined:
    Aug 1, 2012
    Messages:
    29
    Likes Received:
    2
    Trophy Points:
    3
    Thanks so much for willerz for this post :D
    I was looking for something exactly like this. I want to give my iPhone5 to my sister, so I want to clean up all of my data, apps, settings etc without have to restore and jailbreak it again. Tested Semi restore and it work like a charm :D
     
  13. whiteyhd

    whiteyhd New Member

    Joined:
    Aug 4, 2013
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    0
    Hi, I was just wondering if this would clear just my jailbroken data, or all of my iphone data including other apps, contacts, messages, pictures, etc. Because I thought this might help my iphone problem, but I have a lot of important stuff and pictures from a holiday I just got back from and it isn't backed up, so want to make sure that that data would still be there to be recovered
     
  14. willerz2

    willerz2 Super Moderator Staff Member

    Joined:
    Aug 15, 2012
    Messages:
    7,659
    Likes Received:
    648
    Trophy Points:
    113
    Location:
    New York
    Depends on which method. ILEX RAT has the option to do so. But when it comes to restoring but retaining your jailbreak, it's best to do it after backing up your device and completely wiping it rather than keeping user data, just to be safe and sure that nothing goes wrong


    Sent from my iPhone via Tapatalk
     
  15. whiteyhd

    whiteyhd New Member

    Joined:
    Aug 4, 2013
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    0
    If ILEX RAT has the option to do so, then maybe that would be good. If my jailbreak has to go, i'm not too fussed as I know I can just jailbreak it again and it was a recent jailbreak, it's more my non- jailbreak data that I'm worried about. What would you suggest is the best one to go for? (sorry, I'm not a tech expert and just a guy in need of an urgent fix and is doing his best to learn as to how to fix it)
     

Share This Page