I would like to know if it is possible to determine if Active Directory Domain Services is running on a host by looking at certain registry keys. I'm also trying to do the same for Active Directory Lightweight Directory Service.
So far research has lead me to look for HKEY_LOCAL_MACHINE\^SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\ADAM_.*$
to see if AD LDS is installed, however I would like to know if the service is currently running, or alternatively, if this is possible to achieve.
I believe you can check if the service is running on the server/machine via powershell
get-service NTDS
(Active Directory Domain Services) get the status or if it exist. Also
get-service ADWS
to get the status of the ADDS ans AD LDS.
Status Name DisplayName
------ ---- -----------
Running ADWS Active Directory Web Services
Please write what you want to achieve and how you want to run this. How you want to be notified if the service is not running. If you need a csv or a txt import with the server names (list).
Please provide more information or use this command it fits your needs.