[Samba] Re: locks cooperating with a server side process

Adam Tauno WIlliams adam at morrison-ind.com
Tue Jul 20 20:04:52 GMT 2004


> > I'm having a problem where I can gain the lock but the process is
> > still writing to the file.

If your building a 'drop box' so to speak, where a process picks up
files after they are copied in, perhaps you want to look into hooking
for application into 'fam'

http://oss.sgi.com/projects/fam/

man fam: 
...
       fam  is a server that tracks changes to the filesystem and
       relays these changes to interested applications.  Applica­
       tions  such as fm(1G) and mailbox(1) present an up-to-date
       view of the filesystem.  In  the  absence  of  fam,  these
       applications  and  others like them are forced to poll the
       filesystem to detect changes.  fam is more efficient.
 
       Applications can request  fam  to  monitor  any  files  or
       directories  in  any filesystem.  When fam detects changes
       to monitored files, it notifies the  appropriate  applica­
       tion.   The  FAM  API provides a programmatic interface to
       fam; see fam(3X).
                                                                                
       fam is informed of filesystem changes as  they  happen  by
       the  kernel through the imon(7M) pseudo device driver.  If
       asked to monitor files on an NFS mounted  filesystem,  fam
       tries  to  use fam on the NFS server to monitor files.  If
       fam cannot contact  a  remote  fam,  it  polls  the  files
       instead.  fam also polls special files.
...



More information about the samba mailing list