Script Engine memory usage

Microsoft.Amalga.UIS.2009.Monitoring.ScriptEngineMemoryUsage.Monitor (UnitMonitor)

Generates an alert when 1 or more Script Engine services consumes more memory than the configured threshold.

Knowledge Base article:

Summary

Script Engine memory usage is above threshold.

This monitor alerts when one or more Script Engine services is consuming more memory than the configured threshold.

Configuration

The default memory threshold is set to 500MB with the assumption of one package per a Script Engine Service. A good indication of the memory usage is by reviewing the Task Manager’s working memory set. To display Task Manager’s working set, change the default columns and select “Memory – Working Set”. Set the threshold to the Script Engine Service with the largest working set memory with a 100MB buffer.

Note: Also, consider increasing/decreasing the threshold base on message size, package per a service and the available memory.

Resolutions

Ensure there is no memory leak in the package otherwise increase the threshold to a higher value. If memory is low on the server, increase the amount of physical ram.

Element properties:

TargetMicrosoft.Amalga.UIS.2009.ScriptEngineServer
Parent MonitorSystem.Health.PerformanceState
CategoryCustom
EnabledFalse
Alert GenerateTrue
Alert SeverityMatchMonitorHealth
Alert PriorityNormal
Alert Auto ResolveTrue
Monitor TypeMicrosoft.Amalga.Library.ProcessMemoryUsageMonitorType
RemotableTrue
AccessibilityPublic
Alert Message
Script Engine memory usage is above threshold
Details are current as of the time the alert was generated.

One or more Script Engine services is consuming more memory than the configured threshold.

Environment: {0}
Computer: {1}

Process Name: {2}
Threshold Megs: {3}
Max Megs Found: {4}
Total Count: {5}

Count Over Threshold: {6}

Over Threshold:
{7}

Count Under Threshold: {8}

Under Threshold:
{9}

RunAsMicrosoft.Amalga.Library.Monitoring.RunAsAccount

Source Code:

<UnitMonitor ID="Microsoft.Amalga.UIS.2009.Monitoring.ScriptEngineMemoryUsage.Monitor" Accessibility="Public" Enabled="false" Target="Amalga2009Discovery!Microsoft.Amalga.UIS.2009.ScriptEngineServer" ParentMonitorID="Health!System.Health.PerformanceState" Remotable="true" Priority="High" RunAs="AmalgaLib!Microsoft.Amalga.Library.Monitoring.RunAsAccount" TypeID="AmalgaLib!Microsoft.Amalga.Library.ProcessMemoryUsageMonitorType" ConfirmDelivery="true">
<Category>Custom</Category>
<AlertSettings AlertMessage="Microsoft.Amalga.UIS.2009.Monitoring.ScriptEngineMemoryUsage.Monitor_AlertMessageResourceID">
<AlertOnState>Error</AlertOnState>
<AutoResolve>true</AutoResolve>
<AlertPriority>Normal</AlertPriority>
<AlertSeverity>MatchMonitorHealth</AlertSeverity>
<AlertParameters>
<AlertParameter1>$Target/Property[Type="AmalgaLib!Microsoft.Amalga.Library.Server"]/Environment$</AlertParameter1>
<AlertParameter2>$Target/Host/Property[Type="Windows!Microsoft.Windows.Computer"]/PrincipalName$</AlertParameter2>
<AlertParameter3>$Data/Context/Property[@Name='Process Name']$</AlertParameter3>
<AlertParameter4>$Data/Context/Property[@Name='Threshold Megs']$</AlertParameter4>
<AlertParameter5>$Data/Context/Property[@Name='Max Megs Found']$</AlertParameter5>
<AlertParameter6>$Data/Context/Property[@Name='Count']$</AlertParameter6>
<AlertParameter7>$Data/Context/Property[@Name='Count Over Threshold']$</AlertParameter7>
<AlertParameter8>$Data/Context/Property[@Name='Over Threshold']$</AlertParameter8>
<AlertParameter9>$Data/Context/Property[@Name='Count Under Threshold']$</AlertParameter9>
<AlertParameter10>$Data/Context/Property[@Name='Under Threshold']$</AlertParameter10>
</AlertParameters>
</AlertSettings>
<OperationalStates>
<OperationalState ID="UIGeneratedOpStateId083f35b068d443e989f777394e5cb45e" MonitorTypeStateID="LTThreshold" HealthState="Success"/>
<OperationalState ID="UIGeneratedOpStateId92f6f564a4fc4d7f80181fd22ca0ecf5" MonitorTypeStateID="GEThreshold" HealthState="Error"/>
</OperationalStates>
<Configuration>
<IntervalSeconds>1477</IntervalSeconds>
<SyncTime/>
<TimeoutSeconds>300</TimeoutSeconds>
<ThresholdValueMegs>500</ThresholdValueMegs>
<DebugEnabled>false</DebugEnabled>
<ProcessName>Microsoft.Amalga.ScriptEngine.Core.ASEService.exe</ProcessName>
<DebugEventSource>Amalga2009ScriptEngineMemoryUsageMonitor</DebugEventSource>
</Configuration>
</UnitMonitor>