Solved

Powershell code to view the FSMO role and AD Sites across the Active Directory domain

Posted on 2014-10-22
7
216 Views
Last Modified: 2014-10-23
People,

Can anyone here please assist me with the PowerShell code that I can execute to get the AD Sites name and FSMO role for all of the Domain Controller/Global Catalog in my AD Domain ?

My AD Domain functionality is still Windows Server 2003 with some AD/DC is still running on WIndows Server 2003 physical box to be decommissioned.

Thanks,
0
Comment
  • 4
  • 2
7 Comments
 
LVL 27

Accepted Solution

by:
Dan McFadden earned 500 total points
ID: 40396740
Using NETDOM from command line:

netdom query /domain:YourDomainGoes.Here fsmo

Using Powershell (its 2 separate commands):

1. Get-ADForest YourDomainGoes.Here | ft SchemaMaster, DomainNamingMaster
2. Get-ADDomain YourDomainGoes.Here | ft PDCEmulator ,RIDMaster, InfrastructureMaster

Dan
0
 
LVL 19

Expert Comment

by:Kash
ID: 40396743
0
 
LVL 7

Author Comment

by:Senior IT System Engineer
ID: 40396755
ok, as for the NetDom, do I have to run that on the Domain Controllers or it can run on my WIndows 7 laptop ?
0
Does Powershell have you tied up in knots?

Managing Active Directory does not always have to be complicated.  If you are spending more time trying instead of doing, then it's time to look at something else. For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why

 
LVL 27

Expert Comment

by:Dan McFadden
ID: 40396767
You can run it from your laptop in you have RSAT (AD remote administrator tools) installed.
0
 
LVL 27

Expert Comment

by:Dan McFadden
ID: 40396768
0
 
LVL 27

Expert Comment

by:Dan McFadden
ID: 40396777
RSAT is Remote Server Administrator Tools... made a mistake in the name in my above post.
0
 
LVL 7

Author Closing Comment

by:Senior IT System Engineer
ID: 40400661
Thanks !
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article will help you understand what HashTables are and how to use them in PowerShell.
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
Windows 8 comes with a dramatically different user interface known as Metro. Notably missing from the new interface is a Start button and Start Menu. Many users do not like it, much preferring the interface of earlier versions — Windows 7, Windows X…
The viewer will learn how to successfully create a multiboot device using the SARDU utility on Windows 7. Start the SARDU utility: Change the image directory to wherever you store your ISOs, this will prevent you from having 2 copies of an ISO wit…

815 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now