HP ProLiant Server may experience a Stop error on Windows Server 2012 if the HPCISSS2.SYS driver version 62.26.0.64 is installed with the HP Smart Array Controller
http://go.microsoft.com/fwlink/?LinkId=311810
Target | Microsoft.KnowledgeServices.Windows.OperatingSystem | ||
Parent Monitor | System.Health.ConfigurationState | ||
Category | Alert | ||
Enabled | True | ||
Alert Generate | True | ||
Alert Severity | Error | ||
Alert Priority | High | ||
Alert Auto Resolve | True | ||
Monitor Type | Microsoft.KnowledgeServices.Library.PowerShellMonitorEx | ||
Remotable | True | ||
Accessibility | Public | ||
Alert Message |
| ||
RunAs | Default | ||
Comment | SupportTopic=TBD;VersionNumber=1.0.0.0; |
<UnitMonitor ID="Monitor_AKN568879" Comment="SupportTopic=TBD;VersionNumber=1.0.0.0;" Accessibility="Public" Enabled="true" Target="MicrosoftKnowledgeServicesWindowsLibrary!Microsoft.KnowledgeServices.Windows.OperatingSystem" ParentMonitorID="Health!System.Health.ConfigurationState" Remotable="true" Priority="High" TypeID="KnowledgeServicesLibrary!Microsoft.KnowledgeServices.Library.PowerShellMonitorEx" ConfirmDelivery="true">
<Category>Alert</Category>
<AlertSettings AlertMessage="MonitorMessaged8436b5c02ae4c5aa95f590df9979dcf">
<AlertOnState>Error</AlertOnState>
<AutoResolve>true</AutoResolve>
<AlertPriority>High</AlertPriority>
<AlertSeverity>Error</AlertSeverity>
<AlertParameters>
<AlertParameter1>$Data/Context/Property[@Name='StrHPCISSS2RequiredFileVersionOutput']$</AlertParameter1>
<AlertParameter2>$Data/Context/Property[@Name='StrHPCISSS2FileVersionOutput']$</AlertParameter2>
</AlertParameters>
</AlertSettings>
<OperationalStates>
<OperationalState ID="Success" MonitorTypeStateID="Success" HealthState="Success"/>
<OperationalState ID="Error" MonitorTypeStateID="Error" HealthState="Error"/>
</OperationalStates>
<Configuration>
<ScriptName>AKN568879.ps1</ScriptName>
<Parameters>
<Parameter>
<Name>StrOSVersion</Name>
<Value>$Target/Property[Type="Windows!Microsoft.Windows.OperatingSystem"]/OSVersion$</Value>
</Parameter>
<Parameter>
<Name>StrOSCaption</Name>
<Value>$Target/Property[Type="Windows!Microsoft.Windows.OperatingSystem"]/OSVersionDisplayName$</Value>
</Parameter>
</Parameters>
<ScriptBody>
param($StrOSVersion,$StrOSCaption)
$ErrorActionPreference = "Stop"
# Set up the arguments
$scriptargs = new-object psobject
$scriptargs | add-member NoteProperty "StrOSVersion" $StrOSVersion
$scriptargs | add-member NoteProperty "StrOSCaption" $StrOSCaption
# Set up the output
$global:scriptoutput = new-object psobject
$scriptoutput | add-member NoteProperty "HasIssue" $false
$scriptoutput | add-member NoteProperty "StrHPCISSS2FileVersionOutput" ""
$scriptoutput | add-member NoteProperty "StrHPCISSS2RequiredFileVersionOutput" ""
#-----------------------------------------------------
# MAIN CODE SECTION
#-----------------------------------------------------
# Environment
$scriptenv = New-Object System.Management.Automation.PSObject
$scriptenv | Add-Member NoteProperty "RuntimeError" $false
$scriptenv | Add-Member ScriptProperty "IsWindowsServer2012Env" {([version]$scriptargs.StrOSVersion).Major -eq 6 -and ([version]$scriptargs.StrOSVersion).Minor -eq 2 -and $scriptargs.StrOSCaption -like "*Windows Server 2012 *"}
$scriptenv | Add-Member NoteProperty "HPCISSS2FileVersionEnv" ""
$scriptenv | Add-Member NoteProperty "HPCISSS2RequiredFileVersionEnv" "62.24.2.64"
$scriptenv | Add-Member NoteProperty "HPCISSS2VersionIsLargerEnv" $false
function CheckHPCISSS2SysVersion
{
$HPCISSS2SysPath = Join-Path -Path $ENV:windir "System32\Drivers\HPCISSS2.sys"
if (Test-Path $HPCISSS2SysPath)
{
$fileVer = [System.Diagnostics.FileVersionInfo]::GetVersionInfo($HPCISSS2SysPath)
$scriptenv.HPCISSS2FileVersionEnv = "{0}.{1}.{2}.{3}" -f $fileVer.FileMajorPart,$fileVer.FileMinorPart,$fileVer.FileBuildPart,$fileVer.FilePrivatePart
if([version]$scriptenv.HPCISSS2FileVersionEnv -eq [version]"62.26.0.64")
{
$scriptenv.HPCISSS2VersionIsLargerEnv = $true
}
}
}
# Main function
function AdvisorRule($scriptargs, $scriptoutput)
{
# All parameters should be populated outside of the main function.
# The main function should only include the detection logic so that it can be easily reused by the Atlanta authoring tool.
trap [Exception] {
$scriptenv.RuntimeError = $true
continue
}
# Initialize parameters
$scriptoutput.HasIssue = $false
$scriptoutput.StrHPCISSS2FileVersionOutput = ""
$scriptoutput.StrHPCISSS2RequiredFileVersionOutput = ""
# Set parameter values
if($scriptenv.IsWindowsServer2012Env -eq $true)
{
CheckHPCISSS2SysVersion
if($scriptenv.HPCISSS2VersionIsLargerEnv -eq $true)
{
if($scriptenv.RuntimeError -eq $false)
{
$scriptoutput.HasIssue = $true
$scriptoutput.StrHPCISSS2FileVersionOutput = $scriptenv.HPCISSS2FileVersionEnv
$scriptoutput.StrHPCISSS2RequiredFileVersionOutput = $scriptenv.HPCISSS2RequiredFileVersionEnv
}
}
}
}
AdvisorRule $scriptargs $scriptoutput
# set the output
$mom = new-object -comobject "MOM.ScriptAPI"
$bag = $mom.CreatePropertyBag()
if ($scriptoutput.HasIssue -ne $null)
{
$bag.AddValue("HasIssue", $scriptoutput.HasIssue)
}
if ($scriptoutput.StrHPCISSS2FileVersionOutput -ne $null)
{
$bag.AddValue("StrHPCISSS2FileVersionOutput", $scriptoutput.StrHPCISSS2FileVersionOutput)
}
if ($scriptoutput.StrHPCISSS2RequiredFileVersionOutput -ne $null)
{
$bag.AddValue("StrHPCISSS2RequiredFileVersionOutput", $scriptoutput.StrHPCISSS2RequiredFileVersionOutput)
}
$bag
</ScriptBody>
<SnapIns/>
<TimeoutSeconds>300</TimeoutSeconds>
<Schedule>86393</Schedule>
<ErrorExpression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="Boolean">Property[@Name='HasIssue']</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<Value Type="Boolean">true</Value>
</ValueExpression>
</SimpleExpression>
</ErrorExpression>
<SuccessExpression>
<Not>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="Boolean">Property[@Name='HasIssue']</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<Value Type="Boolean">true</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
</Not>
</SuccessExpression>
</Configuration>
</UnitMonitor>