DFS Namespaces Role Service Discovery (Windows Server 2016 and above)

Microsoft.Windows.FileServer.DFSN.10.0.RoleServiceDiscovery (Discovery)

This rule discovers all servers running Windows Server 2016 and above that have the DFS Namespaces role service installed.

Knowledge Base article:

Summary

This rule discovers all servers running Windows Server 2016 and above that have the DFS Namespaces role service installed. To discover the servers, this object checks the following registry location: SYSTEM\CurrentControlSet\Services\Dfs\Start

Element properties:

TargetMicrosoft.Windows.Server.10.0.Computer
EnabledTrue
Frequency43200
RemotableFalse

Object Discovery Details:

Discovered Classes and their attribuets:

Member Modules:

ID Module Type TypeId RunAs 
DS DataSource Microsoft.Windows.FilteredRegistryDiscoveryProvider Microsoft.Windows.FileServer.DFSN.NamespaceDiscoveryAccount

Source Code:

<Discovery ID="Microsoft.Windows.FileServer.DFSN.10.0.RoleServiceDiscovery" Enabled="true" Target="WS2016Disc!Microsoft.Windows.Server.10.0.Computer" ConfirmDelivery="false" Remotable="true" Priority="Normal">
<Category>Discovery</Category>
<DiscoveryTypes>
<DiscoveryClass TypeID="Microsoft.Windows.FileServer.DFSN.10.0.RoleService">
<Property TypeID="System!System.Entity" PropertyID="DisplayName"/>
</DiscoveryClass>
</DiscoveryTypes>
<DataSource ID="DS" RunAs="DFSNLib!Microsoft.Windows.FileServer.DFSN.NamespaceDiscoveryAccount" TypeID="Windows!Microsoft.Windows.FilteredRegistryDiscoveryProvider">
<ComputerName>$Target/Property[Type="Windows!Microsoft.Windows.Computer"]/NetworkName$</ComputerName>
<RegistryAttributeDefinitions>
<RegistryAttributeDefinition>
<AttributeName>DFS</AttributeName>
<Path>SYSTEM\CurrentControlSet\Services\Dfs\Start</Path>
<PathType>1</PathType>
<AttributeType>2</AttributeType>
</RegistryAttributeDefinition>
</RegistryAttributeDefinitions>
<Frequency>43200</Frequency>
<ClassId>$MPElement[Name="Microsoft.Windows.FileServer.DFSN.10.0.RoleService"]$</ClassId>
<InstanceSettings>
<Settings>
<Setting>
<Name>$MPElement[Name="Windows!Microsoft.Windows.Computer"]/PrincipalName$</Name>
<Value>$Target/Property[Type="Windows!Microsoft.Windows.Computer"]/PrincipalName$</Value>
</Setting>
<Setting>
<Name>$MPElement[Name="DFSNLib!Microsoft.Windows.FileServer.DFSN.RoleService"]/IsOnVirtualNode$</Name>
<Value>$Target/Property[Type="Windows!Microsoft.Windows.Server.Computer"]/IsVirtualNode$</Value>
</Setting>
<Setting>
<Name>$MPElement[Name="System!System.Entity"]/DisplayName$</Name>
<Value>$Target/Property[Type="Windows!Microsoft.Windows.Computer"]/NetbiosComputerName$</Value>
</Setting>
</Settings>
</InstanceSettings>
<Expression>
<And>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="String">Values/DFS</XPathQuery>
</ValueExpression>
<Operator>GreaterEqual</Operator>
<ValueExpression>
<Value Type="String">0</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="String">Values/DFS</XPathQuery>
</ValueExpression>
<Operator>LessEqual</Operator>
<ValueExpression>
<Value Type="String">3</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
</And>
</Expression>
</DataSource>
</Discovery>