When the NFSv3 access method is called and there is no correspoding
authorzoulasc <christos@zoulas.com>
Fri, 22 Jan 2016 15:12:52 +0000 (10:12 -0500)
committerzoulasc <christos@zoulas.com>
Fri, 22 Jan 2016 15:12:52 +0000 (10:12 -0500)
mount point for the path we requested, we need to return ESTALE so
that the kernel will then perform an NFSv3 lookup and the mount point
will be re-mounted.

If there is no map entry to mount, the NFSv3 lookup method will
return the failure.

(Ian Kent)

amd/nfs_subr.c

index ef07a4a977266ebdeaa3cc3f88346cf14cf68fe2..85cf98c203cca9617589166ba9e938d751cbe5b1 100644 (file)
@@ -1239,9 +1239,9 @@ am_nfs3_access_3_svc(am_ACCESS3args *argp, struct svc_req *rqstp)
   if (!mp) {
     post_op_obj = &result.res_u.fail.obj_attributes;
     post_op_obj->attributes_follow = 0;
-    result.status = nfs_error(ENOENT);
+    result.status = nfs_error(ESTALE);
     if (amuDebug(D_TRACE))
-      plog(XLOG_DEBUG, "access_3: ENOENT");
+      plog(XLOG_DEBUG, "access_3: ESTALE");
   } else {
     nfsfattr *fattr = &mp->am_fattr;
     am_fattr3 *fattr3;