Module: check_mk
Branch: master
Commit: 71b4b78d4fb5939d4db730afb191cd88f479bb96
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=71b4b78d4fb593…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Thu Aug 29 10:55:41 2013 +0200
cmk --snmpwalk: put diagnostic output into stderr
---
modules/check_mk.py | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/modules/check_mk.py b/modules/check_mk.py
index 705c2fc..60634c7 100755
--- a/modules/check_mk.py
+++ b/modules/check_mk.py
@@ -3907,10 +3907,10 @@ def do_snmptranslate(walk):
translated_lines = []
walk_lines = file(path_walk).readlines()
- print("Processing %d lines (%d per dot)" % (len(walk_lines),
entries_per_cycle))
+ sys.stderr.write("Processing %d lines (%d per dot)\n" % (len(walk_lines),
entries_per_cycle))
for i in range(0, len(walk_lines), entries_per_cycle):
- sys.stdout.write(".")
- sys.stdout.flush()
+ sys.stderr.write(".")
+ sys.stderr.flush()
process_lines = walk_lines[i:i+entries_per_cycle]
translated_lines.extend(translate(process_lines))