aboutsummaryrefslogtreecommitdiffstats
path: root/tools/xenmon
diff options
context:
space:
mode:
Diffstat (limited to 'tools/xenmon')
-rw-r--r--tools/xenmon/xenmon.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/tools/xenmon/xenmon.py b/tools/xenmon/xenmon.py
index 402b6b4e18..e6b8ce9e24 100644
--- a/tools/xenmon/xenmon.py
+++ b/tools/xenmon/xenmon.py
@@ -675,6 +675,11 @@ def main():
if options.mspersample < 0:
parser.error("option --ms_per_sample: invalid negative value: '%d'" %
options.mspersample)
+ # If --ms_per_sample= is too large, no data may be logged.
+ if not options.live and options.duration != 0 and \
+ options.mspersample > options.duration * 1000:
+ parser.error("option --ms_per_sample: too large (> %d ms)" %
+ (options.duration * 1000))
start_xenbaked()
if options.live: