From 6759c2cb63625eb517613a8cd52047de8747d99c Mon Sep 17 00:00:00 2001 From: thantry Date: Wed, 13 Nov 2002 04:05:47 +0000 Subject: [PATCH] Name changes to make all file system statistics names common across the /proc/lustre hierarchy. See comment in Bug #320 --- lustre/lov/lproc_lov.c | 14 +++++++------- lustre/mdc/lproc_mdc.c | 6 +++--- lustre/mds/lproc_mds.c | 12 ++++++------ lustre/obdfilter/lproc_obdfilter.c | 12 +++++++++--- lustre/osc/lproc_osc.c | 37 +++++++++++++++---------------------- lustre/ost/lproc_ost.c | 12 ++++++------ 6 files changed, 46 insertions(+), 47 deletions(-) diff --git a/lustre/lov/lproc_lov.c b/lustre/lov/lproc_lov.c index 97bc841..4845f41 100644 --- a/lustre/lov/lproc_lov.c +++ b/lustre/lov/lproc_lov.c @@ -128,19 +128,19 @@ int rd_kbfree(char* page, char **start, off_t off, int count, int *eof, return 0; } -int rd_numobjects(char* page, char **start, off_t off, int count, int *eof, +int rd_filestotal(char* page, char **start, off_t off, int count, int *eof, void *data) { return 0; } -int rd_objfree(char* page, char **start, off_t off, int count, int *eof, - void *data) +int rd_filesfree(char* page, char **start, off_t off, int count, int *eof, + void *data) { return 0; } -int rd_objgroups(char* page, char **start, off_t off, int count, int *eof, +int rd_filegroups(char* page, char **start, off_t off, int count, int *eof, void *data) { return 0; @@ -178,9 +178,9 @@ struct lprocfs_vars status_var_nm_1[] = { {"status/stripetype", rd_stripetype, 0, 0}, {"status/numobd",rd_numobd, 0, 0}, {"status/activeobd", rd_activeobd, 0, 0}, - {"status/objects", rd_numobjects, 0, 0}, - {"status/objectsfree", rd_objfree, 0, 0}, - {"status/objectgroups", rd_objgroups, 0, 0}, + {"status/filestotal", rd_filestotal, 0, 0}, + {"status/filesfree", rd_filesfree, 0, 0}, + {"status/filegroups", rd_filegroups, 0, 0}, {"status/blocksize", rd_blksize, 0, 0}, {"status/kbytestotal", rd_kbtotal, 0, 0}, {"status/kbytesfree", rd_kbfree, 0, 0}, diff --git a/lustre/mdc/lproc_mdc.c b/lustre/mdc/lproc_mdc.c index 357c1de..b0fcad6 100644 --- a/lustre/mdc/lproc_mdc.c +++ b/lustre/mdc/lproc_mdc.c @@ -54,8 +54,8 @@ int rd_kbfree(char* page, char **start, off_t off, int count, int *eof, } -int rd_files(char* page, char **start, off_t off, int count, int *eof, - void *data) +int rd_filestotal(char* page, char **start, off_t off, int count, int *eof, + void *data) { return 0; } @@ -106,7 +106,7 @@ struct lprocfs_vars status_var_nm_1[] = { {"status/blocksize",rd_blksize, 0, 0}, {"status/kbytestotal",rd_kbtotal, 0, 0}, {"status/kbytesfree", rd_kbfree, 0, 0}, - {"status/files", rd_files, 0, 0}, + {"status/filestotal", rd_filestotal, 0, 0}, {"status/filesfree", rd_filesfree, 0, 0}, {"status/filegroups", rd_filegroups, 0, 0}, {"status/mds_server_uuid", rd_server_uuid, 0, 0}, diff --git a/lustre/mds/lproc_mds.c b/lustre/mds/lproc_mds.c index 904c18f..0fc96bd 100644 --- a/lustre/mds/lproc_mds.c +++ b/lustre/mds/lproc_mds.c @@ -114,8 +114,8 @@ int rd_fstype(char* page, char **start, off_t off, int count, int *eof, } -int rd_files(char* page, char **start, off_t off, int count, int *eof, - void *data) +int rd_filestotal(char* page, char **start, off_t off, int count, int *eof, + void *data) { struct obd_device* temp = (struct obd_device*)data; struct mds_obd *mds = &temp->u.mds; @@ -152,8 +152,8 @@ int rd_filesfree(char* page, char **start, off_t off, int count, int *eof, return len; } -int rd_filesets(char* page, char **start, off_t off, int count, int *eof, - void *data) +int rd_filegroups(char* page, char **start, off_t off, int count, int *eof, + void *data) { return 0; } @@ -163,9 +163,9 @@ struct lprocfs_vars status_var_nm_1[]={ {"status/kbytestotal",rd_kbtotal, 0, 0}, {"status/kbytesfree", rd_kbfree, 0, 0}, {"status/fstype", rd_fstype, 0, 0}, - {"status/files", rd_files, 0, 0}, + {"status/filestotal", rd_filestotal, 0, 0}, {"status/filesfree", rd_filesfree, 0, 0}, - {"status/filesets", rd_filesets, 0, 0}, + {"status/filegroups", rd_filegroups, 0, 0}, {0} }; int rd_numrefs(char* page, char **start, off_t off, int count, int *eof, diff --git a/lustre/obdfilter/lproc_obdfilter.c b/lustre/obdfilter/lproc_obdfilter.c index 48c5382..e680784 100644 --- a/lustre/obdfilter/lproc_obdfilter.c +++ b/lustre/obdfilter/lproc_obdfilter.c @@ -92,8 +92,8 @@ int rd_fstype(char* page, char **start, off_t off, int count, int *eof, len += snprintf(page, count, "%s\n", temp->u.filter.fo_fstype); return len; } -int rd_files(char* page, char **start, off_t off, int count, int *eof, - void *data) +int rd_filestotal(char* page, char **start, off_t off, int count, int *eof, + void *data) { struct obd_device* temp = (struct obd_device*)data; struct statfs mystats; @@ -114,13 +114,19 @@ int rd_filesfree(char* page, char **start, off_t off, int count, int *eof, return len; } +int rd_filegroups(char* page, char **start, off_t off, int count, int *eof, + void *data) +{ + return 0; +} struct lprocfs_vars status_var_nm_1[] = { {"status/uuid", rd_uuid, 0, 0}, {"status/blocksize",rd_blksize, 0, 0}, {"status/kbytestotal",rd_kbtotal, 0, 0}, {"status/kbytesfree", rd_kbfree, 0, 0}, - {"status/files", rd_files, 0, 0}, + {"status/filestotal", rd_filestotal, 0, 0}, {"status/filesfree", rd_filesfree, 0, 0}, + {"status/filegroups", rd_filegroups, 0, 0}, {"status/fstype", rd_fstype, 0, 0}, {0} }; diff --git a/lustre/osc/lproc_osc.c b/lustre/osc/lproc_osc.c index 229be02..58e9097 100644 --- a/lustre/osc/lproc_osc.c +++ b/lustre/osc/lproc_osc.c @@ -38,38 +38,32 @@ int rd_blksize(char* page, char **start, off_t off, int count, int *eof, { return 0; } -int rd_blktotal(char* page, char **start, off_t off, int count, int *eof, - void *data) -{ - return 0; -} - -int rd_blkfree(char* page, char **start, off_t off, int count, int *eof, - void *data) +int rd_kbytestotal(char* page, char **start, off_t off, int count, int *eof, + void *data) { return 0; } -int rd_kbfree(char* page, char **start, off_t off, int count, int *eof, - void *data) +int rd_kbytesfree(char* page, char **start, off_t off, int count, int *eof, + void *data) { return 0; } -int rd_numobjects(char* page, char **start, off_t off, int count, int *eof, +int rd_filestotal(char* page, char **start, off_t off, int count, int *eof, void *data) { return 0; } -int rd_objfree(char* page, char **start, off_t off, int count, int *eof, - void *data) +int rd_filesfree(char* page, char **start, off_t off, int count, int *eof, + void *data) { return 0; } -int rd_objgroups(char* page, char **start, off_t off, int count, int *eof, - void *data) +int rd_filegroups(char* page, char **start, off_t off, int count, int *eof, + void *data) { return 0; } @@ -100,13 +94,12 @@ int rd_conn_uuid(char* page, char **start, off_t off, int count, int *eof, struct lprocfs_vars status_var_nm_1[] = { {"status/uuid", rd_uuid, 0, 0}, - {"status/f_blocksize",rd_blksize, 0, 0}, - {"status/f_blockstotal",rd_blktotal, 0, 0}, - {"status/f_blocksfree",rd_blkfree, 0, 0}, - {"status/f_kbytesfree", rd_kbfree, 0, 0}, - {"status/f_objects", rd_numobjects, 0, 0}, - {"status/f_objectsfree", rd_objfree, 0, 0}, - {"status/f_objectgroups", rd_objgroups, 0, 0}, + {"status/blocksize",rd_blksize, 0, 0}, + {"status/kbytestotal", rd_kbytestotal, 0, 0}, + {"status/kbytesfree", rd_kbytesfree, 0, 0}, + {"status/filestotal", rd_filestotal, 0, 0}, + {"status/filesfree", rd_filesfree, 0, 0}, + {"status/filegroups", rd_filegroups, 0, 0}, {"status/ost_server_uuid", rd_server_uuid, 0, 0}, {"status/ost_conn_uuid", rd_conn_uuid, 0, 0}, {0} diff --git a/lustre/ost/lproc_ost.c b/lustre/ost/lproc_ost.c index e919104..1fa1c59 100644 --- a/lustre/ost/lproc_ost.c +++ b/lustre/ost/lproc_ost.c @@ -98,8 +98,8 @@ int rd_kbfree(char* page, char **start, off_t off, int count, int *eof, return len; } -int rd_files(char* page, char **start, off_t off, int count, int *eof, - void *data) +int rd_filestotal(char* page, char **start, off_t off, int count, int *eof, + void *data) { struct obd_device* temp = (struct obd_device*)data; struct ost_obd *ost = &temp->u.ost; @@ -129,8 +129,8 @@ int rd_filesfree(char* page, char **start, off_t off, int count, int *eof, } -int rd_objgroups(char* page, char **start, off_t off, int count, int *eof, - void *data) +int rd_filegroups(char* page, char **start, off_t off, int count, int *eof, + void *data) { return 0; } @@ -140,9 +140,9 @@ struct lprocfs_vars status_var_nm_1[] = { {"status/blocksize",rd_blksize, 0, 0}, {"status/kbytesfree", rd_kbfree, 0, 0}, {"status/kbytestotal", rd_kbtotal, 0, 0}, - {"status/files", rd_files, 0, 0}, + {"status/filestotal", rd_filestotal, 0, 0}, {"status/filesfree", rd_filesfree, 0, 0}, - {"status/objectgroups", rd_objgroups, 0, 0}, + {"status/filegroups", rd_filegroups, 0, 0}, {0} }; -- 1.8.3.1