Active Directory, List FSMO Roles of a Domain Controller (DC) using NtdsUtil.exe
To list the FSMO (Flexible Single Master Operations) Roles of a Microsoft Active Directory Domain Controller (DC) using NtdsUtil.exe:
Start a command prompt (cmd.exe)
Start NtdsUtil.exe
C:\>NtdsUtil.exe
Switch to Roles context
ntdsutil:Roles
Swtich to Connections context
fsmo maintenance:Connections
Connect to the server
server connections:Connect to server MYDOMAINCONTROLLER
Quit this context
server connections:Quit
Select the so called Operation Targer
fsmo maintenance:Select Operation Target
Now list the Roles for the Server
select operation target:List roles for connected server
that’s it.
To fully automate these steps, you can use this script (just copy paste it in a .bat or .cmd file and execute it with the servername as the first and only parameter)
@echo off
REM
REM Script to dump FSMO role owners on the server designated by %1
REM
if ""=="%1" goto usage
Ntdsutil roles Connections "Connect to server %1" Quit "select Operation Target" "List roles for connected server" Quit Quit Quit
goto done
:usage
@echo Please provide the name of a domain controller (i.e. dumpfsmos MYDC)
@echo.
:done
[…] get a list of all the FSMO Roles for a specific server, read here Categories: Active Directory, Microsoft Tags: Comments (0) Trackbacks (0) Leave a […]