HardyFullDiskHandling

Differences between revisions 2 and 5 (spanning 3 versions)
Revision 2 as of 2007-11-14 06:32:13
Size: 4210
Editor: p54A679A0
Comment:
Revision 5 as of 2008-08-06 16:31:55
Size: 4140
Editor: localhost
Comment: converted to 1.6 markup
Deletions are marked like this. Additions are marked like this.
Line 10: Line 10:
This spec describes a tool that helps the user to free diskspace by This spec describes a tool that helps the user to free disk space by
Line 20: Line 20:
If a machine runs low on diskspace the user is on his own. There is no If a machine runs low on disk space the user is on his own. There is no
Line 22: Line 22:
adresses this issue. addresses this issue.
Line 26: Line 26:
 1. Alice runs out of diskspace because her apt cache is too big
 2. Bob has a very small /boot parition and with the addition of new kernels it eventually runs out of space.
 1. Alice runs out of disk space because her apt cache is too big
 2. Bob has a very small /boot partition and with the addition of new kernels it eventually runs out of space.
Line 35: Line 35:
When gnome-volume-manager (or kded) detect that the diskspace runs When gnome-volume-manager (or kded) detect that the disk space runs
Line 37: Line 37:
button to launch the system-cleanup helper with the appropriate fs
that runs low on diskspace. The cleanup wizard should also be run when
the dist-quota is full.
button to launch the system-cleanup helper with the appropriate
filesystem
that is low on disk space. The user-cleanup helper should
also be run when the disk quota is full.
Line 47: Line 47:
  * tracker/strigi cache: maybe a problem because it can not be re-generated
(make sure to never remove "metadata")
  * tracker/strigi cache: maybe a problem because it can not be re-generated (make sure to never remove "metadata")
Line 60: Line 59:
  * ~/mail/.imap dovecot mail indexes
Line 66: Line 66:
  * Unused / less used software : is there any way to list them?
(use the popcon heuristics for this?)
  * Unused / less used software : is there any way to list them? (use the popcon heuristics for this?)
Line 76: Line 75:
duplicated files in the users homedir. If the tool runs out of ideas, duplicated files in the users home directory. If the tool runs out of ideas,
Line 86: Line 85:
mount point that runs low on diskspace is passed to the plugin and it mount point that runs low on disk space is passed to the plugin and it
Line 88: Line 87:
considered too). Support for a global plugin dir where applications considered too). Support for a global plugin directory where applications
Line 94: Line 93:
It's important that we are able to test new features, and demonstrate them to users. Use this section to describe a short plan that anybody can follow that demonstrates the feature is working. This can then be used during CD testing, and to show off after release. TBD
Line 98: Line 97:
== Releated Work ==

 * https://wiki.ubuntu.com/FullFilesystemSanityGutsy
 * https://wiki.ubuntu.com/SystemCleanUpTool
Line 100: Line 104:
What to do for kde? they don't have a daemon that checks the disk space.  What to do for kde? they don't have a daemon that checks the disk space.

Please check the status of this specification in Launchpad before editing it. If it is Approved, contact the Assignee or another knowledgeable person before making changes.

Summary

This spec describes a tool that helps the user to free disk space by offering to remove temporary files.

Release Note

A new tool that helps freeing up diskspace is now part of the default install.

Rationale

If a machine runs low on disk space the user is on his own. There is no good GUI tool to help him freeing space. The "system-cleanup" tool addresses this issue.

Use Cases

  1. Alice runs out of disk space because her apt cache is too big
  2. Bob has a very small /boot partition and with the addition of new kernels it eventually runs out of space.

Design

The tools needs to be written in a way that makes it easy to add new GUI frontends (like qt/text) and to make it very easy to add custom free space plugins to make community participation easy.

When gnome-volume-manager (or kded) detect that the disk space runs low, it pops up a notification. This notification should include a button to launch the system-cleanup helper with the appropriate filesystem that is low on disk space. The user-cleanup helper should also be run when the disk quota is full.

Some of the areas where space can be freed require administrative privileges. We will only show them if the user is in the admin group (or the distro specific equivalent).

Possible targets:

  • User:
    • tracker/strigi cache: maybe a problem because it can not be re-generated (make sure to never remove "metadata")
    • thumbnail cache
    • firefox/epiphany/konqueror cache
    • Trash
    • ~/.thunderbird/*/ImapMail (dangerous)

    • ~/.evolution/mail (dangerous)
    • psp font cache from OpenOffice

    • google earth cache
    • xchat/pidin logs may be worth to be compressed (upstream!)
    • ccache
    • button to spawn baobab
    • debclean on all debian branches
    • ~/mail/.imap dovecot mail indexes
  • System:
    • old rotated Logs
    • apt cache
    • apt-get autoremove / deborphan
    • old kernels
    • Unused / less used software : is there any way to list them? (use the popcon heuristics for this?)

Depending on the partition layout the tool needs to make intelligent decisions. E.g.:

  • /var - cleanup apt cache
  • /boot - cleanup old kernels
  • /tmp - old cruft, but we need to be *very* careful (check out temp-reaper/tmp-watch)

Additionally it should offer to run something like "fdupes" to find duplicated files in the users home directory. If the tool runs out of ideas, it should offer to run baobab and let the user continue the cleanup manually.

It is important that we ensure that it is possible to login into gnome even if $HOME is full. We should add a automatic test for this.

Implementation

Each cleanup target is implemented as a plugin. The directory with the mount point that runs low on disk space is passed to the plugin and it then declares how much space it can free where (symlinks needs to be considered too). Support for a global plugin directory where applications can store plugins (e.g. opera to delete its own cache) as well as user plugins should be added.

Test/Demo Plan

TBD

This need not be added or completed until the specification is nearing beta.

Releated Work

Outstanding Issues

  • What to do for kde? they don't have a daemon that checks the disk space.

BoF agenda and discussion

gnome-volume-manager has some heuristics to take the velocity of disk-fill up into account (do some learning here to try to figure out the users disk-usage pattern?)

Random:

  • Like the out of memory killer of the kernel, the tool could stop/kill application that will conduct to disk full


CategorySpec

HardyFullDiskHandling (last edited 2008-08-06 16:31:55 by localhost)