Skip to content
Snippets Groups Projects
Commit c6093aed authored by Moe Jette's avatar Moe Jette
Browse files

Check KillWait time for reasonable value for effective test.

parent 69ad698b
No related branches found
No related tags found
No related merge requests found
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
# Note: This script generates and then deletes files in the working directory # Note: This script generates and then deletes files in the working directory
# named test1.7.input, test1.7.output, and test1.7.error # named test1.7.input, test1.7.output, and test1.7.error
############################################################################ ############################################################################
# Copyright (C) 2002-6 The Regents of the University of California. # Copyright (C) 2002-2006 The Regents of the University of California.
# Produced at Lawrence Livermore National Laboratory (cf, DISCLAIMER). # Produced at Lawrence Livermore National Laboratory (cf, DISCLAIMER).
# Written by Morris Jette <jette1@llnl.gov> # Written by Morris Jette <jette1@llnl.gov>
# UCRL-CODE-217948. # UCRL-CODE-217948.
...@@ -49,6 +49,7 @@ print_header $test_id ...@@ -49,6 +49,7 @@ print_header $test_id
# #
# Make sure sleep time is no larger than InactiveLimit # Make sure sleep time is no larger than InactiveLimit
set inactive_limit $sleep_time set inactive_limit $sleep_time
set kill_wait $sleep_time
log_user 0 log_user 0
spawn $scontrol show config spawn $scontrol show config
expect { expect {
...@@ -56,6 +57,10 @@ expect { ...@@ -56,6 +57,10 @@ expect {
set inactive_limit $expect_out(1,string) set inactive_limit $expect_out(1,string)
exp_continue exp_continue
} }
-re "KillWait.*= ($number)" {
set kill_wait $expect_out(1,string)
exp_continue
}
timeout { timeout {
send_user "\nFAILURE: scontrol not responding\n" send_user "\nFAILURE: scontrol not responding\n"
set exit_code 1 set exit_code 1
...@@ -72,6 +77,10 @@ if {$inactive_limit < 120} { ...@@ -72,6 +77,10 @@ if {$inactive_limit < 120} {
send_user "\nWARNING: Inactive limit is too low for this test\n" send_user "\nWARNING: Inactive limit is too low for this test\n"
exit 0 exit 0
} }
if {$kill_wait > 60} {
send_user "\nWARNING: KillWait configured too high for this test\n"
exit 0
}
if {$inactive_limit < $sleep_time} { if {$inactive_limit < $sleep_time} {
set sleep_time $inactive_limit set sleep_time $inactive_limit
send_user "\nReset job sleep time to $sleep_time seconds\n" send_user "\nReset job sleep time to $sleep_time seconds\n"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment