Implemented net fsmo command for transferring fsmo roles
commit45662e6582fab68c56d471f321aa72063b763ef9
authorNadezhda Ivanova <nadezhda.ivanova@postpath.com>
Wed, 27 Jan 2010 15:57:37 +0000 (27 17:57 +0200)
committerFernando J V da Silva <fernandojvsilva@yahoo.com.br>
Thu, 4 Feb 2010 19:09:47 +0000 (4 17:09 -0200)
treeca00e4628fa9fa97342875febcac35e77ce15feb
parent93df93be85b43f36a38c267cdebe5fd762e61aeb
Implemented net fsmo command for transferring fsmo roles

The command allows the user to transfer a fsmo role to the server to which
the connection is established. Roles can be transferred or seized. By default a
transfer is attempted even if seize option is chosen, as it is dangerous to
seize a role if the current owner is still running.
example use:
net fsmo show --host=hostnameoraddress --username=username --password=password
net fsmo transfer --role=role --host=hostnameoraddress --username=username --password=password
net fsmo seize --role=role --host=hostnameoraddress --username=username --password=password [--force]

Tested against Win2008. Does not work for samba 4 yet as we are missing the GetNCChanges extensions.
source4/scripting/python/samba/netcmd/__init__.py
source4/scripting/python/samba/netcmd/fsmo.py [new file with mode: 0644]