Editing Free up rootfs space
Warning: You are not logged in.
Your IP address will be recorded in this page's edit history.
The edit can be undone.
Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 3: | Line 3: | ||
Here's a simple howto for those suffering from lack of space in rootfs. The first suggestion is more of a temporary matter, for example to get enough space to install an update, but it's also the fastest and easiest. The suggestions are in order of potential threat to operating system. Least dangerous first and the most dangerous last. The rest are more permanent (and thus more useful), but they require [[root access]]. | Here's a simple howto for those suffering from lack of space in rootfs. The first suggestion is more of a temporary matter, for example to get enough space to install an update, but it's also the fastest and easiest. The suggestions are in order of potential threat to operating system. Least dangerous first and the most dangerous last. The rest are more permanent (and thus more useful), but they require [[root access]]. | ||
- | ==Listing rootfs space on your device == | + | |
+ | ===Listing rootfs space on your device === | ||
Use this command to determine how much rootfs space is allocated, used, and available on your device. | Use this command to determine how much rootfs space is allocated, used, and available on your device. | ||
Line 10: | Line 11: | ||
If you want to see all filesystems, use only "df -h". | If you want to see all filesystems, use only "df -h". | ||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
===Disable Extras-testing, Extras-devel, and/or any other third party repositories=== | ===Disable Extras-testing, Extras-devel, and/or any other third party repositories=== | ||
Line 24: | Line 17: | ||
Disabling [[extras-testing]] and [[extras-devel]] will (currently) give you an extra 5 MB in rootfs | Disabling [[extras-testing]] and [[extras-devel]] will (currently) give you an extra 5 MB in rootfs | ||
+ | |||
===Clear apt cache=== | ===Clear apt cache=== | ||
Line 31: | Line 25: | ||
apt-get clean | apt-get clean | ||
- | will release probably near | + | will release probably near 10Mo. |
- | + | ||
===Remove unused dependencies=== | ===Remove unused dependencies=== | ||
Line 40: | Line 33: | ||
apt-get autoremove | apt-get autoremove | ||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
===List of big and rarely used files=== | ===List of big and rarely used files=== | ||
Line 58: | Line 38: | ||
You can't just delete these files, this is just a list with ideas! You have to know what you are going to do with them (optify, backup+remove, etc.). | You can't just delete these files, this is just a list with ideas! You have to know what you are going to do with them (optify, backup+remove, etc.). | ||
- | * | + | * /usr/lib/locale/locale-archive (28 MB) : stupid idea : if you do such a thing, you will loose all the constant texts as the names of days ("Monday","Tuesday",...). Who has written a such advice ? |
- | * | + | * /usr/share/locale (10 MB, but you have to keep at least the languages you use) |
- | * | + | * /usr/share/themes/alpha and /beta (they use 5-6 MB each, keep the one you use - REMOVING THESE WILL GENERALLY MESS UP YOUR UI - do not simply remove them with "rm -f $dir" - use "apt-get remove [hildon-theme-alpha|hildon-theme-beta]" Similarly you can reinstall them the same way. Dependency apps: "bluezwitch cherry feedingit google-search-widget hildon-desktop hildon-desktop-python-loader hildon-theme-alpha") |
hildon-theme-beta mp-fremantle-002-pr osso-startup-wizard ovi-promotion-widget) | hildon-theme-beta mp-fremantle-002-pr osso-startup-wizard ovi-promotion-widget) | ||
- | * | + | * /usr/share/fonts/arabic and /chinese (2,5 MB less for people who don't speak those two languages) |
===Move apt cache outside of rootfs=== | ===Move apt cache outside of rootfs=== | ||
Line 96: | Line 76: | ||
/opt/pymaemo/usr/lib/python2.5 | /opt/pymaemo/usr/lib/python2.5 | ||
2064208 471712 1487640 24% /usr/lib/python2.5 | 2064208 471712 1487640 24% /usr/lib/python2.5 | ||
+ | |||
===Remove non-optified packages=== | ===Remove non-optified packages=== | ||
Line 109: | Line 90: | ||
You get a listing of all running processes, including the application you just started. To find out what package an application belongs to, enter | You get a listing of all running processes, including the application you just started. To find out what package an application belongs to, enter | ||
dpkg --search $(which ''processname'') | dpkg --search $(which ''processname'') | ||
+ | |||
Source: http://talk.maemo.org/showpost.php?p=468063&postcount=1 | Source: http://talk.maemo.org/showpost.php?p=468063&postcount=1 | ||
+ | |||
===Custom scripts=== | ===Custom scripts=== | ||
Line 122: | Line 105: | ||
First, create a file, move-to-opt.sh for example, containing this script: | First, create a file, move-to-opt.sh for example, containing this script: | ||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | # Moving video on start-up to /home/opt | + | #!/bin/sh |
- | mkdir -p /home/opt/usr/share/hildon-welcome 2> /dev/null | + | # Nokia N900 Maemo 5 Script to free up space on rootfs |
- | cp -r /usr/share/hildon-welcome/* /home/opt/usr/share/hildon-welcome | + | # ignoring errors when creating dirs that may already exist |
- | rm -r /usr/share/hildon-welcome | + | |
- | ln -s /home/opt/usr/share/hildon-welcome /usr/share/hildon-welcome | + | # Moving ?? icons to /home/opt |
- | + | mkdir -p /home/opt/usr/share/icons 2> /dev/null | |
- | # ?? | + | cp -r /usr/share/icons/* /home/opt/usr/share/icons |
- | mkdir -p /home/opt/usr/share/pixmaps 2> /dev/null | + | rm -r /usr/share/icons |
- | cp -r /usr/share/pixmaps/* /home/opt/usr/share/pixmaps | + | ln -s /home/opt/usr/share/icons /usr/share/icons |
- | rm -r /usr/share/pixmaps | + | |
- | ln -s /home/opt/usr/share/pixmaps /usr/share/pixmaps | + | # Moving video on start-up to /home/opt |
- | + | mkdir -p /home/opt/usr/share/hildon-welcome 2> /dev/null | |
- | # Moving 'apt cache' to /home/opt - Valid until [https://bugs.maemo.org/show_bug.cgi?id=5746 Bug 5746] is fixed. | + | cp -r /usr/share/hildon-welcome/* /home/opt/usr/share/hildon-welcome |
- | mkdir -p /home/opt/var/cache/apt 2> /dev/null | + | rm -r /usr/share/hildon-welcome |
- | cp -r /var/cache/apt/* /home/opt/var/cache/apt | + | ln -s /home/opt/usr/share/hildon-welcome /usr/share/hildon-welcome |
- | rm -r /var/cache/apt | + | |
- | ln -s /home/opt/var/cache/apt /var/cache/apt | + | # ?? |
+ | mkdir -p /home/opt/usr/share/pixmaps 2> /dev/null | ||
+ | cp -r /usr/share/pixmaps/* /home/opt/usr/share/pixmaps | ||
+ | rm -r /usr/share/pixmaps | ||
+ | ln -s /home/opt/usr/share/pixmaps /usr/share/pixmaps | ||
+ | |||
+ | # Moving 'apt cache' to /home/opt - Valid until [https://bugs.maemo.org/show_bug.cgi?id=5746 Bug 5746] is fixed. | ||
+ | mkdir -p /home/opt/var/cache/apt 2> /dev/null | ||
+ | cp -r /var/cache/apt/* /home/opt/var/cache/apt | ||
+ | rm -r /var/cache/apt | ||
+ | ln -s /home/opt/var/cache/apt /var/cache/apt | ||
+ | |||
+ | # Moving locales [http://talk.maemo.org/showpost.php?p=568370&postcount=11 Source] | ||
+ | mv /usr/share/locale /opt | ||
+ | ln -s /opt/locale /usr/share/locale | ||
- | |||
- | |||
- | |||
- | |||
Set the script's permission for executable: | Set the script's permission for executable: | ||
chmod +x move-to-opt.sh | chmod +x move-to-opt.sh | ||
- | (note that this step will - without warning you in any way - not work on partitions which are only | + | (note that this step will - without warning you in any way - not work on partitions which are only fat formatted, as maybe your micro sd card will initially be; in such a case, move the script somewhere else) |
Run the script as root: | Run the script as root: | ||
Line 171: | Line 154: | ||
====Move some of the pre-installed applications into /opt==== | ====Move some of the pre-installed applications into /opt==== | ||
- | Some applications like Nokia Maps and the microb-engine are placed in /usr/share taking up valuable root space, moving these files will not affect the apps. | + | Some applications like Nokia Maps and the microb-engine are placed in /usr/share taking up valuable root space, moving these files will not affect the apps. Moving Nokia Maps (has to be done as root) will save 8.7 Mb: |
- | + | ||
- | Moving Nokia Maps (has to be done as root) will save 8.7 Mb: | + | |
mv /usr/share/nokia-maps /home/opt/ | mv /usr/share/nokia-maps /home/opt/ | ||
Line 180: | Line 161: | ||
mv /usr/share/microb-engine /home/opt | mv /usr/share/microb-engine /home/opt | ||
ln -s /home/opt/microb-engine /usr/share/microb-engine | ln -s /home/opt/microb-engine /usr/share/microb-engine | ||
- | Moving the "Getting started" app/tutorial (has to be done as root) | + | Moving the "Getting started" app/tutorial (has to be done as root): |
mv /usr/share/tutorial-applet /home/opt | mv /usr/share/tutorial-applet /home/opt | ||
ln -s /home/opt/tutorial-applet /usr/share/tutorial-applet | ln -s /home/opt/tutorial-applet /usr/share/tutorial-applet | ||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
====Move themes==== | ====Move themes==== | ||
Line 195: | Line 169: | ||
{{ambox | {{ambox | ||
| type = notice | | type = notice | ||
+ | | image= | ||
| text = '''This may cause problems when changing themes, and reversing it is NOT possible unless the device is [[Updating the firmware|reflashed]] | | text = '''This may cause problems when changing themes, and reversing it is NOT possible unless the device is [[Updating the firmware|reflashed]] | ||
}} | }} | ||
Line 205: | Line 180: | ||
rm -r /usr/share/themes | rm -r /usr/share/themes | ||
ln -s /home/opt/usr/share/themes /usr/share/themes | ln -s /home/opt/usr/share/themes /usr/share/themes | ||
+ | |||
+ | [[Category:Power users]] | ||
+ | [[Category:N900]] | ||
+ | [[Category:Firmware update]] | ||
====See rootfs usage per package==== | ====See rootfs usage per package==== | ||
Line 212: | Line 191: | ||
from [http://www.robinhill.me.uk/maemo/package_sizes.html] | from [http://www.robinhill.me.uk/maemo/package_sizes.html] | ||
- | |||
- | |||
- | |||
- | |||
- | |||
- |
Learn more about Contributing to the wiki.