reorg disk metrics for use with raw device

This commit is contained in:
Doug MacEachern 2007-10-10 03:14:01 +00:00
parent a7eb05fd63
commit 5e47762150
1 changed files with 23 additions and 15 deletions

View File

@ -432,25 +432,33 @@ SIGAR_DECLARE(int)
sigar_file_system_list_destroy(sigar_t *sigar, sigar_file_system_list_destroy(sigar_t *sigar,
sigar_file_system_list_t *fslist); sigar_file_system_list_t *fslist);
#define SIGAR_DISK_USAGE_T \
sigar_uint64_t disk_reads; \
sigar_uint64_t disk_writes; \
sigar_uint64_t disk_write_bytes; \
sigar_uint64_t disk_read_bytes; \
sigar_uint64_t disk_queue; \
sigar_uint64_t disk_rtime; \
sigar_uint64_t disk_wtime; \
sigar_uint64_t disk_time
typedef struct { typedef struct {
SIGAR_DISK_USAGE_T;
} sigar_disk_usage_t;
typedef struct {
SIGAR_DISK_USAGE_T;
double use_percent; double use_percent;
sigar_uint64_t sigar_uint64_t total;
total, sigar_uint64_t free;
free, sigar_uint64_t used;
used, sigar_uint64_t avail;
avail, sigar_uint64_t files;
files, sigar_uint64_t free_files;
free_files,
disk_reads,
disk_writes,
disk_write_bytes,
disk_read_bytes,
disk_queue,
disk_rtime,
disk_wtime,
disk_time;
} sigar_file_system_usage_t; } sigar_file_system_usage_t;
#undef SIGAR_DISK_USAGE_T
SIGAR_DECLARE(int) SIGAR_DECLARE(int)
sigar_file_system_usage_get(sigar_t *sigar, sigar_file_system_usage_get(sigar_t *sigar,
const char *dirname, const char *dirname,