Great Circle Associates Majordomo-Workers
(October 1996)
 

Indexed By Date: [Previous] [Next] Indexed By Thread: [Previous] [Next]

Subject: Re: Simultaneous opens for list file. Questions.
From: Chan Wilson <cwilson @ slurp . neu . sgi . com>
Date: Tue, 15 Oct 1996 23:02:10 +0200
To: zielonko @ ucx . lkg . dec . com (Karol Zielonko - UCX engineering - (508)-486-5632)
Cc: Majordomo-Workers @ greatcircle . com
In-reply-to: Your message of "Fri, 11 Oct 1996 11:24:43 EDT." <96101111244376@ucx.lkg.dec.com>

> I tracked it down in the code and I know why it's happening. The majordomo
> script calls the shlock routine lopen() to open the list file for append access
> and then procedes to call is_list_member() for the file which then opens the
> file for input. To refresh your memory, here is an excerpt from majordomo.

Uh huh.

> change it.  Could you please tell me if you know of any other places in the code
> where this technique is used? I am worried that the same thing might be hidden

I think most, if not all, of the file operations are done this way.
Since VMS doesn't allow concurrent access to a file (!), you can
likely get rid of the first call to lopen() and have it work fine.

> Please correct me if I'm wrong, the race condition mentioned in the comments is
> two or more majordomo processes all trying to access the list file, no? You
> prevent it by calling lopen() to lock the file so that the second process blocks
> until the lock is released, no?

Ummm, mostly no, yes. Or would that be yes, mostly no?  ;-?  'ja?

One race condition exists for multiple MDs accessing the same list,
correct.

Another race condition, which I don't think is likely, is a security
race.  That applies mostly to privileged processes...

--Chan


References:
Indexed By Date Previous: Re: Cryptic resend failute?
From: Dave Wolfe <dwolfe@risc.sps.mot.com>
Next: Re: Cryptic resend failute?
From: Jason L Tibbitts III <tibbs@hpc.uh.edu>
Indexed By Thread Previous: Simultaneous opens for list file. Questions.
From: zielonko@ucx.lkg.dec.com (Karol Zielonko - UCX engineering - (508)-486-5632)
Next: bug report 1.94b4
From: "Vincent D. Skahan" <vds7789@aw101.iasl.ca.boeing.com>

Google
 
Search Internet Search www.greatcircle.com