Active Topics

 


Reply
Thread Tools
mece's Avatar
Posts: 1,111 | Thanked: 1,985 times | Joined on Aug 2009 @ Åbo, Finland
#1
Here's a simple howto for those suffering from lack of space in rootfs:

The first one is more of a temporary matter, for example to get enough space to install an update, but it's also the fastest and easiest.

1. Disable extras-testing and extras-devel and third party repositories

Simply check the disabled box and save in the Application Manager's catalogues menu. wait for app manger to update the lists.
Of course this only helps if you actually had these repositories enabled.

Disabling extras-testing and extras-devel will (currently) give you an extra 11.5Mb in rootfs

2. Reinstall python

This one is a bit more work, but gives you around 20Mb.
If you installed a python application (for example FM Radio, Quicknote, Witter) before python was optified, you need to reinstall python. This will uninstall your python applications, so you will need to reinstall them after you're done. For this you need rootsh which is in extras.

check that app manger is not running
open xterm
type the following commands:

sudo gainroot
apt-get remove python

This will prompt if you really want to do it and give a list of things that will be removed. It's good to check the list so you know which applications are going to be uninstalled.

then these commands:
apt-get remove python2.5
apt-get remove python-osso
apt-get autoremove
apt-get clean

I think I manually installed python-osso on my device, so that one might just say that it's not installed.

After that is done open application manager and reinstall the python applications. The new optified version of python will be automatically installed with them. Try with FM Radio for example.


Do this instead (Thanks @rewt):
Code:
sudo gainroot
apt-get install pymaemo-optify
apt-get clean
When the program is installed, type df -h in the xterm to see if it worked.
The output should now contain these lines at the end:
Code:
/opt/pymaemo/usr/lib/python2.5
                       2064208    471712   1487640  24% /usr/lib/python2.5
/opt/pymaemo/usr/share/pyshared
                       2064208    471712   1487640  24% /usr/share/pyshared
/opt/pymaemo/usr/lib/pyshared
                       2064208    471712   1487640  24% /usr/lib/pyshared
/opt/pymaemo/usr/share/python-support
                       2064208    471712   1487640  24% /usr/share/python-support
/opt/pymaemo/usr/lib/python-support
                       2064208    471712   1487640  24% /usr/lib/python-support
Scroll up to see rootfs status. It should hopefully have more space now.

3. Moving apt cache to home.

This is a more risky fix that could lead to some problems. However it works for me.

This fix is required to be able to install large programs with apt.

in xterm type these commands:
Code:
sudo gainroot
mv /var/cache/apt /home/user/.apt-cache
ln -s /home/user/.apt-cache /var/cache/apt
This should free up a couple of Mb. It depends on what repositories you have and if you have been using apt.

There's a wiki page with this information too:
http://wiki.maemo.org/Free_up_rootfs_space
__________________
Class .. : Meddler, Thread watcher, Developer, Helper
Humor .. : [********--] Alignment: Pacifist
Patience : [*****-----] Weapon(s): N900, N950, Metal music
Agro ... : [----------] Relic(s) : N95, NGage, Tamyia Wild One

Try Tweed Suit for your hardcore twittering needs
http://twitter.com/mece66
I like my coffee black, like my metal.

Last edited by mece; 2010-01-14 at 12:52.
 

The Following 74 Users Say Thank You to mece For This Useful Post:
mece's Avatar
Posts: 1,111 | Thanked: 1,985 times | Joined on Aug 2009 @ Åbo, Finland
#2
I've been hacking pretty vigorously at the roofs problem and have a couple of other things that can be done too. Should I post the more risky stuff here or would it be wiser to stick to the safe stuff?

My own goal was to get more than 50Mb with all my repositories enabled, and I got to 49Mb with the above fix. (I have a few third party repositories too)
__________________
Class .. : Meddler, Thread watcher, Developer, Helper
Humor .. : [********--] Alignment: Pacifist
Patience : [*****-----] Weapon(s): N900, N950, Metal music
Agro ... : [----------] Relic(s) : N95, NGage, Tamyia Wild One

Try Tweed Suit for your hardcore twittering needs
http://twitter.com/mece66
I like my coffee black, like my metal.
 
qwerty12's Avatar
Posts: 4,274 | Thanked: 5,358 times | Joined on Sep 2007 @ Looking at y'all and sighing
#3
I'd love to see a proper port of localepurge... I'm currently using the version hacked to use pcregrep, instead. Localepurge frees up a nice 15 MBs' worth of locales that I will never use. (And it continues to free up space by purging locales after a program is installed.)

But the problem with the currently available, it assumes the user is using en_GB and, by default, only chooses to keep: en, en_GB and en_US locales.
 
ossipena's Avatar
Posts: 3,159 | Thanked: 2,023 times | Joined on Feb 2008 @ Finland
#4
http://wiki.maemo.org/Free_up_rootfs_space

"a bit" rough but there it is
__________________
Want to know something?
K.I.S.S. approach:
wiki category:beginners. Browse it through and you'll be much wiser!
If the link doesn't help, just use
Google Custom Search
 

The Following 8 Users Say Thank You to ossipena For This Useful Post:
mece's Avatar
Posts: 1,111 | Thanked: 1,985 times | Joined on Aug 2009 @ Åbo, Finland
#5
Originally Posted by qwerty12 View Post
I'd love to see a proper port of localepurge... I'm currently using the version hacked to use pcregrep, instead. Localepurge frees up a nice 15 MBs' worth of locales that I will never use. (And it continues to free up space by purging locales after a program is installed.)

