Filed under: iPod Family, Hacks, How-tos, iPhone
iPhone Hacks: Running out of Application space on your iPhone or touch?
Both the iPhone and the iPod touch include relatively limited space on the OS partition (the part of your iPhone's memory that stores the operating system and associated files). It's where Apple, by default, adds its factory-installed Applications but you can save space by installing your Apps on the Media partition instead (that's the part of your your touch or phone that contains your iTunes musics and videos). Here's how: Your iPhone or iPod touch knows about a folder called "/Widgets". Any Application installed into /Widgets gets recognized and loaded into SpringBoard, just like any app in /Applications. You can fool your iPod or iPhone into thinking you've added a Widgets folder by creating a symbolic link between your media partition and /Widgets.
To do this, you create a folder in your root directory called Applications, or more specifically, /var/root/Applications. You can then add a "symbolic link", a kind of alias, that connects /Widgets with /var/root/Applications. If you install my Erica Utilities and the BSD subsystem, you can create and remove this link by running my xwidg utility.
At this time this is a command-line only operation, however, if you have ssh installed on your system and connect from your computer, just issue the following command: ~/bin/xwidg. The utility looks for an existing symbolic link. If it finds one it removes it, if it does not it creates it. So running xwidg repeatedly just toggles the connection on and off. After each update, it restarts SpringBoard so it reflects the updated link.
The downside is some Applications use absolute paths in their code: Labyrinth and Crossy are two prime examples (They should be using NSBundle calls but that's a completely different matter). Most Applications will run as happily in /Widgets via /var/root/Applications as they will in /Applications and you will save yourself a lot of OS partition space.


Reader Comments (Page 1 of 3)
bshell said 6:09PM on 10-29-2007
Love your posts Erica. Thanks. Please: how we tell if we are running out of OS partition space? Is there a command, or a utility that tells us?
Reply
Sam Weiss said 6:17PM on 10-29-2007
W00t! Thanks Erica!
Now what would be spiff is if you could tell the installer where to install!
And some things of course need to live in certain places. I'm certain most of the unix utils need to live where they are put, unless of course symlinks were created for those directories as well. Would there be any drawback to this? Like... I'd love to put in the python script engine back on my phone (though I haven't used it yet).
I'm not sure what directories python installs into, but I know it takes about 10+ megs!
(oh... what spiffy unix commands can I used to get free space info? I know some unix, but not sure about that one)
Thanks!
Sam
Reply
Hussain said 6:18PM on 10-29-2007
yeah ... also i think you need to remove the noexec option on the media partion in fstab.
also where does the installer put its apps ... cause i wasn't sure so i copied /Application over to /var/root/Application and made /Application a symlink to it... although maybe not as safe ... it does avoid possible problems you mentioned
also I would like to thank you for all your work on the iphone ... and tell you that I really appreciate it.
thanks
Reply
Michaels POINT said 7:27PM on 10-29-2007
Here me out first !
Allot of GOOD HEARTED people put allot of time in the newest release of the APPSNAP, so whoever or whomever comes up with a fix for the space limitation needs to make it simple and easy.
Read the posts people allot of people, users or however you want to label them did NOT do the previous hacks and such do to "POINT BLANK" they either did NOT understand fully what needed to be done or plain and simple it was NOT a simple GUI.
NOT everyone understands Command line theory, or instruction and how it all comes together.
I ask the developer / hacker / cracker community to make something that is USER friendly and it will get more response, usage, and I think you get my point.
Just trying to HELP nothing else.
Reply
Chris said 7:53PM on 10-29-2007
What about the iPhone (Only!) part in the Description for Erica's Utilities?
Reply
Phreak said 8:43PM on 10-29-2007
o.k. i can`t get this to work. i created /var/root/Applications and ran xwidg and it created the link. there is a widgets folder in /root now. i tried putting sendsong and iblackjack in /var/root/Applications and they show up but when i try to launch them with xlaunch it just hangs at a blank scrren. can some1 explain what i am doing wrong or what the problem is. thanx
Reply
Erica Sadun said 8:44PM on 10-29-2007
Make sure you have removed noexec from /etc/fstab (if it is there) and have installed the BSD subsystem and all your executables are +x
Reply
Phreak said 8:52PM on 10-29-2007
fstab is 0644, and i have bsd installed. i`m on 1.0.2 if it matters.and i only installed xwidg. do i need to install everything in your utils folder? thanx again
Reply
iSkysoft Studio said 8:58PM on 10-29-2007
Good.
I have a lots of DVD and want to convert them to my iphone.
http://www.iskysoft.com
Reply
Phreak said 9:32PM on 10-29-2007
i think i figured out the problem. xlaunch 10 doesn`t read /var/root/Applications. i have xlaunch 15 on my 1.0.2 firmware phone and it launches /root/Applications fine and it will show /var/root/Applications but when i try to launch the one`s symlinked they just freeze. is there anyway you could fix this for 1.0.2 user`s? thanx Erica
Reply
Hussain said 10:31PM on 10-29-2007
Phreak,
open fstab and get rid of the noexec option on the second line (i think)
just delete noexec also if i remember correctly you will need to get rid of a comma as well
Hussain
Reply
Anthony said 11:32PM on 10-29-2007
I wonder if one could take the 16GB drive out of a touch and install it in an iPhone.
Reply
TjL said 2:21AM on 10-30-2007
I heard that the noexec part in fstab is apparently handed automatically.
An easier solution to this that someone told me works:
READ THIS ALL BEFORE YOU DO ANYTHING!
mkdir ~/Applications
mv -iv /Applications/AppNameZHere.app ~/Applications/
WHERE "AppNameZHere" DOES NOT INCLUDE ANY OF THE DEFAULT APPS.
ln -s ~/Applications/* /Applications/
This makes a link between the files in ~/Applications/ (which has a lot of space) and /Applications (which does not).
Your iPhone will tell you when you are running low of space. I think I heard it is only about 300mb.
If you can get to the commandline on your phone, use
du -sh
to check disk usage ("du") using the "summary" (-s) and "human readable" (-h) flags, so you don't have convert bytes to megabytes/gigabytes.
YMMV, Use at your Own Risk, I have not tried this. Since Apple started telling people that doing any of this voids your warranty, I suggest doing what I am doing which is waiting until February. You never know when it's going to break again.
Reply
Antonio said 7:26AM on 10-30-2007
Excelent post Erica, worked like a charm!
Reply
Kura said 8:03AM on 10-30-2007
@ Michaels POINT
People like you make me sad. Developers are putting a lot of work in these applications that you get for free. Before you can get a gui you need to find a solution first but you start begin shouting requesting for a gui because you're not able to handle a few command lines. Oh and stop using caps, it makes you look stupid.
@Erica: Great work!
-Kura
Reply
Phreak said 1:09PM on 10-30-2007
thanx Hussain, that worked
Reply
Flib said 7:45PM on 10-31-2007
I actually ran out of partition ("disk") space, which I suspected was at the root of a You Tube error "Not able to play this video" (and yes, I wasn't able to play anything from You Tube).
I manually did the symbolic link trick for /Widgets, moved most of the applications around (excluding the legacy ones and Labyrinth as mentionned in the post) and it works beautifully.
In case this helps, another thing I did was deleting /var/root/Library/You Tube/VideoCache, which solved the You Tube problem without apparent side effects.
Reply
hxx said 2:50AM on 11-01-2007
I'm not used to command lines but figured it out. The Customize app and Launcher app seems not working once moved to /var/rooot/Applications though. So now, is there way to manage show/hide icons?
Reply
Jail Break iPhone said 4:31AM on 11-01-2007
Jail Break Your iPhone/iPod
http://mgopinath.blogspot.com/2007/10/freedom-to-your-iphoneipod-with-single.html
Reply
Will Boyce said 8:46AM on 11-01-2007
Could you not just move /Applications to the media partition and symlink that? Then Installer.App etc should go straight onto the media partition...
Reply