From owner-freebsd-bugs Tue Jun 23 11:20:17 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id LAA04893 for freebsd-bugs-outgoing; Tue, 23 Jun 1998 11:20:17 -0700 (PDT) (envelope-from owner-freebsd-bugs@FreeBSD.ORG) Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id LAA04808 for ; Tue, 23 Jun 1998 11:20:09 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.8.8/8.8.5) id LAA01126; Tue, 23 Jun 1998 11:20:01 -0700 (PDT) Received: from www.video-collage.com (www.video-collage.com [206.15.171.132]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id LAA04577 for ; Tue, 23 Jun 1998 11:18:23 -0700 (PDT) (envelope-from mi@xxx.video-collage.com) Received: from xxx.video-collage.com (xxx.video-collage.com [199.232.254.68]) by www.video-collage.com (8.8.5/8.8.5) with ESMTP id OAA13693 for ; Tue, 23 Jun 1998 14:15:39 -0400 (EDT) Received: (from root@localhost) by xxx.video-collage.com (8.8.8/8.8.7) id OAA20948; Tue, 23 Jun 1998 14:17:57 -0400 (EDT) (envelope-from mi) Message-Id: <199806231817.OAA20948@xxx.video-collage.com> Date: Tue, 23 Jun 1998 14:17:57 -0400 (EDT) From: Mikhail Teterin Reply-To: mi@aldan.algebra.com To: FreeBSD-gnats-submit@FreeBSD.ORG X-Send-Pr-Version: 3.2 Subject: bin/7033: newsyslog's new option Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org >Number: 7033 >Category: bin >Synopsis: Same process notified multiple times >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Tue Jun 23 11:20:01 PDT 1998 >Last-Modified: >Originator: Mikhail Teterin >Organization: Virtual Estates, Inc. >Release: FreeBSD 3.0-CURRENT >Environment: >Description: After finishing rotating the logs, newsyslog duly notifies the processes involved. The last (optional) argument on the line specifies the file the process-id of the process to be notified. If the same process is concerned about several files, it gets notified several times: Jun 23 14:04:53 xxx squid[318]: Restarting Squid Cache (version 1.1.8)... Jun 23 14:04:54 xxx squid[318]: Ready to serve requests. Jun 23 14:05:03 xxx squid[318]: Restarting Squid Cache (version 1.1.8)... Jun 23 14:05:04 xxx squid[318]: Ready to serve requests. Jun 23 14:05:13 xxx squid[318]: Restarting Squid Cache (version 1.1.8)... Jun 23 14:05:14 xxx squid[318]: Ready to serve requests. >How-To-Repeat: Add this to your /etc/newsyslog.conf for example: /var/log/squid.access.log 664 3 * 168 Z /var/run/squid.pid /var/log/squid.cache.log 664 3 * 168 Z /var/run/squid.pid /var/log/squid.store.log 664 3 * 168 Z /var/run/squid.pid >Fix: Only list the file once is the almost working work-around. It fails if there are different conditions affect different files. Please, have in mind that the same process may happen to be listed in several files. So, the list of processes should first be "uniq"-ed... >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message