But the problem with the currently available, it assumes the user is using en_GB and, by default, only chooses to keep: en, en_GB and en_US locales.
I haven't bothered with that one yet, but yeah, it would be nice.

One thing that worries me a little is the icon-cache. I mean that effectively limits the amount of apps you can have in the repository afaict.
__________________
Class .. : Meddler, Thread watcher, Developer, Helper
Humor .. : [********--] Alignment: Pacifist
Patience : [*****-----] Weapon(s): N900, N950, Metal music
Agro ... : [----------] Relic(s) : N95, NGage, Tamyia Wild One

Try Tweed Suit for your hardcore twittering needs
http://twitter.com/mece66
I like my coffee black, like my metal.
 
mece's Avatar
Posts: 1,111 | Thanked: 1,985 times | Joined on Aug 2009 @ Åbo, Finland
#6
Originally Posted by ossipena View Post
http://wiki.maemo.org/Free_up_rootfs_space

"a bit" rough but there it is
@Flandry, Perhaps a link to that wiki page could be added to the Sticky FAQ?
__________________
Class .. : Meddler, Thread watcher, Developer, Helper
Humor .. : [********--] Alignment: Pacifist
Patience : [*****-----] Weapon(s): N900, N950, Metal music
Agro ... : [----------] Relic(s) : N95, NGage, Tamyia Wild One

Try Tweed Suit for your hardcore twittering needs
http://twitter.com/mece66
I like my coffee black, like my metal.
 
Flandry's Avatar
Posts: 1,559 | Thanked: 1,786 times | Joined on Oct 2009 @ Boston
#7
Thanks guys. I've been looking for a safe place to direct people in the sticky. A description of how to cut and paste a shell script to optify their entire root just didn't make the cut.

If anyone is going to add to the wiki, please make sure to divide it into basic and advanced sections and clearly post a suitably specific and dire warning at the transition.

Edit: ha, you beat me by 10 s.
__________________

Unofficial PR1.3/Meego 1.1 FAQ

***
Classic example of arbitrary Nokia decision making. Couldn't just fallback to the no brainer of tagging with lat/lon if network isn't accessible, could you Nokia?
MAME: an arcade in your pocket
Accelemymote: make your accelerometer more joy-ful
 
Posts: 287 | Thanked: 165 times | Joined on Oct 2009 @ The Netherlands
#8
Is it possible to create a script that lists 'odd' things in rootfs? Maybe compare the current rootfs to a reference list? Is that doable? Or isn't the rootfs filelist (mostly) the same for each device?
 
hopbeat's Avatar
Posts: 516 | Thanked: 643 times | Joined on Oct 2009 @ Denmark/Poland
#9
@qwerty12, is that the version you are using on n900?http://talk.maemo.org/showthread.php?t=24564
__________________
Hi! I'm a Maemo Greeter!
Witaj na talk.maemo.org!

Useful links for newcomers:
Użyteczne linki:
Nowi użyktownicy mówią cześć | New members say hello , Tu zaczynają nowi użytkownicy | New users start here, Podforum społeczności | Community subforum, Wiki dla początkujących | Beginners' wiki page, Maemo5 101, Często zadawane pytania | Frequently Asked Questions (FAQ), Google

Jeżeli mogę w czymś pomóc, pytaj!
If I can help with anything else, just ask!

Bored? Follow me
 
Posts: 150 | Thanked: 93 times | Joined on Oct 2009 @ Pennsylvania, US
#10
I put together a quick script last night... It'll check any packages that aren't dependencies of mp-fremantle-*-pr (which should exclude most of the pre-installed packages) to see if they place any files in /opt - if they don't it'll let you know that [package_name] isn't optified.

Just copy this code into a file on your device and in x-term type ". ./filename" in the directory the file is in, and you'll get a list of packages that may be a problem. If you see something you don't remember installing, it's probably best to ignore it (as it may be a system package, see below for the reason why).

Code:
getpkg () { dpkg -l $1 | grep -E "^i" | sed -r "s/^.. *//g;s/ +.*$//g"; }
getdepends () { apt-cache depends $1 | grep "Depends:" | sed -r "s/(.*: |<|>)//g"; }
fremantlepkg=$(getpkg mp-fremantle-\*-pr | head -1)
if [ "$fremantlepkg" == "" ]; then echo Missing mp-fremantle-\*-pr package, aborting
else sysdeps="x $fremantlepkg $(getdepends $fremantlepkg) x"; pypaths="";
if [ -e /opt/pymaemo ]; then pypaths="|/usr/lib/python2.5/|/usr/share/pyshared/|/usr/lib/pyshared/|/usr/share/python-support/|/usr/lib/python-support/"; fi
for x in $(getpkg); do
 dpkg -L $x | grep -E "^(/opt/$pypaths)" > /dev/null || echo $sysdeps | grep " $x " > /dev/null || echo $x not optified
done; fi
In another version, I made an attempt at enumerating the entire dependency tree for mp-fremantle-*-pr, but it was too time consuming (after 20 minutes, it was still tracing dependencies). Because the script above doesn't know about every system package, there may be a few packages reported that are system packages and not user installed - most of the noise should be filtered, however.

If you find this useful, feel free to thank me by using this "Thanks!" link

Last edited by rewt; 2010-01-13 at 21:35. Reason: updated to detect mp-fremantle-*-pr package name and recognize python optification
 

The Following 12 Users Say Thank You to rewt For This Useful Post:
Reply


 
Forum Jump


All times are GMT. The time now is 08:10.