SUNRPC: Retry rpcbind requests if the server's portmapper isn't up
authorChuck Lever <cel@netapp.com>
Fri, 7 Oct 2005 03:12:58 +0000 (23:12 -0400)
committerTrond Myklebust <Trond.Myklebust@netapp.com>
Tue, 18 Oct 2005 21:20:10 +0000 (14:20 -0700)
 After a server crash/reboot, rebinding should always retry, otherwise
 requests on "hard" mounts will fail when they shouldn't.

 Test plan:
 Run a lock-intensive workload against a server while rebooting the server
 repeatedly.

Signed-off-by: Chuck Lever <cel@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
net/sunrpc/clnt.c

index 5a8f01d726e995a8d441ee0b30ddddd2121deade..a5f7029b1daa88b5dc34d671ee8571dc5991cb0b 100644 (file)
@@ -759,7 +759,8 @@ call_bind_status(struct rpc_task *task)
        case -EACCES:
                dprintk("RPC: %4d remote rpcbind: RPC program/version unavailable\n",
                                task->tk_pid);
-               break;
+               rpc_delay(task, 3*HZ);
+               goto retry_bind;
        case -ETIMEDOUT:
                dprintk("RPC: %4d rpcbind request timed out\n",
                                task->tk_pid);