Re: fifos over NFS

[ Available lists | Index of freebsd-hackers | Month of Oct 2000 | Week of 6 Oct 2000 | Raw email | View thread | Wrap long lines | Reply | Tag ]
From
Dan Nelson <dnelson@emsphone.com>
Date
6 Oct 2000 11:40:24
Subject
Re: fifos over NFS
Message-ID
20001006134017.A13617@dan.emsphone.com

References to

[ Hide this part ]
In the last episode (Oct 06), Paul Herman said:
> On Fri, 6 Oct 2000, Dan Nelson wrote:
> > I think that's expected behaviour. Fifos should be usable on NFS
> > mounts, but an active fifo is only usable for processes running on
> > the same machine.
>
> That's cool, seems reasonable.
>
> BTW, the hanging behavior I was seeing didn't have anything to do
> with NFS -- it was the same if I tried to write to a local fifo with
> nothing listening on the other side (no NFS).

That's how fifos work; you're blocking on the open, not the write.
Open with O_NONBLOCK if you want to the call to fail if there's no-one
at the other end.

> So I guess opening a fifo over NFS doesn't even reach nfs_open() in
> sys/nfs/nfs_vnops.c which would return an EACCES on a VFIFO. OK, I
> think I'm satisfied. Thanks!

That's probably the case, if you're looking at the server code. If a
client ever actually tried to open a fifo over NFS (say they're running
an OS that doesn't know about them, like Windows), it'll return the
error. My guess is that on the Unix client end, the open request is
handled by the kernel and nothing is ever sent to the remote NFS server
(just like opening a devicenode).

--
Dan Nelson
dnelson@emsphone.com


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message



Elapsed time: 0.106 seconds