From owner-freebsd-questions@FreeBSD.ORG Fri Jun 1 12:28:20 2007 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 5A99416A400 for ; Fri, 1 Jun 2007 12:28:20 +0000 (UTC) (envelope-from jonathan@hst.org.za) Received: from sirian.hst.org.za (sirian.hst.org.za [209.203.2.130]) by mx1.freebsd.org (Postfix) with ESMTP id AE49913C480 for ; Fri, 1 Jun 2007 12:28:17 +0000 (UTC) (envelope-from jonathan@hst.org.za) Received: from localhost (localhost.hst.org.za [127.0.0.1]) by sirian.hst.org.za (Postfix) with ESMTP id 60E3731D2F6; Fri, 1 Jun 2007 14:24:51 +0200 (SAST) Received: from sirian.hst.org.za ([127.0.0.1]) by localhost (sirian.hst.org.za [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 07709-05; Fri, 1 Jun 2007 14:24:51 +0200 (SAST) Received: from sysadmin.hst.org.za (sysadmin.int.dbn.hst.org.za [10.1.1.20]) by sirian.hst.org.za (Postfix) with ESMTP id 8F8EB31D2ED; Fri, 1 Jun 2007 14:24:50 +0200 (SAST) From: Jonathan McKeown Organization: Health Systems Trust To: freebsd-questions@freebsd.org Date: Fri, 1 Jun 2007 14:31:48 +0200 User-Agent: KMail/1.7.2 References: <46600D05.2070709@ibctech.ca> In-Reply-To: <46600D05.2070709@ibctech.ca> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200706011431.48560.jonathan@hst.org.za> X-Virus-Scanned: by amavisd-new at hst.org.za Cc: mats.lindberg@se.transport.bombardier.com Subject: Re: purging old mail X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 01 Jun 2007 12:28:20 -0000 On Friday 01 June 2007 14:11, Steve Bertrand wrote: > mats.lindberg@se.transport.bombardier.com wrote: > > Hi all, > > I'm setting up a FreeBSD 5.4 system that need to run unattended for a > > year or more. > > I've noticed that the /var/mail/root file grows a bit over time. > > > > Do I need to configure the system in some way to prevent this file from > > growing indefinately, filling up the /var partition? > > Are you actually interested in reading root mail? > > Are you running sendmail? > > If so, in the /etc/mail/aliases file, change the root alias to an email > address that someone actually POP's. > > If you don't want to read the email at all, change the root alias to > point to /dev/null. What I've been caught by a couple of times is the periodic(8) routines, which quickly fill roots mailbox with daily, weekly and monthly status reports. If you're not going to forward these to a real user but still want to keep (some of) them available, put daily_output="/var/log/daily.log" weekly_output="/var/log/weekly.log" monthly_output="/var/log/monthly.log" in /etc/periodic.conf. The relevant reports will be logged into the respective files, and newsyslog already knows to rotate these if they exist, so they won't grow endlessly (by default, /etc/newsyslog.conf keeps a week of dailys, 5 weeks of weeklys and a year of monthlys). Jonathan