locked
MSMQ 2008 R2 database query RRS feed

  • Question

  • Hi,

    I have a custom report that queries the MSMQ (v.3) performance data from the OperationsManager DB (SCOM 2007R2). The basic query as follows:

    USE OperationsManager
    SELECT pcv.InstanceName, pdv.SampleValue, pdv.TimeSampled, pcv.CounterName
    FROM dbo.PerformanceDataAllView pdv
    INNER JOIN dbo.PerformanceCounterView pcv  
    ON pcv.PerformanceSourceInternalId = pdv.PerformanceSourceInternalId 
    WHERE  pcv.InstanceName = 'servername\queuename' and pcv.RuleId = '55531174-EEFA-D495-5556-BC37A5F5AA5E'
    ORDER BY TimeSampled DESC

    I have recently installed the MSMQ 2008 R2 (MSMQ v.5) management pack but I can't find the data for MSMQ 2008 queues in the database using the same query. In the SCOM management console I can see that SCOM detects the queues but the data does not seem to be in the same tables. Does anyone perhaps know where this data is stored for MSMQ 2008 in the database?

    Many thanks,

    Albert

    Wednesday, September 5, 2012 8:48 AM

Answers

  • Got it fixed. Make 2 mistakes:

    There needs to be data in the queues for the monitor to start writing performance data - it will n not just record 0 (duh!)

    The new rule ID is '7A80AAB9-BED5-82D6-4843-9AE0BE1A4597' - so this query will work:

    USE OperationsManager
    SELECT pcv.InstanceName, pdv.SampleValue, pdv.TimeSampled, pcv.CounterName
    FROM dbo.PerformanceDataAllView pdv
    INNER JOIN dbo.PerformanceCounterView pcv  
    ON pcv.PerformanceSourceInternalId = pdv.PerformanceSourceInternalId 
    WHERE  pcv.InstanceName = 'servername\queuename' and pcv.RuleId = '7A80AAB9-BED5-82D6-4843-9AE0BE1A4597
    ORDER BY TimeSampled DESC

    • Marked as answer by AvdVyver Wednesday, September 5, 2012 9:41 AM
    Wednesday, September 5, 2012 9:41 AM