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.