From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8402 invoked from network); 16 Jul 1998 04:05:21 -0000 Received: from math.gatech.edu (list@130.207.146.50) by ns1.primenet.com.au with SMTP; 16 Jul 1998 04:05:21 -0000 Received: (from list@localhost) by math.gatech.edu (8.8.5/8.8.5) id XAA11106; Wed, 15 Jul 1998 23:53:03 -0400 (EDT) Resent-Date: Wed, 15 Jul 1998 23:46:09 -0400 (EDT) Message-ID: <19980715234957.51065@astaroth.nit.gwu.edu> Date: Wed, 15 Jul 1998 23:49:57 -0400 From: Sweth Chandramouli To: ZSH Users Subject: rolling over high-traffic logfiles? Mail-Followup-To: ZSH Users Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.89 Resent-Message-ID: <"0Mugm1.0.lh2.0UNhr"@math> Resent-From: zsh-users@math.gatech.edu X-Mailing-List: archive/latest/1674 X-Loop: zsh-users@math.gatech.edu X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu is there some easy way to roll over high-traffic logfiles in zsh, without losing any possible incoming data? i have a machine, for example, that receives syslog reports from many other machines on a network, which syslog.conf puts into the file /var/adm/extlog. for similar such files, i have a crontab entry that simply copies the log file to the file "log.`date`", and then copies /dev/null over the current logfile. this syslog file, however, is almost constatnly being updated. in the ideal world, i'd like to not have to worry about one or two entries getting added (and thus lost) to /var/adm/extlog in the time between when /var/adm/extlog.`date` is created and /dev/null gets copied over /var/adm/extlog. can zsh do some sort of file locking here? if not, does anyone have any other ideas on how to not lose and log entires? tia, sweth. -- Sweth Chandramouli IS Coordinator, The George Washington University / (202) 994 - 8521 (V) / (202) 994 - 0458 (F) *