Sample active sessions

Citrix.PresentationServer.ActiveSessions.CollectionRule (Rule)

Collects active session performance data from the Citrix Presentation Server Provider

Knowledge Base article:

Citrix ® Management Pack

Summary

This rule measures the number of active sessions on the local server. This data is displayed in the Active Sessions view and is used in an alert if the number of active sessions on a server exceeds a configurable limit.

 
© 2002-2008 Citrix Systems, Inc. All rights reserved.

Element properties:

TargetCitrix.PresentationServer.ManagedServer
CategoryPerformanceCollection
EnabledTrue
Alert GenerateFalse
RemotableTrue

Member Modules:

ID Module Type TypeId RunAs 
WMIPerfCounterCollectionDS DataSource Microsoft.Windows.WmiPerfCounterProvider Citrix.PresentationServer.CitrixAdministratorAccount
WriteToDB WriteAction Microsoft.SystemCenter.CollectPerformanceData Citrix.PresentationServer.CitrixAdministratorAccount
WriteToDW WriteAction Microsoft.SystemCenter.DataWarehouse.PublishPerformanceData Citrix.PresentationServer.CitrixAdministratorAccount

Source Code:

<Rule ID="Citrix.PresentationServer.ActiveSessions.CollectionRule" Enabled="true" Target="Citrix.PresentationServer.ManagedServer" ConfirmDelivery="false" Remotable="true" Priority="Normal" DiscardLevel="100">
<Category>PerformanceCollection</Category>
<DataSources>
<DataSource ID="WMIPerfCounterCollectionDS" RunAs="CtxLibrary!Citrix.PresentationServer.CitrixAdministratorAccount" TypeID="Windows!Microsoft.Windows.WmiPerfCounterProvider">
<NameSpace>\\$Target/Host/Property[Type='Windows!Microsoft.Windows.Computer']/NetworkName$\root\Citrix</NameSpace>
<Query>SELECT * FROM MetaFrame_Server WHERE ServerName="$Target/Host/Property[Type='Windows!Microsoft.Windows.Computer']/NetbiosComputerName$"</Query>
<Frequency>1020</Frequency>
<ObjectName>MetaFrame_Server</ObjectName>
<CounterName>NumberOfActiveSessions</CounterName>
<InstanceName>$Target/Property[Type='CtxLibrary!Citrix.Library.ServerApplication']/Name$</InstanceName>
<Value>$Data/Property[@Name='NumberOfActiveSessions']$</Value>
</DataSource>
</DataSources>
<WriteActions>
<WriteAction ID="WriteToDB" RunAs="CtxLibrary!Citrix.PresentationServer.CitrixAdministratorAccount" TypeID="SC!Microsoft.SystemCenter.CollectPerformanceData"/>
<WriteAction ID="WriteToDW" RunAs="CtxLibrary!Citrix.PresentationServer.CitrixAdministratorAccount" TypeID="SCDW!Microsoft.SystemCenter.DataWarehouse.PublishPerformanceData"/>
</WriteActions>
</Rule>