Re: /tmp ikke stor nok

From: Phil Regnauld (none@regnauld--starBSD.org.lh.bsd-dk.dk)
Date: Sun 07 Dec 2003 - 01:51:04 CET


Date: Sun, 7 Dec 2003 01:51:04 +0100
From: Phil Regnauld <none@regnauld--starBSD.org.lh.bsd-dk.dk>
To: bsd-dk@bsd-dk.dk
Subject: Re: /tmp ikke stor nok

Michael Knudsen
>
> Er det ikke konvention, at indhold i /var/tmp bestaar mellem boots af
> maskinen? I saa fald er dette en daarlig idé. På OpenBSD ryddes /tmp
> under boot.

        Det gøres ikke pr. default på FreeBSD længere, og styres af en
        rc.conf variabel:

(fra /etc/rc):

# Clearing /tmp at boot-time seems to have a long tradition. It doesn't
# help in any way for long-living systems, and it might accidentally
# clobber files you would rather like to have preserved after a crash
# (if not using mfs /tmp anyway).
#
# See also the example of another cleanup policy in /etc/periodic/daily.
#
case ${clear_tmp_enable} in
[Yy][Ee][Ss])
        echo -n 'Clearing /tmp:'
        # prune quickly with one rm, then use find to clean up /tmp/[lq]*
        # (not needed with mfs /tmp, but doesn't hurt there...)
        (cd /tmp && rm -rf [a-km-pr-zA-Z]* &&
                find -d . ! -name . ! -name lost+found ! -name quota.user \
                ! -name quota.group -exec rm -rf -- {} \;)
        echo '.'
        ;;
esac



This archive was generated by hypermail 2b30 : Wed 15 Nov 2006 - 18:24:34 CET