diff options
author | Allan Jude <allanjude@FreeBSD.org> | 2017-03-17 00:46:50 +0000 |
---|---|---|
committer | Allan Jude <allanjude@FreeBSD.org> | 2017-03-17 00:46:50 +0000 |
commit | 1dbfa4b5305d35ebfc9e6b9f1d2e8e53a928722b (patch) | |
tree | 5a89c04969fdf260142e883c4243673c974bc67f /contrib/top/top.c | |
parent | 9dbf8c467ec84aa5ec5e61125d111220562b364c (diff) | |
download | src-1dbfa4b5305d35ebfc9e6b9f1d2e8e53a928722b.tar.gz src-1dbfa4b5305d35ebfc9e6b9f1d2e8e53a928722b.zip |
Add ZFS compressed ARC stats to top(1)
Provides:
amount of compressed data
logical size of compressed data (how much it would have taken uncompressed)
compression ratio (logical size : total ARC size)
Overhead (space consumed for compression headers)
Example output:
ARC: 31G Total, 18G MFU, 9067M MRU, 2236K Anon, 615M Header, 2947M Other
25G Compressed, 54G Uncompressed, 1.76:1 Ratio, 2265M Overhead
Reviewed by: jpaetzel, smh, imp, jhb (previous version)
MFC after: 2 week
Relnotes: yes
Sponsored by: ScaleEngine Inc.
Differential Revision: https://reviews.freebsd.org/D9829
Notes
Notes:
svn path=/head/; revision=315435
Diffstat (limited to 'contrib/top/top.c')
-rw-r--r-- | contrib/top/top.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/contrib/top/top.c b/contrib/top/top.c index c74c1d1aa595..cf2f5e7c6f3b 100644 --- a/contrib/top/top.c +++ b/contrib/top/top.c @@ -125,6 +125,7 @@ void (*d_procstates)() = i_procstates; void (*d_cpustates)() = i_cpustates; void (*d_memory)() = i_memory; void (*d_arc)() = i_arc; +void (*d_carc)() = i_carc; void (*d_swap)() = i_swap; void (*d_message)() = i_message; void (*d_header)() = i_header; @@ -658,6 +659,7 @@ restart: /* display memory stats */ (*d_memory)(system_info.memory); (*d_arc)(system_info.arc); + (*d_carc)(system_info.carc); /* display swap stats */ (*d_swap)(system_info.swap); @@ -724,6 +726,7 @@ restart: d_cpustates = u_cpustates; d_memory = u_memory; d_arc = u_arc; + d_carc = u_carc; d_swap = u_swap; d_message = u_message; d_header = u_header; @@ -1190,6 +1193,7 @@ reset_display() d_cpustates = i_cpustates; d_memory = i_memory; d_arc = i_arc; + d_carc = i_carc; d_swap = i_swap; d_message = i_message; d_header = i_header; |