diff options
author | Scot W. Stevenson <[email protected]> | 2017-11-07 23:50:15 +0100 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2017-11-07 14:50:15 -0800 |
commit | 681957fe2efc6a15b9675387075514957cbcd821 (patch) | |
tree | 45f2da825f3bc94e07bf18f98deead1d907df195 | |
parent | 12954494a1bfe4c115332049cca1704d865f72d0 (diff) |
Sort output of tunables in arc_summary.py
Sort list of tunables printed by _tunable_summary()
alphabetically
Reviewed-by: Brian Behlendorf <[email protected]>
Reviewed-by: Giuseppe Di Natale <[email protected]>
Signed-off-by: Scot W. Stevenson <[email protected]>
Closes #6828
-rwxr-xr-x | cmd/arc_summary/arc_summary.py | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/cmd/arc_summary/arc_summary.py b/cmd/arc_summary/arc_summary.py index f4968fb6a..4c513d63d 100755 --- a/cmd/arc_summary/arc_summary.py +++ b/cmd/arc_summary/arc_summary.py @@ -900,14 +900,18 @@ def _tunable_summary(Kstat): sys.stderr.write("Tunable descriptions will be disabled.\n") sys.stdout.write("ZFS Tunable:\n") + names.sort() + + if alternate_tunable_layout: + format = "\t%s=%s\n" + else: + format = "\t%-50s%s\n" + for name in names: + if not name: continue - format = "\t%-50s%s\n" - if alternate_tunable_layout: - format = "\t%s=%s\n" - if show_tunable_descriptions and name in descriptions: sys.stdout.write("\t# %s\n" % descriptions[name]) |