Raccolta numero di tabelle del database MySQL

Microsoft.MySQLServer.Database.Unix.NumberOfTables.Collection (Rule)

Questa regola raccoglie il numero di tabelle di un database MySQL

Knowledge Base article:

Riepilogo

Questa regola raccoglie i dati sulle prestazioni per il contatore delle prestazioni Database MySQL\ Numero di tabelle. I valori raccolti sono accessibili nelle viste Prestazioni. Questa metrica espone il numero totale di tabelle per un database MySQL. Il valore restituito dall'agente viene calcolato analizzando tutte le tabelle associate al database nel database information_schema che fa parte del server MySQL.

Element properties:

TargetMicrosoft.MySQLServer.Database.Unix
CategoryPerformanceCollection
EnabledTrue
Alert GenerateFalse
RemotableTrue

Member Modules:

ID Module Type TypeId RunAs 
DS DataSource Microsoft.Oss.WSMan.PerfCounterProvider.Filtered.TimedEnumerator Default
WriteToDB WriteAction Microsoft.SystemCenter.CollectPerformanceData Default
WriteToDW WriteAction Microsoft.SystemCenter.DataWarehouse.PublishPerformanceData Default

Source Code:

<Rule ID="Microsoft.MySQLServer.Database.Unix.NumberOfTables.Collection" Target="Microsoft.MySQLServer.Database.Unix" Remotable="true" Enabled="onStandardMonitoring">
<Category>PerformanceCollection</Category>
<DataSources>
<DataSource ID="DS" TypeID="Oss!Microsoft.Oss.WSMan.PerfCounterProvider.Filtered.TimedEnumerator">
<Interval>300</Interval>
<TargetSystem>$Target/Host/Host/Property[Type="Unix!Microsoft.Unix.Computer"]/NetworkName$</TargetSystem>
<Uri>http://schemas.microsoft.com/wbem/wscim/1/cim-schema/2/MySQL_Server_Database?__cimnamespace=root/mysql</Uri>
<Filter/>
<SplitItems>true</SplitItems>
<ObjectName>MySQL Database</ObjectName>
<CounterName>Number Of Tables</CounterName>
<InstanceName>$Target/Property[Type="Microsoft.MySQLServer.Database"]/InstanceID$</InstanceName>
<InstanceProperty>/DataItem/WsManData/*[local-name(.)='MySQL_Server_Database']/*[local-name(.)='InstanceID']</InstanceProperty>
<Value>$Data/WsManData/*[local-name(.)='MySQL_Server_Database']/*[local-name(.)='NumberOfTables']$</Value>
</DataSource>
</DataSources>
<WriteActions>
<WriteAction ID="WriteToDB" TypeID="SC!Microsoft.SystemCenter.CollectPerformanceData"/>
<WriteAction ID="WriteToDW" TypeID="SCDW!Microsoft.SystemCenter.DataWarehouse.PublishPerformanceData"/>
</WriteActions>
</Rule>