diff options
author | lmr <lmr@592f7852-d20e-0410-864c-8624ca9c26a4> | 2011-06-21 04:53:37 +0000 |
---|---|---|
committer | lmr <lmr@592f7852-d20e-0410-864c-8624ca9c26a4> | 2011-06-21 04:53:37 +0000 |
commit | 8dff3f4d0713d2688505cf72957fa1913053bd83 (patch) | |
tree | 455e52192160e349a42ef2cac060300c83ec5ff9 | |
parent | 48d15a688996f69a6e1736421efecba63364960a (diff) |
server/crashcollect.py: Add control for crash collection timeout to global_config
The four hour timeout for crash collection is way too long for Chrome
OS, so we moved this parameter into global config for easier control.
Signed-off-by: Dale Curtis <dalecurtis@google.com>
git-svn-id: svn://test.kernel.org/autotest/trunk@5433 592f7852-d20e-0410-864c-8624ca9c26a4
-rw-r--r-- | server/crashcollect.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/server/crashcollect.py b/server/crashcollect.py index 6e1de7fd..dc582ac8 100644 --- a/server/crashcollect.py +++ b/server/crashcollect.py @@ -1,5 +1,6 @@ import os, time, pickle, logging, shutil +from autotest_lib.client.common_lib import global_config from autotest_lib.server import utils @@ -33,7 +34,12 @@ def get_crashinfo(host, test_start_time): collect_uncollected_logs(host) -def wait_for_machine_to_recover(host, hours_to_wait=4.0): +# Load default for number of hours to wait before giving up on crash collection. +HOURS_TO_WAIT = global_config.global_config.get_config_value( + 'SERVER', 'crash_collection_hours_to_wait', type=float, default=4.0) + + +def wait_for_machine_to_recover(host, hours_to_wait=HOURS_TO_WAIT): """Wait for a machine (possibly down) to become accessible again. @param host: A RemoteHost instance to wait on |