Performance Counters

avatar

We don’t use the MSI installer to install PSU, so i was wondering if it’s possible to install the performance counters without it?

Monitoring - PowerShell Universal

Product: PowerShell Universal
Version: 3.5.2


avatar

Recommended Answer

Here’s the snippet from the installer.

<util:PerformanceCategory Id="Counters" Name="PowerShell Universal" MultiInstance="yes">
    <util:PerformanceCounter Name="Active Endpoints" Type="numberOfItems64" Help="Active number of executing endpoints."/>
    <util:PerformanceCounter Name="Execution Time" Type="averageTimer32" Help="Average execution time."/>
    <util:PerformanceCounter Name="Execution Time Base" Type="averageBase" Help="Average execution time base."/>
    <util:PerformanceCounter Name="Calls per second" Type="rateOfCountsPerSecond64" Help="Number of executions per second."/>
    <util:PerformanceCounter Name="Active Connections" Type="numberOfItems64" Help="Number of active connections to dashboards"/>
</util:PerformanceCategory>


We should probably provide a utility to do this outside of the installer.

I’ve opened an issue for creating some docs on how to do this: Create performance counters outside of MSI · Issue #1709 · ironmansoftware/issues · GitHub

Adam Driscoll
PowerShell Expert and Developer at Devolutions

All Comments (3)

avatar

Here’s the snippet from the installer.

<util:PerformanceCategory Id="Counters" Name="PowerShell Universal" MultiInstance="yes">
    <util:PerformanceCounter Name="Active Endpoints" Type="numberOfItems64" Help="Active number of executing endpoints."/>
    <util:PerformanceCounter Name="Execution Time" Type="averageTimer32" Help="Average execution time."/>
    <util:PerformanceCounter Name="Execution Time Base" Type="averageBase" Help="Average execution time base."/>
    <util:PerformanceCounter Name="Calls per second" Type="rateOfCountsPerSecond64" Help="Number of executions per second."/>
    <util:PerformanceCounter Name="Active Connections" Type="numberOfItems64" Help="Number of active connections to dashboards"/>
</util:PerformanceCategory>


We should probably provide a utility to do this outside of the installer.

I’ve opened an issue for creating some docs on how to do this: Create performance counters outside of MSI · Issue #1709 · ironmansoftware/issues · GitHub

Adam Driscoll
PowerShell Expert and Developer at Devolutions

avatar

Thanks Admin

To others that need to register the performance counter you can do it with “lodctr /M:”.
Just save the XML to PSU.XML and point the command at the file.

avatar

Sorry to bring up an old thread but is this still the guidance for IIS installs? I’ve the run the commands suggested but still do not see the perf counters in perfmon.