Path: utzoo!utgpu!watmath!clyde!att!osu-cis!tut.cis.ohio-state.edu!unmvax!ncar!ames!amdahl!pacbell!pbhyf!rob From: rob@pbhyf.PacBell.COM (Rob Bernardo) Newsgroups: comp.mail.elm Subject: Re: mailbox locking across multiple machines? Keywords: elm, mail, lockf, fcntl Message-ID: <4679@pbhyf.PacBell.COM> Date: 10 Feb 89 22:50:45 GMT References: <2434@eta.unix.ETA.COM> Reply-To: rob@pbhyf.PacBell.COM (Rob Bernardo) Distribution: na Organization: Pacific * Bell, San Ramon, CA Lines: 24 In article <2434@eta.unix.ETA.COM> rscott@eta.unix.ETA.COM (Rich Scott) writes: + Are there any patches/releases that use, say, lockf(3) or +fcntl(2) to lock /usr/spool/mail/username so that only one instance +of elm _on the network_ can read and modify it? Currently, elm only +does this right for two simultaneous sessions on the same machine. +Thanks ... Well, you can't use file locking because on some systems file locking is used to lock the mail file against updates to the mail file; you don't want it locked against new mail coming in the whole time you're using elm. I don't know about previous versions of ELM, but ELM 2.2 can be configured with a non-default directory for temporary files (default = /tmp on most systems). This is the directory where elm creates the file that locks against multiple sessions with the same mail file. What you would need to do is configure ELM so that the directory for temporary files is one shared between all systems that can acces the mail spool directory. -- Rob Bernardo, Pacific Bell UNIX/C Reusable Code Library Email: ...![backbone]!pacbell!pbhyf!rob OR rob@pbhyf.PacBell.COM Office: (415) 823-2417 Room 4E750A, San Ramon Valley Administrative Center Residence: (415) 827-4301 R Bar JB, Concord, California