Service Provider Foundation VMM 웹 끝점 모니터

Microsoft.SystemCenter.SPF.Monitor.VMMEndpointGet (UnitMonitor)

SPF VMM 웹 끝점의 작동 상태를 모니터링합니다.

Knowledge Base article:

요약

SPF 웹 서버에서 VMM 웹 인터페이스의 접근성과 작동성을 모니터링합니다. 이 작업은 클라우드 리소스를 검색할 수 있는 테스트 웹 이터페이스 호출을 주기적으로 만들어 수행됩니다.

구성

이 모니터가 올바르게 작동하려면 VMM 서버에서 클라우드 리소스에 액세스할 수 있는 관리자 권한이 있어야 합니다. VMM 웹 끝점에 대해 지정된 앱 풀 계정과 동일한 권한을 사용하거나 보유한 실행 계정을 만들어 Microsoft Service Provider Foundation VMM 계정이라는 실행 프로필에 추가합니다.

이 모니터에 구성할 수 있는 옵션은 다음과 같습니다.

옵션

정의

기본값

경고 상태

경고를 생성하는 모니터의 성능 상태입니다.

모니터가 위험 성능 상태입니다.

경고 우선 순위

이 모니터에 대해 생성된 경고의 우선 순위입니다.

높음

경고 심각도

이 모니터에 대해 생성된 경고의 우선 순위입니다.

위험

경고 자동 해결

모니터가 정상 상태로 돌아갈 때 경고를 자동으로 해결할지 여부를 지정합니다.

True

사용

모니터를 실행할지 여부를 지정합니다.

True

경고 생성

모니터가 경고 또는 위험 상태로 바뀔 때 경고를 생성할지 여부를 지정합니다.

True

간격

모니터가 실행되는 시간 사이의 간격(초)입니다.

300

원인

이 모니터가 오류 상태인데 다른 연결 모니터는 오류 상태가 아니면 패브릭 구성 오류 또는 권한 오류가 원인일 수 있습니다. 모니터 구성에 대한 자세한 내용은 구성 섹션을 참조하세요.

해결 방법

클라우드 리소스에서 패브릭 구성에 대한 대상 VMM 서버를 확인하고 액세스 권한이 관리자 계정에 부여되어 있는지 확인하세요. 모니터 보안이 올바르게 구성되어 있는지 확인하세요.

Element properties:

TargetMicrosoft.SystemCenter.SPF.SpfServer
Parent MonitorSystem.Health.AvailabilityState
CategoryAvailabilityHealth
EnabledTrue
Alert GenerateTrue
Alert SeverityMatchMonitorHealth
Alert PriorityNormal
Alert Auto ResolveTrue
Monitor TypeMicrosoft.SystemCenter.ServiceProviderFoundation.PowerShellModule.TwoStateMonitorType.PropertyBag
RemotableTrue
AccessibilityPublic
Alert Message
VMM 끝점에 액세스할 수 없음
Service Provider Foundation VMM 웹 끝점에 액세스할 수 없습니다.
RunAsMicrosoft.SystemCenter.SPF.VmmEndpointAccount

Source Code:

<UnitMonitor ID="Microsoft.SystemCenter.SPF.Monitor.VMMEndpointGet" Accessibility="Public" Enabled="true" Target="Microsoft.SystemCenter.SPF.SpfServer" ParentMonitorID="Health!System.Health.AvailabilityState" Remotable="true" Priority="Normal" TypeID="Microsoft.SystemCenter.ServiceProviderFoundation.PowerShellModule.TwoStateMonitorType.PropertyBag" ConfirmDelivery="false" RunAs="Microsoft.SystemCenter.SPF.VmmEndpointAccount">
<Category>AvailabilityHealth</Category>
<AlertSettings AlertMessage="Microsoft.SystemCenter.SPF.Monitor.VMMEndpointGet.AlertMessage">
<AlertOnState>Error</AlertOnState>
<AutoResolve>true</AutoResolve>
<AlertPriority>Normal</AlertPriority>
<AlertSeverity>MatchMonitorHealth</AlertSeverity>
<AlertParameters>
<AlertParameter1>$Data/Context/Property[@Name='StatusCode']$</AlertParameter1>
</AlertParameters>
</AlertSettings>
<OperationalStates>
<OperationalState ID="Error" MonitorTypeStateID="Error" HealthState="Error"/>
<OperationalState ID="Success" MonitorTypeStateID="Success" HealthState="Success"/>
</OperationalStates>
<Configuration>
<IntervalSeconds>300</IntervalSeconds>
<SyncTime/>
<ScriptName>HealthOfSpfServer.ps1</ScriptName>
<ScriptBody><Script>param
(
$PortNumber
)

$oAPI = new-object -comObject "MOM.ScriptAPI"
$propertyBag = $oAPI.CreatePropertyBag()

$errorActionSetting = $ErrorActionPreference

$downVmmServers = ""
$res = $null

try
{
$ErrorActionPreference = "Stop"

[Net.ServicePointManager]::ServerCertificateValidationCallback = {$true}

$req = [System.Net.WebRequest]::Create("https://localhost:$PortNumber/SC2012R2/VMM/Microsoft.Management.OData.svc/Clouds")
$req.UseDefaultCredentials = $true
$res = $req.GetResponse()
$int = [int]$res.StatusCode
if($int -eq 200)
{
$propertyBag.AddValue("Result", "Success")
}
else
{
$propertyBag.AddValue("Result", "Failure")
}

$propertyBag.AddValue("StatusCode", $int)

}
catch
{
$propertyBag.AddValue("Result", "Failure")
$propertyBag.AddValue("StatusCode", $_.Exception.Message)
}
finally
{
$ErrorActionPreference = $errorActionSetting
if($res -ne $null)
{
$res.Close()
}
$propertyBag
}
</Script></ScriptBody>
<Parameters>
<Parameter>
<Name>PortNumber</Name>
<Value>$Target/Property[Type="Microsoft.SystemCenter.SPF.SpfServerBase"]/PortNumber$</Value>
</Parameter>
</Parameters>
<TimeoutSeconds>300</TimeoutSeconds>
<ErrorExpression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="String">Property[@Name='Result']</XPathQuery>
</ValueExpression>
<Operator>NotEqual</Operator>
<ValueExpression>
<Value Type="String">Success</Value>
</ValueExpression>
</SimpleExpression>
</ErrorExpression>
<SuccessExpression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="String">Property[@Name='Result']</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<Value Type="String">Success</Value>
</ValueExpression>
</SimpleExpression>
</SuccessExpression>
</Configuration>
</UnitMonitor>