From owner-freebsd-stable Wed Dec 15 14:58:31 1999 Delivered-To: freebsd-stable@freebsd.org Received: from ramstind.gtf.ol.no (ramstind.gtf.ol.no [128.39.174.16]) by hub.freebsd.org (Postfix) with ESMTP id 053131519B for ; Wed, 15 Dec 1999 14:58:28 -0800 (PST) (envelope-from trond@ramstind.gtf.ol.no) Received: from localhost (trond@localhost) by ramstind.gtf.ol.no (8.9.3/8.9.3) with ESMTP id XAA75063; Wed, 15 Dec 1999 23:58:20 +0100 (CET) (envelope-from trond@ramstind.gtf.ol.no) Date: Wed, 15 Dec 1999 23:58:20 +0100 (CET) From: Trond Endrestol To: SitePlus Web Services Cc: "freebsd-stable@FreeBSD.ORG" Subject: Re: /var full In-Reply-To: <3857AFC2.398188F0@siteplus.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=ISO-8859-1 Content-Transfer-Encoding: 8BIT Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Wed, 15 Dec 1999, SitePlus Web Services wrote: > Hi all, > > I am new to this. My web server is beginning to get pretty busy and I > noticed today that /var was at 90% I moved and linked log and mail to > /usr/log and /usr/mail but it is still pretty full. When I set up the > server I allotted / and /var both 100megs. I suppose that was not > enough for /var. > > Any more suggestions, May I suggest enabling rotation of the web server log files. In /etc/newsyslog.conf add the following lines (I assume you are running Apache): /var/log/httpd-access.log 644 5 100 * Z /var/run/httpd.pid /var/log/httpd-error.log 644 5 100 * Z /var/run/httpd.pid This will give you 5 generations of the previous log files in addition to the current ones. Each rotation will be performed on the hour by newsyslog (engaged by cron) when the current log file exceeds 100 kB. Apache will also be notified with a SIGHUP and the PID is obtained from /var/run/httpd.pid. Take a look at the manpage for newsyslog(8) and look in /etc/newsyslog.conf for more details. You may need to adjust the lines for /etc/newsyslog.conf if you run a different web server. ---------------------------------------------------------------------- Trond Endrestøl | trond@gtf.ol.no Merkantilvegen 59HB7, | trond@ramstind.gtf.ol.no N-2815 GJØVIK, NORWAY |+47 61139424 || +47 63874242 Patron of The Art of Computer Programming| FreeBSD 3.3 & Pine 4.10 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message