Re: ifile lexing question

[email protected]
Newsgroups gmane.mail.ifile.general
Message-ID <[email protected]>
[email protected] writes:

> My theory for the daemonized version went like this:
> - daemon locks the DB file .idata with lockf.  (Is there a reason that's
>   non-reliable that I should use an independent lock file instead?)

The lockf() call has historically been dubious over NFS and possibly
other shared filesystems. I wouldn't worry about it too much, as
nobody seems to have screamed about the current total lack of
inter-machine locking.

> - daemon creates a unix-domain-socket .idata.socket

I was about to say that you could use the existence of this socket
itself as a locking mechanism, but putting sockets in shared
filesystems is also dubious - other machines can't use the socket, and
some filesystems, like AFS, simply won't let you put sockets there.

I'd create a file .idata.lock and put the socket somewhere in /tmp. 

> All that said, I think I'm out of cycles for this project for awhile.

Understood.

        - Nathan
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.