summaryrefslogtreecommitdiff
path: root/ctdb/tests/eventscripts/60.nfs.monitor.122.sh
blob: fc5cea87c75586f76451f44d36a2f97bb2388b6d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#!/bin/sh

. "${TEST_SCRIPTS_DIR}/unit.sh"

define_test "lockd down, 15 iterations, back up after 10"

# This simulates a success the eventscript's automated attempts to
# restart the service.

setup_nfs
rpc_services_down "nlockmgr"

# Iteration 10 should try to restart rpc.lockd.  However, our test
# stub rpc.lockd does nothing, so we have to explicitly flag it as up.

iterate_test 15 "ok_null" \
    10 "rpc_set_service_failure_response 'lockd'" \
    11 "rpc_services_up nlockmgr"