Without a timeout on the command, it may hang for a very long time,
hunting for new mons. If it hangs for more than 60 seconds, it is
safe to assume the mon is indeed down.
Fixes: http://tracker.ceph.com/issues/16477
Signed-off-by: Loic Dachary <loic@dachary.org>
# kill the mon and verify it cannot be reached
#
kill_daemon $pidfile TERM || return 1
- ! ceph --connect-timeout 60 status || return 1
+ ! timeout 60 ceph --connect-timeout 60 status || return 1
done
teardown $dir || return 1
# kill the mon and verify it cannot be reached
#
kill_daemons $dir TERM || return 1
- ! ceph --connect-timeout 60 status || return 1
+ ! timeout 60 ceph --connect-timeout 60 status || return 1
teardown $dir || return 1
}