Advisor 기술 자료 검색

Microsoft.SystemCenter.Advisor.AgentHealth.KnowledgeDiscoveryMonitor (UnitMonitor)

Knowledge Base article:

요약

특정 에이전트에서 Advisor 기술 자료 검색을 실행하지 못했습니다.

원인

관리 팩이 손상되거나 잘못되었습니다.

해결 방법

해당 에이전트를 처음으로 옵트인한 경우 이는 정상적인 상황이므로 몇 분 정도 기다려 주십시오. 그렇지 않으면 특정 에이전트에서 %Program Files%\System Center Operations Manager\ 아래의 상태 서비스 상태 폴더를 삭제하고 상태 서비스를 다시 시작하여 최신 관리 팩을 강제로 다운로드합니다.

Element properties:

TargetMicrosoft.SystemCenter.Advisor.Internal.AdvisorConnector
Parent MonitorSystem.Health.AvailabilityState
CategoryAvailabilityHealth
EnabledTrue
Alert GenerateTrue
Alert SeverityError
Alert PriorityNormal
Alert Auto ResolveTrue
Monitor TypeMicrosoft.Windows.TimedScript.ThreeStateMonitorType
RemotableTrue
AccessibilityPublic
Alert Message
서버에서 Advisor 기술 자료 검색 실패
Advisor 관리 팩이 잘못되었습니다.
RunAsSystem.PrivilegedMonitoringAccount

Source Code:

<UnitMonitor ID="Microsoft.SystemCenter.Advisor.AgentHealth.KnowledgeDiscoveryMonitor" Accessibility="Public" Enabled="true" Target="Microsoft.SystemCenter.Advisor.Internal.AdvisorConnector" ParentMonitorID="Health!System.Health.AvailabilityState" Remotable="true" Priority="Normal" TypeID="Windows!Microsoft.Windows.TimedScript.ThreeStateMonitorType" RunAs="System!System.PrivilegedMonitoringAccount" ConfirmDelivery="false">
<Category>AvailabilityHealth</Category>
<AlertSettings AlertMessage="Microsoft.SystemCenter.Advisor.AgentHealth.KnowledgeDiscoveryMonitor.AlertMessage">
<AlertOnState>Error</AlertOnState>
<AutoResolve>true</AutoResolve>
<AlertPriority>Normal</AlertPriority>
<AlertSeverity>Error</AlertSeverity>
</AlertSettings>
<OperationalStates>
<OperationalState ID="Warning" MonitorTypeStateID="Warning" HealthState="Warning"/>
<OperationalState ID="Success" MonitorTypeStateID="Success" HealthState="Success"/>
<OperationalState ID="Error" MonitorTypeStateID="Error" HealthState="Error"/>
</OperationalStates>
<Configuration>
<IntervalSeconds>60</IntervalSeconds>
<SyncTime/>
<ScriptName>MonitorKnowledgeDiscovery.vbs</ScriptName>
<Arguments/>
<ScriptBody><Script>
function readFromRegistry(strRegistryKey, strDefault)
Dim WSHShell, value

On Error Resume Next
Set WSHShell = CreateObject("WScript.Shell")
value = WSHShell.RegRead(strRegistryKey)

if err.number &lt;&gt; 0 then
readFromRegistry=strDefault
else
readFromRegistry=value
end if

set WSHShell = nothing
end function

Dim oAPI, oBag, strStatePath, strMonitorState
Set oAPI = CreateObject("MOM.ScriptAPI")
Set oBag = oAPI.CreatePropertyBag()

strStatePath = readFromRegistry("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\System Center Operations Manager\12\Advisor\DataRoot", Empty)
strMonitorState = "Warning"

if strStatePath &lt;&gt; Empty then
Dim oFSO, strModelPath, strKnowledgePath, oKnowledgeFolder
Set oFSO = CreateObject("Scripting.FileSystemObject")
strModelPath = strStatePath &amp; "\AdvisorMonitorV2\Configuration\model.xml"
strKnowledgePath = strStatePath &amp; "\AdvisorMonitorV2\Management Packs\Knowledge12"
if oFSO.FileExists(strModelPath) then
strMonitorState = "Success"
elseif oFSO.FolderExists(strKnowledgePath) then
Set oKnowledgeFolder = oFSO.GetFolder(strKnowledgePath)
if oKnowledgeFolder.Files.Count &lt;&gt; 0 then
strMonitorState = "Error"
end if
end if
else
strMonitorState = "Success"
end if

Call oBag.AddValue("Status", strMonitorState)
Call oAPI.Return(oBag)
</Script></ScriptBody>
<TimeoutSeconds>60</TimeoutSeconds>
<ErrorExpression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="String">Property[@Name='Status']</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<Value Type="String">Error</Value>
</ValueExpression>
</SimpleExpression>
</ErrorExpression>
<WarningExpression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="String">Property[@Name='Status']</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<Value Type="String">Warning</Value>
</ValueExpression>
</SimpleExpression>
</WarningExpression>
<SuccessExpression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="String">Property[@Name='Status']</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<Value Type="String">Success</Value>
</ValueExpression>
</SimpleExpression>
</SuccessExpression>
</Configuration>
</UnitMonitor>