]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
STABLE12-volser-dump-vnode-include-volid-in-error-20030213
authorDerrick Brashear <shadow@dementia.org>
Fri, 4 Apr 2003 09:29:47 +0000 (09:29 +0000)
committerDerrick Brashear <shadow@dementia.org>
Fri, 4 Apr 2003 09:29:47 +0000 (09:29 +0000)
include a volume number in the error message

(cherry picked from commit 7c8bd23f40a18027b9229376bf9dacdbc9a2879b)

src/volser/dumpstuff.c

index 28e9626db7450ba55ac59c2882f0858929ad9d3b..ab6e9662d1f562bc0f1161325234110de2ac2067 100644 (file)
@@ -75,7 +75,7 @@ static int DumpPartial(register struct iod *iodp, register Volume *vp,
 static int DumpVnodeIndex(register struct iod *iodp, Volume *vp,
                          VnodeClass class, afs_int32 fromtime, int forcedump);
 static int DumpVnode(register struct iod *iodp, struct VnodeDiskObject *v,
-                    int vnodeNumber, int dumpEverything);
+                    int volid, int vnodeNumber, int dumpEverything);
 static int ReadDumpHeader(register struct iod *iodp, struct DumpHeader *hp);
 static int ReadVnodes(register struct iod *iodp, Volume *vp,
                      int incremental, afs_int32 *Lbuf, afs_int32 s1,
@@ -659,7 +659,7 @@ static int DumpVnodeIndex(register struct iod *iodp, Volume *vp,
        /* Note:  the >= test is very important since some old volumes may not have
           a serverModifyTime.  For an epoch dump, this results in 0>=0 test, which
           does dump the file! */
-       if (!code) code = DumpVnode(iodp, vnode, bitNumberToVnodeNumber(vnodeIndex, class), flag);
+       if (!code) code = DumpVnode(iodp, vnode, V_id(vp), bitNumberToVnodeNumber(vnodeIndex, class), flag);
        if (!flag) IOMGR_Poll(); /* if we dont' xfr data, but scan instead, could lose conn */
     }
     STREAM_CLOSE(file);
@@ -686,7 +686,7 @@ static int DumpDumpHeader(register struct iod *iodp, register Volume *vp,
 }
 
 static int DumpVnode(register struct iod *iodp, struct VnodeDiskObject *v,
-                    int vnodeNumber, int dumpEverything)
+                    int volid, int vnodeNumber, int dumpEverything)
 {
     int code = 0;
     IHandle_t *ihP;
@@ -715,8 +715,8 @@ static int DumpVnode(register struct iod *iodp, struct VnodeDiskObject *v,
        IH_INIT(ihP, iodp->device, iodp->parentId, VNDISK_GET_INO(v));
        fdP = IH_OPEN(ihP);
        if (fdP == NULL) {
-           Log("1 Volser: DumpVnode: dump: Unable to open inode %d for vnode %d; not dumped, error %d\n",
-               VNDISK_GET_INO(v), vnodeNumber, errno);
+           Log("1 Volser: DumpVnode: dump: Unable to open inode %d for vnode %d (volume %d); not dumped, error %d\n",
+               VNDISK_GET_INO(v), vnodeNumber, volid, errno);
            IH_RELEASE(ihP);
            return VOLSERREAD_DUMPERROR;
        }