Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.3 4.3bsd-beta 6/6/85; site gatech.CSNET Path: utzoo!watmath!clyde!cbosgd!gatech!spaf From: spaf@gatech.CSNET (Gene Spafford) Newsgroups: net.news.sa Subject: Re: Are there problems if expire runs while news is being received? Message-ID: <2054@gatech.CSNET> Date: Mon, 25-Nov-85 19:48:12 EST Article-I.D.: gatech.2054 Posted: Mon Nov 25 19:48:12 1985 Date-Received: Tue, 26-Nov-85 20:52:13 EST References: <186@pluto.UUCP> <5443@allegra.UUCP> Reply-To: spaf@gatech.UUCP (Gene Spafford) Organization: The Clouds Project, School of ICS, Georgia Tech Lines: 48 Rick Adams (rick@seismo.css.gov) posted a very nice fix to this problem some time back. Since it is small, I will post it again (here). First, create a file named "rnews.x" in your news library directory containing: exec /bin/cat $* > /usr/spool/news/rnews.$$ Next, you make your nightly news script do the following (I believe that the "install" command is a BSD-specific command; a combination of "cp", "chown" and "chmod" will replace it for other sites): #! /bin/sh umask 002 # Prevent additions to history file while expire is running /usr/bin/install -c -m 4755 -o news /usr/lib/news/rnews.x /usr/bin/rnews # actually expire the articles # if this was invoked manually, pass along the flags too cd /usr/lib/news /usr/lib/news/expire -v2 $* # get a fresh logfile /bin/mv log olog /bin/cp /dev/null log /bin/chmod 666 log /bin/cat olog >>log.mtd /bin/rm -f ohistory.pag ohistory.dir ohistory olog # turn rnews loose /bin/rm -f /usr/bin/rnews /bin/ln /usr/lib/news/inews /usr/bin/rnews cd /usr/spool/news for i in rnews.* do /usr/bin/rnews <$i /bin/rm -f $i done -- Gene "wedding done, thesis to go" Spafford The Clouds Project, School of ICS, Georgia Tech, Atlanta GA 30332 CSNet: Spaf @ GATech ARPA: Spaf%GATech.CSNet @ Relay.CS.NET uucp: ...!{akgua,decvax,hplabs,ihnp4,linus,seismo,ulysses}!gatech!spaf