From owner-freebsd-questions@FreeBSD.ORG Sat Apr 17 09:31:35 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DA38A16A4CE for ; Sat, 17 Apr 2004 09:31:35 -0700 (PDT) Received: from sarevok.webteckies.org (e236040.upc-e.chello.nl [213.93.236.40]) by mx1.FreeBSD.org (Postfix) with ESMTP id DDD1743D48 for ; Sat, 17 Apr 2004 09:31:34 -0700 (PDT) (envelope-from mdev@sarevok.webteckies.org) Received: by sarevok.webteckies.org (Postfix, from userid 100) id 686E6B958; Sat, 17 Apr 2004 18:31:33 +0200 (CEST) From: Melvyn Sopacua Organization: WebTeckies.org To: Matthew Seaman , Canggung Mendonan , "freebsd-questions@freebsd.org" Date: Sat, 17 Apr 2004 18:31:24 +0200 User-Agent: KMail/1.6.1 References: <20040416230102.H2835@ybpnyubfg> <20040417160012.GA75477@happy-idiot-talk.infracaninophile.co.uk> In-Reply-To: <20040417160012.GA75477@happy-idiot-talk.infracaninophile.co.uk> MIME-Version: 1.0 Content-Type: multipart/signed; protocol="application/pgp-signature"; micalg=pgp-sha1; boundary="Boundary-02=_kvVgAGVHONF52m1"; charset="iso-8859-15" Content-Transfer-Encoding: 7bit Message-Id: <200404171831.32687.freebsd-questions@webteckies.org> Subject: Re: ipmon fills up partition X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Apr 2004 16:31:36 -0000 --Boundary-02=_kvVgAGVHONF52m1 Content-Type: text/plain; charset="iso-8859-15" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On Saturday 17 April 2004 18:00, Matthew Seaman wrote: > > Adding /var/run/ipmon.pid at the end of newsyslog.conf line above stops > > the above symptom, but ipmon stopped logging after each rotation. > > This should be the correct thing to do: ipmon should interpret a HUP > signal to mean 'reopen log files' -- unless it's changed dramatically > between 4.x and 5.x[*], in which case you'll have to hunt down what > should be done instead by reading the documentation or the code or > something. It does: ipmon.c:1452 if (donehup) { donehup =3D 0; if (newlog) { fclose(log); log =3D newlog; newlog =3D NULL; } } And: static void handlehup(sig) int sig; { FILE *fp; signal(SIGHUP, handlehup); if (logfile && (fp =3D fopen(logfile, "a"))) newlog =3D fp; init_tabs(); donehup =3D 1; } The only codepath I can see, that could cause this behavior, would be if th= e=20 fopen fails, because newsyslog is holding a lock on the file at the time it= =20 signals ipmon. =2D-=20 Melvyn =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D =46reeBSD sarevok.webteckies.org 5.2-CURRENT FreeBSD 5.2-CURRENT #3: Sun Ap= r 4=20 02:24:06 CEST 2004 =20 root@sarevok.webteckies.org:/usr/obj/usr/src/sys/SAREVOK_NOAPM_NODEBUG i386 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D --Boundary-02=_kvVgAGVHONF52m1 Content-Type: application/pgp-signature Content-Description: signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (FreeBSD) iD8DBQBAgVvkOv9JNmfFN5URAp2dAJ0QDbqGPXOFa8VHsvIYRVtb/K7rZgCfSdOI FGoTfNXYuigzq3WElwhrEew= =0rnC -----END PGP SIGNATURE----- --Boundary-02=_kvVgAGVHONF52m1--