Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!rutgers!sri-unix!ctnews!pyramid!prls!philabs!ttidca!mb From: mb@ttidca.TTI.COM (Michael Bloom) Newsgroups: comp.unix.wizards Subject: Re: NFS and EWOULDBLOCK (why not?) Message-ID: <900@ttidca.TTI.COM> Date: Tue, 30-Jun-87 20:29:41 EDT Article-I.D.: ttidca.900 Posted: Tue Jun 30 20:29:41 1987 Date-Received: Fri, 3-Jul-87 04:59:28 EDT References: <1446@xanth.UUCP> Reply-To: mb@ttidca.TTI.COM (Michael A. Bloom) Organization: Citicorp/TTI, Santa Monica Lines: 27 In article <1446@xanth.UUCP> kyle@xanth.UUCP (Kyle Jones) writes: >Why can't the relevant system calls that can be blocked by an overloaded or >dead NFS server return -1, with errno == EWOULDBLOCK? > >kyle jones old dominion university, norfolk, va We do something like this at TTI. In the retry loop in rfscall (which is right after the clget call in rfscall), we add a test for a server being down. If it is, we do the following: { /* MB, ER - Citicorp/TTI */ status = rpcerr.re_status = RPC_SYSTEMERROR; rpcerr.re_errno = EHOSTDOWN; goto splitfast; } The splitfast label is added just before the mi_printed = 0 and clfree call near the bottom of the routine The way we test for a server being down is very site dependant, allowing for a maximum of 4 class C networks. It uses a table, indexed by network and host, that a daemon we call nfsmonitor modifies by writing kmem. - Michael Bloom Citicorp/TTI (213 450-9111x3097)