summaryrefslogtreecommitdiffstats
path: root/cmd/arcstat
diff options
context:
space:
mode:
authorFabian-Gruenbichler <[email protected]>2017-10-26 21:18:49 +0200
committerBrian Behlendorf <[email protected]>2017-10-26 12:18:49 -0700
commit3ad59c015dce45965fa309a0364a46c6f8bdda9f (patch)
tree1c20fd63d990861e40d041e40884c96dbffd1477 /cmd/arcstat
parent69b229bd60135838d606f5da41831d409d11de2d (diff)
arcstat: flush stdout / outfile after each line
Otherwise, if arcstat gets interrupted before the desired number of iterations is reached, the output file will be empty (both if set via '-o' or via shell redirection). Reviewed-by: George Melikov <[email protected]> Reviewed-by: Brian Behlendorf <[email protected]> Reviewed-by: Giuseppe Di Natale <[email protected]> Signed-off-by: Fabian Grünbichler <[email protected]> Closes #6775
Diffstat (limited to 'cmd/arcstat')
-rwxr-xr-xcmd/arcstat/arcstat.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/cmd/arcstat/arcstat.py b/cmd/arcstat/arcstat.py
index d969da8d4..aa54ee87a 100755
--- a/cmd/arcstat/arcstat.py
+++ b/cmd/arcstat/arcstat.py
@@ -219,6 +219,7 @@ def print_values():
sep
))
sys.stdout.write("\n")
+ sys.stdout.flush()
def print_header():