windows-volstat-vl-unknown-20080214

LICENSE MIT

Add volumes in the vl_unknown state to the list of objects to be
checked as offline or retried when an allbusy error is received
in cm_Analyze.
This commit is contained in:
Jeffrey Altman 2008-02-15 03:23:44 +00:00
parent 1133cc4418
commit 093433b981
3 changed files with 9 additions and 7 deletions

View File

@ -280,7 +280,7 @@ cm_Analyze(cm_conn_t *connp, cm_user_t *userp, cm_req_t *reqp,
else if (fidp->volume == volp->bk.ID)
statep = &volp->bk;
if (statep->state != vl_offline) {
if (statep->state != vl_offline && statep->state != vl_unknown) {
retry = 1;
} else {
if (cm_CheckOfflineVolume(volp, statep->ID))
@ -312,7 +312,9 @@ cm_Analyze(cm_conn_t *connp, cm_user_t *userp, cm_req_t *reqp,
else if (fidp->volume == volp->bk.ID)
statep = &volp->bk;
if (statep->state != vl_offline && statep->state != vl_busy) {
if (statep->state != vl_offline &&
statep->state != vl_busy &&
statep->state != vl_unknown) {
retry = 1;
} else {
if (!serversp) {

View File

@ -638,8 +638,8 @@ long cm_GetSCache(cm_fid_t *fidp, cm_scache_t **outScpp, cm_user_t *userp,
long code;
cm_volume_t *volp = NULL;
cm_cell_t *cellp;
int special; // yj: boolean variable to test if file is on root.afs
int isRoot;
int special = 0; // yj: boolean variable to test if file is on root.afs
int isRoot = 0;
extern cm_fid_t cm_rootFid;
hash = CM_SCACHE_HASH(fidp);

View File

@ -1010,7 +1010,7 @@ cm_CheckOfflineVolume(cm_volume_t *volp, afs_uint32 volID)
lock_ObtainMutex(&volp->mx);
if (volp->rw.ID != 0 && (!volID || volID == volp->rw.ID) &&
(volp->rw.state == vl_busy || volp->rw.state == vl_offline)) {
(volp->rw.state == vl_busy || volp->rw.state == vl_offline || volp->rw.state == vl_unknown)) {
cm_InitReq(&req);
for (serversp = volp->rw.serversp; serversp; serversp = serversp->next) {
@ -1045,7 +1045,7 @@ cm_CheckOfflineVolume(cm_volume_t *volp, afs_uint32 volID)
}
if (volp->ro.ID != 0 && (!volID || volID == volp->ro.ID) &&
(volp->ro.state == vl_busy || volp->ro.state == vl_offline)) {
(volp->ro.state == vl_busy || volp->ro.state == vl_offline || volp->ro.state == vl_unknown)) {
cm_InitReq(&req);
for (serversp = volp->ro.serversp; serversp; serversp = serversp->next) {
@ -1080,7 +1080,7 @@ cm_CheckOfflineVolume(cm_volume_t *volp, afs_uint32 volID)
}
if (volp->bk.ID != 0 && (!volID || volID == volp->bk.ID) &&
(volp->bk.state == vl_busy || volp->bk.state == vl_offline)) {
(volp->bk.state == vl_busy || volp->bk.state == vl_offline || volp->bk.state == vl_unknown)) {
cm_InitReq(&req);
for (serversp = volp->bk.serversp; serversp; serversp = serversp->next) {