🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nntp
3 messages
3 total messages Started by Evan Champion Tue, 23 Jan 1996 00:00
rnews locking
#4174
Author: Evan Champion
Date: Tue, 23 Jan 1996 00:00
21 lines
1173 bytes
I have a problem whereby when multiple rnews are running they have a
tendancy to eventually all start processing the exact same news
batches.

In my case, I solved it by adding a | O_EXLOCK to the open() that
opens the news batch.

I am sure that I am not the only one that has run in to this problem.
I am thinking that an rnews that does proper file locking would be a
good addition to an upcoming inn1.4unoff release.

Is there already an rnews implementation that does file locking with
good cross-platform support that could replace the current rnews, or
does anyone have a set of patches that add locking support to the INN
rnews?

Evan



Re: rnews locking
#4267
Author: Rich Salz
Date: Wed, 24 Jan 1996 00:00
10 lines
848 bytes
In <4e1q28$4ic@piano.synapse.net> evanc@synapse.net (Evan Champion) writes:
>I have a problem whereby when multiple rnews are running they have a
>tendancy to eventually all start processing the exact same news
>batches.

Don't do that.

Make rnews a shell script that calls shlock.

Re: rnews locking
#4824
Author: John Milburn
Date: Sun, 11 Feb 1996 00:00
31 lines
1222 bytes
rsalz@uunet.uu.net (Rich Salz) writes:
>In <4e1q28$4ic@piano.synapse.net> evanc@synapse.net (Evan Champion) writes:
>>I have a problem whereby when multiple rnews are running they have a
>>tendancy to eventually all start processing the exact same news
>>batches.

>Don't do that.

>Make rnews a shell script that calls shlock.

And a simple script it is.

-jem

#!/bin/sh

##  =()<. @<_PATH_SHELLVARS>@>()=
. /inn/lib/innshellvars

LOCK=${LOCKS}/LOCK.rnewsU

trap 'rm -f ${LOCK} ; exit 1' 1 2 3 15
if ${NEWSBIN}/shlock -p $$ -f ${LOCK} ; then
    ${RNEWS} -U
    exit 0
else
    exit 0
fi


Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads