1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-03 13:47:25 +03:00
samba-mirror/ctdb/tests/takeover/mgmt_simple.py
Martin Schwenke 0fdd7566c7 Testing: IP allocation simulation - update options processing in examples.
Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit a65ca1a71386f40080dd553756f3600d3b20d523)
2010-08-02 15:01:47 +10:00

23 lines
448 B
Python
Executable File

#!/usr/bin/env python
# This is an example showing a current SONAS configuration with 3
# interface node and a management node. When run with deterministic
# IPs there are gratuitous IP reassignments.
from ctdb_takeover import Cluster, Node, process_args
process_args()
addresses = ['A', 'B', 'C', 'D', 'E', 'F', 'G']
c = Cluster()
for i in range(3):
c.add_node(Node(addresses))
c.add_node(Node([]))
c.recover()
c.random_iterations()