iOS 4.0 [Tutorial] How to use swap file for ipod touch (iMemoryEnhancer alternative)

Discussion in 'iOS Jailbreak & Cydia' started by arsenal1312, Aug 22, 2010.

  1. arsenal1312

    arsenal1312 New Member

    Joined:
    Jul 9, 2010
    Messages:
    131
    Likes Received:
    0
    Device:
    4G iPod touch
    If you think that iMemoryEnhancer is too risky and unstable to use (causes boot loop, brick device...) then creating a swap file to use as a virtual memory is a perfect solution. What it does is that it simply is a daemon that will use a portion of your flash drive as virtual ram. Unlike swap file, iMemoryEnhancer not only use flash drive but it also does other stuff (that idk) that can cause boot loop and other damages.
    Ok here are the steps:

    1) Navigate to /System/Library/LaunchDaemons/ using iFile.

    2) Create a new file and name it 'com.apple.dynamic_pager.plist', set the 'owner' as 'root' and the 'group' as 'wheel', the rest leave them at default.

    3) SSH into that plist file u just created, open it with notepad and add the following code then save it:

    Code:
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
    <plist version="1.0">
    <dict>
    <key>Label</key>
    <string>com.apple.dynamic_pager</string>
    <key>KeepAlive</key>
    <true/>
    <key>OnDemand</key>
    <false/>
    <key>ProgramArguments</key>
    <array>
    <string>/sbin/dynamic_pager</string>
    <string>-F</string>
    <string>/private/var/vm/iphone_swap</string>
    </array>
    <key>RunAtLoad</key>
    <true/>
    <key>UseEncryptedSwap</key>
    <false/>
    </dict>
    </plist>
    4) SSH into "/private/var/preferences/" and create a file named "com.apple.virtualMemory.plist" with he same properties as the other one.

    5) Copy and paste this into the new file, then save it:

    Code:
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN"
    "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
    <plist version="1.0">
    <dict>
     <key>UseEncryptedSwap</key>
     <false/>
    </dict>
    </plist>
    6) Reboot ur ipod touch IMMEDIATELY.

    7) Use "Free Memory" function in SBSSettings. At first, u'll see that the amount of free memory will drop to 29-30MB, but then after 5-6 seconds it will go back up to 75-85 MB.

    8) Enjoy new speed

    Please Register or Log in to view images

  2. tinyman392

    tinyman392 Super Moderator Staff Member

    Joined:
    Jul 10, 2008
    Messages:
    16,012
    Likes Received:
    1,380
    Device:
    iPhone 6
    I can say that this works 100%, used it with 3.x about 3 times (updates) and with 4.x once (Will use it again when 4.1 is jailbroken).

    Also to add, this plist method is Apple's way of implementing VM.
  3. arsenal1312

    arsenal1312 New Member

    Joined:
    Jul 9, 2010
    Messages:
    131
    Likes Received:
    0
    Device:
    4G iPod touch
    My ipod touch is a 2G MC Model 8GB, by the way.
  4. XxRedRumxX

    XxRedRumxX Well-Known Member

    Joined:
    Dec 18, 2009
    Messages:
    6,666
    Likes Received:
    1,079
    Device:
    Samsung Galaxy Nexus
    I wouldnt think that the device makes much of a difference (except if it was a 3g ipod or iphone 4 or somethin)
  5. Nburnes

    Nburnes Well-Known Member

    Joined:
    Jan 3, 2009
    Messages:
    9,022
    Likes Received:
    767
    Device:
    OnePlus One
  6. xX-SicKsKiLZz-Xx

    xX-SicKsKiLZz-Xx Active Member

    Joined:
    Jun 19, 2010
    Messages:
    2,871
    Likes Received:
    4
    Device:
    iPhone 4S (White)
    sorry, but this is the EXACT same thing that imemory enhancer does, except in imemory enhancer you dont need to ssh etc, you just need to install.
  7. arsenal1312

    arsenal1312 New Member

    Joined:
    Jul 9, 2010
    Messages:
    131
    Likes Received:
    0
    Device:
    4G iPod touch
    many ppl reported that imemory enhancer causes boot loop and brick their devices. This method does not cause those
    ------------------double post merged------------------
    sorry but the com.apple.dynamic_pager.plist for ipad is totally different with the one for ipod touch. I used the code in your first link for the com.apple.dynamic_pager.plist but it froze my device when i 'free memory'. The one i posted is the code in the 2nd link, and the file com.apple.virtualMemory.plist is from the 1st link. So this tutorial is kinda the combination of both
  8. iBricked

    iBricked Well-Known Member

    Joined:
    Apr 16, 2010
    Messages:
    5,874
    Likes Received:
    39
    Device:
    iPhone 5S
    This is the exact same one as the ipad version, we do not need these many threads about tis kinda thing.
  9. HavokD

    HavokD New Member

    Joined:
    Jul 5, 2010
    Messages:
    57
    Likes Received:
    0
    Device:
    3G iPod touch
    I actually have this tweak installed on my iPT, and I must say that it is indeed SAFE! It works as intended, gives you a lot of free ram, tho it freezes the device for a couple of seconds when "Free Memory" is called, since it dumps some data into the Swap File.

    I have implemented and reimplemented this method two or three times on my device and I have never experienced any kind of bootloop or problem whatsoever, so instead of throwing a coin with iMemory Enhancer, do you a favor and use this method instead. Just to add, I have been using this method for almost a month and I have seen no performance decrease at all, on the contrary, the device is snappier than ever.
  10. metalmilitia

    metalmilitia Member

    Joined:
    Jul 1, 2010
    Messages:
    202
    Likes Received:
    0
    Device:
    iPhone 3GS (Black)
    Sweet. Hopefully this works, will post my results ASAP. Just finished restoring because of iMemory Enhancer Bullsh*t.
    ------------------double post merged------------------
    YES! This works and a huge performance upgrade. Thanks arsenal!

Share This Page