ctdb: add test script for ctdb_mutex_ceph_rados_helper
authorDavid Disseldorp <ddiss@samba.org>
Tue, 6 Dec 2016 12:03:27 +0000 (13:03 +0100)
committerAmitay Isaacs <amitay@samba.org>
Fri, 9 Dec 2016 06:59:33 +0000 (07:59 +0100)
commitf5536ce1f6ab4e0764e4e806fb0fca5c43051f86
treedc3adbba1366295ef157230302661c85fa37faaa
parent8aba284fc493815592de77847c6a990866a7afce
ctdb: add test script for ctdb_mutex_ceph_rados_helper

This standalone test script performs the following:
- using ctdb_mutex_ceph_rados_helper, take a lock on the Ceph RADOS
  object a CLUSTER/$POOL/$OBJECT using the Ceph keyring for $USER
  + confirm that lock is obtained, via ctdb_mutex_ceph_rados_helper "0"
    output
- check RADOS object lock state, using the "rados lock info" command
- attempt to obtain the lock again, using ctdb_mutex_ceph_rados_helper
  + confirm that the lock is not successfully taken
- tell the first locker to drop the lock and exit, via SIGTERM
- once the first locker has exited, attempt to get the lock again
  + confirm that this attempt succeeds

Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Autobuild-User(master): Amitay Isaacs <amitay@samba.org>
Autobuild-Date(master): Fri Dec  9 07:59:33 CET 2016 on sn-devel-144
ctdb/utils/ceph/test_ceph_rados_reclock.sh [new file with mode: 0755]