Implemented net fsmo command for transferring fsmo roles
authorNadezhda Ivanova <nadezhda.ivanova@postpath.com>
Wed, 27 Jan 2010 15:57:37 +0000 (17:57 +0200)
committerNadezhda Ivanova <nadezhda.ivanova@postpath.com>
Wed, 27 Jan 2010 15:57:37 +0000 (17:57 +0200)
commitdffb5ad2bf75fc0bcb69dce5cde52c8a1ea9c4f9
tree077a8633b7ac7aa98d08659a25b3b90eca56ee64
parent0e2d1cf9c4067dfce80a21ebf735d7d6a823d55e
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]