From: Michael Meffie Date: Sun, 22 May 2011 00:56:23 +0000 (-0400) Subject: volinfo: print namei filenames of index files X-Git-Tag: upstream/1.8.0_pre1^2~3726 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=4999ed13d2355743e07587c8d7c4d23cbc073c5f;p=packages%2Fo%2Fopenafs.git volinfo: print namei filenames of index files On namei fileservers, also print the namei filenames of the volume special files when the -header flag is given. Change-Id: I90112f13d0f39348ee3862fdbdb55074e8877108 Reviewed-on: http://gerrit.openafs.org/4696 Tested-by: BuildBot Reviewed-by: Derrick Brashear --- diff --git a/src/vol/vol-info.c b/src/vol/vol-info.c index b41d762f4..4663c6477 100644 --- a/src/vol/vol-info.c +++ b/src/vol/vol-info.c @@ -448,6 +448,9 @@ HandleSpecialFile(const char *name, struct DiskPartition64 *dp, afs_sfsize_t size = 0; IHandle_t *ih = NULL; FdHandle_t *fdP = NULL; +#ifdef AFS_NAMEI_ENV + namei_t filename; +#endif /* AFS_NAMEI_ENV */ IH_INIT(ih, dp->device, header->parent, inode); fdP = IH_OPEN(ih); @@ -469,6 +472,10 @@ HandleSpecialFile(const char *name, struct DiskPartition64 *dp, if (!dsizeOnly && !saveinodes) { printf("\t%s inode\t= %s (size = %lld)\n", name, PrintInode(NULL, inode), size); +#ifdef AFS_NAMEI_ENV + namei_HandleToName(&filename, ih); + printf("\t%s namei\t= %s\n", name, filename.n_path); +#endif /* AFS_NAMEI_ENV */ } *psize += size;