[1771] in athena10
Re: tmp-cleaner for Linerva
daemon@ATHENA.MIT.EDU (Evan Broder)
Wed Mar 18 20:02:11 2009
Message-ID: <49C18AC0.3050309@mit.edu>
Date: Wed, 18 Mar 2009 19:58:56 -0400
From: Evan Broder <broder@MIT.EDU>
MIME-Version: 1.0
To: Quentin Smith <quentin@mit.edu>
CC: Nelson Elhage <nelhage@mit.edu>, Greg Price <price@mit.edu>,
linerva@mit.edu
In-Reply-To: <alpine.DEB.1.10.0903181924490.1549@vinegar-pot.mit.edu>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Looks like they don't get special treatment, certainly - people who show
up in `w -h` get a free pass.
- Evan
Quentin Smith wrote:
> As written now, does it preserve the files of people who have screen
> sessions running?
>
> --Quentin
>
> On Wed, 18 Mar 2009, Nelson Elhage wrote:
>
>> I guess we may want to change the parameters for the tmp cleaner. The
>> default is
>>
>> # The values here are minimum numbers of days. Negative means mtime,
>> # positive means atime.
>> my %dirs = ("/tmp" => 2,
>> "/var/tmp" => 3);
>>
>> My gut reaction is to want something slightly longer, although I'm not
>> sure. Much longer might not with this f2swp business, for instance.
>>
>> (We may want to make that configurable in debathena-tmp-cleaner
>> through a file in /etc, as well, at some point. Doing that as long as
>> we're deploying that might not be a bad plan)
>>
>> - Nelson
>>
>> On Wed, Mar 18, 2009 at 05:54:33PM -0400, Greg Price wrote:
>>> Sounds good to me. We ran all the way out of space just now, so it's
>>> past time we dealt with this.
>>>
>>> Nearly all of the huge files I deleted in today and yesterday's
>>> episodes belonged to users who were not logged in, so this cleaner may
>>> well be sufficiently thorough, anyway.
>>>
>>> Greg
>>>
>>>
>>> On Wed, Mar 18, 2009 at 04:52:43PM -0400, Nelson Elhage wrote:
>>>> Lacking a definite better plan, I say we set up the (Deb)Athena tmp
>>>> cleaner. If we need something more aggressive, we can move to
>>>> tmpreaper or something that doesn't necessarily respect logged-in
>>>> status. But the Athena cleaner is something people are used to and we
>>>> know works reasonably well in comparable environments.
>>>>
>>>> I'll hold off on doing so until I get at least one ack from another
>>>> maintainer.
>>>>
>>>> - Nelson
>>>>
>>>> On Tue, Mar 17, 2009 at 07:26:45PM -0400, Greg Price wrote:
>>>>> We should install a tmp-cleaner on Linerva. Today we nearly hit 50G.
>>>>>
>>>>> linerva / tmp / andersk 17:41 (Anders Kaseorg)
>>>>> Filesystem 1K-blocks Used Available Use%
>>>>> Mounted on
>>>>> /dev/mapper/linerva-tmp
>>>>> 51606140 47324116 1660968 97% /tmp
>>>>> linerva / tmp / price 18:01 (Gregory N. Price)
>>>>> # find /tmp -maxdepth 1 -size +1G -atime 3
>>>>>
>>>>> finds seven files. None of the owners are logged in. I'm
>>>>> going to
>>>>> remove them with /bin/saferm (like debathena-tmp-cleaner
>>>>> uses.)
>>>>> Then we can deal non-urgently.
>>>>> linerva / tmp / price 18:01 (Gregory N. Price)
>>>>> (pausing for objections...)
>>>>> linerva / tmp / price 18:05 (Gregory N. Price)
>>>>> Done.
>>>>>
>>>>> vinegar-pot:~# df /tmp/
>>>>> Filesystem 1K-blocks Used Available Use%
>>>>> Mounted on
>>>>> /dev/mapper/linerva-tmp
>>>>> 51606140 40478324 8506760 83% /tmp
>>>>>
>>>>> We should still set up a real tmp-cleaner.
>>>>>
>>>>> One obvious choice is debathena-tmp-cleaner, which as written removes
>>>>> files in /tmp older than 2 days and in /var/tmp older than 3.
>>>>>
>>>>> But it refuses to remove files owned by users who are logged in, no
>>>>> matter how long ago the file was last touched. Since the history of
>>>>> -tmp-cleaner is that ghudson wrote it in July, I suspect that this
>>>>> was
>>>>> motivated by the cluster situation where a logged-in user "owns" the
>>>>> machine and may as well do as they please in /tmp/. For Linerva we
>>>>> may want to vary this behavior.
>>>>>
>>>>> It might also be nice to use upstream software. Any recommendations?
>>>>>
>>>>> Greg
>>