Application Integration Discovery

Microsoft.HostIntegrationServer.2010.AppIntDiscovery (Discovery)

Discovery for the Application Integration features

Knowledge Base article:

Summary

The Application Integration discovery checks the following registry locations to verify that the feature is configured:

HKLM\SOFTWARE\Microsoft\Host Integration Server\ConfigFramework\ConfiguredFeatures\COMTI

HKLM\SOFTWARE\Microsoft\Host Integration Server\ConfigFramework\ConfiguredFeatures\SESSION_INTEGRATOR

If either of these locations are found, the Host Integration Server 2010 Management Pack creates an instance of the AppInt class.

Element properties:

TargetMicrosoft.HostIntegrationServer.2010.HISInstallations
EnabledTrue
Frequency43260
RemotableFalse

Object Discovery Details:

Discovered Classes and their attribuets:

Member Modules:

ID Module Type TypeId RunAs 
DS DataSource Microsoft.Windows.TimedScript.DiscoveryProvider Default

Source Code:

<Discovery ID="Microsoft.HostIntegrationServer.2010.AppIntDiscovery" Enabled="true" Target="Microsoft.HostIntegrationServer.2010.HISInstallations" ConfirmDelivery="false" Remotable="true" Priority="Normal">
<Category>Discovery</Category>
<DiscoveryTypes>
<DiscoveryClass TypeID="Microsoft.HostIntegrationServer.2010.AppInt">
<Property TypeID="System!System.Entity" PropertyID="DisplayName"/>
</DiscoveryClass>
</DiscoveryTypes>
<DataSource ID="DS" TypeID="Windows!Microsoft.Windows.TimedScript.DiscoveryProvider">
<IntervalSeconds>43260</IntervalSeconds>
<SyncTime/>
<ScriptName>HIS2010 AppInt Discovery.vbs</ScriptName>
<Arguments>$MPElement$ $Target/Id$ $Target/Host/Property[Type="Windows!Microsoft.Windows.Computer"]/PrincipalName$</Arguments>
<ScriptBody><Script>
'--------------------------------------------------------------------------------------------------
' &lt;name&gt;HIS2010 AppInt Discovery.vbs&lt;/name&gt;
' &lt;company&gt;Microsoft Corporation&lt;/company&gt;
' &lt;copyright&gt;Copyright (c) Microsoft Corporation 2010&lt;/copyright&gt;
' &lt;summary&gt;
' Microsoft Host Integration Server 2010 AppInt discovery script for use with SCOM 2007.
' Provides discovery functions for Host Integration Server 2010.
' &lt;/summary&gt;
'
' See Management Pack Guide for details on parameters and usage
'--------------------------------------------------------------------------------------------------

SetLocale("en-us")
Dim oAPI, oDiscoveryData, oInst
Set oAPI = CreateObject("MOM.ScriptAPI")

Dim oArgs
Set oArgs = WScript.Arguments
if oArgs.Count &lt; 3 Then
Wscript.Quit -1
End If

Dim SourceID, ManagedEntityId, TargetComputer

SourceId = oArgs(0)
ManagedEntityId = oArgs(1)
TargetComputer = oArgs(2)

set oDiscoveryData = oAPI.CreateDiscoveryData(0, SourceId, ManagedEntityId)

Dim strNetbiosName
strNetbiosName = "$Target/Host/Property[Type='Windows!Microsoft.Windows.Computer']/NetbiosComputerName$"

If IsAppIntConfigured OR IsSessionIntConfigured = True then

set oInst = oDiscoveryData.CreateClassInstance("$MPElement[Name='Microsoft.HostIntegrationServer.2010.AppInt']$")
Call oInst.AddProperty("$MPElement[Name='Windows!Microsoft.Windows.Computer']/PrincipalName$", TargetComputer)
call oInst.AddProperty("$MPElement[Name='System!System.Entity']/DisplayName$", "Application Integration")
call oDiscoveryData.AddInstance(oInst)

End If

call oAPI.Return(oDiscoveryData)

Function IsAppIntConfigured()

CONST WMI_REG_HKLM = &amp;H80000002
CONST HIS_KEYPATH = "SOFTWARE\Microsoft\Host Integration Server\ConfigFramework\ConfiguredFeatures"
CONST HIS_KEY = "COMTI"

Dim oRegProvider
Dim intReturn, strVersion

set oRegProvider=GetObject("winmgmts:\\" &amp; TargetComputer &amp; "\root\default:StdRegProv")

intReturn = oRegProvider.GetStringValue (WMI_REG_HKLM, HIS_KEYPATH, HIS_KEY, strVersion)

if intReturn = 0 then
IsAppIntConfigured = True
Else
IsAppIntConfigured = False
end if

End Function 'IsAppIntConfigured


Function IsSessionIntConfigured()

CONST WMI_REG_HKLM = &amp;H80000002
CONST HIS_KEYPATH = "SOFTWARE\Microsoft\Host Integration Server\ConfigFramework\ConfiguredFeatures"
CONST HIS_KEY = "SESSION_INTEGRATOR"

Dim oRegProvider
Dim intReturn, strVersion

set oRegProvider=GetObject("winmgmts:\\" &amp; TargetComputer &amp; "\root\default:StdRegProv")

intReturn = oRegProvider.GetStringValue (WMI_REG_HKLM, HIS_KEYPATH, HIS_KEY, strVersion)

if intReturn = 0 then
IsSessionIntConfigured = True
Else
IsSessionIntConfigured = False
end if

End Function 'IsSessionIntConfigured
</Script></ScriptBody>
<TimeoutSeconds>360</TimeoutSeconds>
</DataSource>
</Discovery>