HardyFullDiskHandling

Differences between revisions 1 and 2
Revision 1 as of 2007-11-14 06:07:54
Size: 2568
Editor: p54A679A0
Comment:
Revision 2 as of 2007-11-14 06:32:13
Size: 4210
Editor: p54A679A0
Comment:
Deletions are marked like this. Additions are marked like this.
Line 5: Line 5:
 * '''Launchpad Entry''': UbuntuSpec:foo
 * '''Packages affected''':
 * '''Launchpad Entry''': UbuntuSpec:handling-full-disks
 * '''Packages affected''': system-cleanup
Line 10: Line 10:
This should provide an overview of the issue/functionality/change proposed here. Focus here on what will actually be DONE, summarising that so that other people don't have to read the whole spec. This spec describes a tool that helps the user to free diskspace by
offering to remove temporary files.
Line 14: Line 15:
This section should include a paragraph describing the end-user impact of this change. It is meant to be included in the release notes of the first release in which it is implemented. (Not all of these will actually be included in the release notes, at the release manager's discretion; but writing them is a useful exercise.)

It is mandatory.
A new tool that helps freeing up diskspace is now part of the default
install.
Line 20: Line 20:
This should cover the _why_: why is this change being proposed, what justifies it, where we see this justified. If a machine runs low on diskspace the user is on his own. There is no
good GUI tool to help him freeing space. The "system-cleanup" tool
adresses this issue.
Line 24: Line 26:
== Assumptions ==  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.
Line 28: Line 31:
You can have subsections that better describe specific parts of the issue. 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 diskspace runs
low, it pops up a notification. This notification should include a
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.

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

 * 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 homedir. 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.
Line 32: Line 85:
This section should describe a plan of action (the "how") to implement the changes discussed. Could include subsections like:

=== UI Changes ===

Should cover changes required to the UI, or specific UI that is required to implement this

=== Code Changes ===

Code changes should include an overview of what needs to change, and in some cases even the specific details.

=== Migration ===

Include:
 * data migration, if any
 * redirects from old URLs to new ones, if any
 * how users will be pointed to the new way of doing things, if necessary.
Each cleanup target is implemented as a plugin. The directory with the
mount point that runs low on diskspace 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 dir where applications
can store plugins (e.g. opera to delete its own cache) as well as user
plugins should be added.
Line 57: Line 100:
This should highlight any issues that should be addressed in further specifications, and not problems with the specification itself; since any specification with problems cannot be approved. What to do for kde? they don't have a daemon that checks the disk space.
Line 61: Line 104:
Use this section to take notes during the BoF; if you keep it in the approved spec, use it for summarising what was discussed and note any options that were rejected. 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

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 diskspace 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 diskspace the user is on his own. There is no good GUI tool to help him freeing space. The "system-cleanup" tool adresses this issue.

Use Cases

  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.

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 diskspace runs low, it pops up a notification. This notification should include a 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.

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
  • 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 homedir. 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 diskspace 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 dir where applications can store plugins (e.g. opera to delete its own cache) as well as user plugins should be added.

Test/Demo Plan

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.

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

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)