Commit 21086aa1 authored by Klaus Aehlig's avatar Klaus Aehlig

Make disk verification optional

In some setups, verification of disks can take a long
time, whereas it is still desirable to run the other
watcher operations more regularly. Hence support this
use case by providing an option to not run disk verification,
allowing for more elaborate cron schedules. Fixes issue 1090.
Signed-off-by: default avatarKlaus Aehlig <>
Reviewed-by: default avatarPetr Pudlak <>
parent 167766dc
......@@ -474,6 +474,8 @@ def ParseOptions():
parser.add_option("--no-wait-children", dest="wait_children",
help="Don't wait for child processes")
parser.add_option("--no-verify-disks", dest="no_verify_disks", default=False,
action="store_true", help="Do not verify disk status")
# See optparse documentation for why default values are not set by options
options, args = parser.parse_args()
......@@ -860,7 +862,8 @@ def _GroupWatcher(opts):
started = _CheckInstances(client, notepad, instances, locks)
_CheckDisks(client, notepad, nodes, instances, started)
_VerifyDisks(client, group_uuid, nodes, instances)
if not opts.no_verify_disks:
_VerifyDisks(client, group_uuid, nodes, instances)
except Exception, err:"Not updating status file due to failure: %s", err)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment