This is a simple little hack that can help fix any lagging problems you may be experiencing by increasing the amount of memory available to the operating system by creating a virtual memory via swap files in the flash memory used by the iPhone as its primary storage (this is separate from the RAM that’s a major factor in how fast the OS can run things).
There are currently two different versions available, the .plist version and the Chinese version:
- The chinese version creates one large swap file of 256MB and uses that space as needed.
- The .plist version creates a smaller swap file of 64MB and creates/deletes the swap files as needed.
Most people that have tried both are going with the .plist version–it uses less space yet manages to actually be a little bit faster. Here’s how to get and install each one:
Chinese Version
- Download the .deb file here: http://www.sendspace.com/file/hatvmw
- SSH and place the .deb file into whatever directory you want (/tmp is always a good choice).
- Open a terminal and navigate to where the .deb file is stored (i.e. “cd /tmp”)
- Install using the command dpkg -i iPhoneVM.deb
- Reboot your iPhone, you’re done
.plist Version
- Download the .plist here: http://www.mediafire.com/?zdezacmq0wm
- SSH into your iPhone and place the .plist in /System/Library/LaunchDaemons/
- Reboot, and that’s it, you’re done.

I tried the Chinese first………..wanna try thr plist method now?
Do I have to uninstall the Chinese one before doing the plist?
If Yes, how do I uninstall the Chinese?
Thx
I originally had 256 MB DDR and I upgraded the ram to 512 MB (256 MB + 512 MB =768 MB). When I installed window XP sp2 after installation XP system reboot automatically and showing a virtual memory error message & also when i tried to send emails from my website http://www.moneyinhands.com with using bulk email marketing software then i faced trouble about low virtual memory. One more thing is when i open too many website on my computer using firefox & google chrome i faced same problems. Please suggest me that about how i increase my system virtual memory to i work easily without any difficulty. Please resolve my problems.
This (.plist) works great! Thanks.
what the hell is sanjay talking about? makes no sense at all.
i think sanjay its on the wrong place =], cant believe he did that to Wxp “?” i hope he knows how to read cus its completely clear that this IS NOT FOR COMPUTERS =]. IT CLEARLY SAYS THAT ITS FOR “IPHONE” NOT A PC LOL
Sanjay admits to being a spammer, so I hope he really did try to install this on his xp box, and that it blows up and/or electrocutes him.
The .plist worked great, just google SSH and Mobileportal before doing this.
woa thanks for the info, i’m using iPhone 2G with 3.1.2 OS to play WeRule and it works fine now… thanks alot ^^
I assume that ssh is just to access the file system and this can be done with something like ifunbox or iphoneexplorer?
How do I confirm the application successfully applied?
Jailbroken 3G 8GB
I’m wondering if the iPhone accessing these swapfiles puts an additional drain on the battery…
These VM mods will ruin your flash memory. Highly Unrecommended.
Did this to my wife’s 3G due to her having really poor “We Rule” performance and while it doesn’t show a big free resource change in SB Settings (53mb free ram), the performance is a huge improvement and smoothed the lag in WE RULE to a minimum. Wondering if I should try it on my 3GS for the heck of it. Anyway….Highly recommended tweak for 2G and 3G users. Make sure you use the .plist version.
Andrew
Mate, “some” people also say what you say.
When Magellan went sailing, “some” still said the world was flat …
Please, when stating such info as you have, kindly refer the reader to a referenced technical discussion in support of your words.
Big Thanks
Yes theoriticaly it MAY reduce the life of your flash memory to 5 years from original 10 years, but do you really care ? atleast I dont, I have no intentions of holding on to this old mobile for another 5 years am pretty sure of that.
[...] Via VM memory kun je het teugen van je iPhone uitbreiden door een swap partitie aan te maken. Hierdoor krijgt je iPhone meer geheugen, daar ios4 niet echt soepel draait lijkt me dit een goei oplossing. Ik heb dit op 3.1.2 altijd gebruikt en je merkte het verschil zeker, echter ik kan geen ervaringen vinden van andere dat dit ook werkt op ios4 Iemand ervaring hiermee? Info: How to Increase iPhone Memory via Virtual Memory Swap Files [...]