提交 882191d6 编写于 作者: N Narasimhan V

multipath: Replaced the sleep with wait_for

We were sleeping instead of waiting for the service to become
stable, after a service restart. So, replaced the sleep with
wait_for.
Signed-off-by: NNarasimhan V <sim@linux.vnet.ibm.com>
上级 6e2ce2a1
......@@ -58,8 +58,9 @@ def form_conf_mpath_file(blacklist="", defaults_extra=""):
# The reason for sleep here is to give some time for change in
# multipath.conf file to take effect.
time.sleep(5)
service.SpecificServiceManager(get_svc_name()).restart()
time.sleep(4)
mpath_svc = service.SpecificServiceManager(get_svc_name())
mpath_svc.restart()
wait.wait_for(mpath_svc.status, timeout=10)
def device_exists(path):
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册