nfs: log stale mount errors occasionally
log the state mount errors only occasionally so as not to fill log file with too many of them. Change-Id: Ib5a2485dc2ce3a181cff34bbb6d7aba17a2e4d4d BUG: 804301 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.org/5229 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
This commit is contained in:
parent
eb6b81e1fc
commit
bda60de187
@ -226,20 +226,22 @@ out:
|
||||
uuid_unparse (handle->exportid, exportid); \
|
||||
uuid_unparse (handle->gfid, gfid); \
|
||||
trans = rpcsvc_request_transport (req); \
|
||||
gf_log (GF_NFS3, GF_LOG_ERROR, "Failed to map " \
|
||||
"FH to vol: client=%s, exportid=%s, gfid=%s",\
|
||||
trans->peerinfo.identifier, exportid, \
|
||||
gfid); \
|
||||
gf_log (GF_NFS3, GF_LOG_ERROR, \
|
||||
"Stale nfs client %s must be trying to "\
|
||||
"connect to a deleted volume, please " \
|
||||
"unmount it.", trans->peerinfo.identifier);\
|
||||
GF_LOG_OCCASIONALLY (nfs3state->occ_logger, \
|
||||
GF_NFS3, GF_LOG_ERROR, "Failed to map " \
|
||||
"FH to vol: client=%s, exportid=%s, " \
|
||||
"gfid=%s", trans->peerinfo.identifier, \
|
||||
exportid, gfid); \
|
||||
GF_LOG_OCCASIONALLY (nfs3state->occ_logger, \
|
||||
GF_NFS3, GF_LOG_ERROR, "Stale nfs " \
|
||||
"client %s must be trying to connect to"\
|
||||
" a deleted volume, please unmount it.",\
|
||||
trans->peerinfo.identifier); \
|
||||
status = NFS3ERR_STALE; \
|
||||
goto label; \
|
||||
} else { \
|
||||
gf_log (GF_NFS3, GF_LOG_TRACE, "FH to Volume: %s"\
|
||||
,volume->name); \
|
||||
rpcsvc_request_set_private (req, volume); \
|
||||
gf_log (GF_NFS3, GF_LOG_TRACE, "FH to Volume:" \
|
||||
"%s", volume->name); \
|
||||
rpcsvc_request_set_private (req, volume); \
|
||||
} \
|
||||
} while (0); \
|
||||
|
||||
|
@ -134,6 +134,7 @@ typedef struct nfs3_state {
|
||||
struct list_head fdlru;
|
||||
gf_lock_t fdlrulock;
|
||||
int fdcount;
|
||||
uint32_t occ_logger;
|
||||
} nfs3_state_t;
|
||||
|
||||
typedef enum nfs3_lookup_type {
|
||||
|
Loading…
x
Reference in New Issue
Block a user