|
1 | 1 | <?xml version="1.0" encoding="utf-8"?>
|
2 | 2 | <Configuration>
|
3 |
| - <Graphite> |
4 |
| - <CarbonServer>yourCarbonServerNameOrIP</CarbonServer> |
5 |
| - <CarbonServerPort>2003</CarbonServerPort> |
6 |
| - <MetricPath>datacenter1.servers</MetricPath> |
7 |
| - <NodeHostName>$env:COMPUTERNAME</NodeHostName> |
8 |
| - <MetricSendIntervalSeconds>5</MetricSendIntervalSeconds> |
9 |
| - <SendUsingUDP>False</SendUsingUDP> |
10 |
| - </Graphite> |
11 |
| - <PerformanceCounters> |
12 |
| - <Counter Name="\Network Interface(*)\Bytes Received/sec"/> |
13 |
| - <Counter Name="\Network Interface(*)\Bytes Sent/sec"/> |
14 |
| - <Counter Name="\Network Interface(*)\Packets Received Unicast/sec"/> |
15 |
| - <Counter Name="\Network Interface(*)\Packets Sent Unicast/sec"/> |
16 |
| - <Counter Name="\Network Interface(*)\Packets Received Non-Unicast/sec"/> |
17 |
| - <Counter Name="\Network Interface(*)\Packets Sent Non-Unicast/sec"/> |
18 |
| - <Counter Name="\Processor(_Total)\% Processor Time"/> |
19 |
| - <Counter Name="\Memory\Available MBytes"/> |
20 |
| - <Counter Name="\Memory\Pages/sec"/> |
21 |
| - <Counter Name="\Memory\Pages Input/sec"/> |
22 |
| - <Counter Name="\System\Processor Queue Length"/> |
23 |
| - <Counter Name="\System\Threads"/> |
24 |
| - <Counter Name="\PhysicalDisk(*)\Avg. Disk Write Queue Length"/> |
25 |
| - <Counter Name="\PhysicalDisk(*)\Avg. Disk Read Queue Length"/> |
26 |
| - </PerformanceCounters> |
27 |
| - <Filtering> |
28 |
| - <MetricFilter Name="isatap"/> |
29 |
| - <MetricFilter Name="teredo tunneling"/> |
30 |
| - </Filtering> |
31 |
| - <MSSQLMetics> |
32 |
| - <MetricPath>datacenter1.sqlmetrics</MetricPath> |
33 |
| - <MetricSendIntervalSeconds>60</MetricSendIntervalSeconds> |
34 |
| - <SQLConnectionTimeoutSeconds>5</SQLConnectionTimeoutSeconds> |
35 |
| - <SQLQueryTimeoutSeconds>5</SQLQueryTimeoutSeconds> |
36 |
| - <SQLServers> |
37 |
| - <!-- A SQL Server Connection Using SQL Authentication --> |
38 |
| - <SQLServer ServerInstance="(localdb)\v11.0" Username="sa" Password="PASSWORD1!"> |
39 |
| - <Query Database="mydb" MetricName="mydb.userlist.rowcount" TSQL="select count(userListID) From [dbo].[userList]"/> |
40 |
| - <Query Database="mydb" MetricName="mydb.userlist.ukemails" TSQL="select count(userListID) From [dbo].[userList] Where Emails like '%.uk%'"/> |
41 |
| - </SQLServer> |
42 |
| - <!-- A SQL Server Connection Using Windows Authentication. The credentials from the running PowerShell session will be used. --> |
43 |
| - <SQLServer ServerInstance="MSSQLServer" Username="" Password=""> |
44 |
| - <Query Database="citydb" MetricName="citydb.cities.navadwipkota" TSQL="Select COUNT (city) from [dbo].[cities] Where City = 'Navadwip' OR City = 'Kota'"/> |
45 |
| - <!-- An example query SQL query using a greater-than symbol. The symbol must be replaced with an XML Entity References. List here - http://msdn.microsoft.com/en-us/library/windows/desktop/dd892769%28v=vs.85%29.aspx --> |
46 |
| - <Query Database="addressbook" MetricName="people.ages.over30" TSQL="Select COUNT (personid) from [dbo].[tblAddressBook] Where Age > 30"/> |
47 |
| - </SQLServer> |
48 |
| - </SQLServers> |
49 |
| - </MSSQLMetics> |
50 |
| - <Logging> |
51 |
| - <VerboseOutput>True</VerboseOutput> |
52 |
| - </Logging> |
| 3 | + <Graphite> |
| 4 | + <CarbonServer>yourCarbonServerNameOrIP</CarbonServer> |
| 5 | + <CarbonServerPort>2003</CarbonServerPort> |
| 6 | + <MetricPath>datacenter1.servers</MetricPath> |
| 7 | + <NodeHostName>$env:COMPUTERNAME</NodeHostName> |
| 8 | + <MetricSendIntervalSeconds>5</MetricSendIntervalSeconds> |
| 9 | + <SendUsingUDP>False</SendUsingUDP> |
| 10 | + </Graphite> |
| 11 | + <PerformanceCounters> |
| 12 | + <Counter Name="\Network Interface(*)\Bytes Received/sec"/> |
| 13 | + <Counter Name="\Network Interface(*)\Bytes Sent/sec"/> |
| 14 | + <Counter Name="\Network Interface(*)\Packets Received Unicast/sec"/> |
| 15 | + <Counter Name="\Network Interface(*)\Packets Sent Unicast/sec"/> |
| 16 | + <Counter Name="\Network Interface(*)\Packets Received Non-Unicast/sec"/> |
| 17 | + <Counter Name="\Network Interface(*)\Packets Sent Non-Unicast/sec"/> |
| 18 | + <Counter Name="\Processor(_Total)\% Processor Time"/> |
| 19 | + <Counter Name="\Memory\Available MBytes"/> |
| 20 | + <Counter Name="\Memory\Pages/sec"/> |
| 21 | + <Counter Name="\Memory\Pages Input/sec"/> |
| 22 | + <Counter Name="\System\Processor Queue Length"/> |
| 23 | + <Counter Name="\System\Threads"/> |
| 24 | + <Counter Name="\PhysicalDisk(*)\Avg. Disk Write Queue Length"/> |
| 25 | + <Counter Name="\PhysicalDisk(*)\Avg. Disk Read Queue Length"/> |
| 26 | + </PerformanceCounters> |
| 27 | + <MetricCleaning> |
| 28 | + <!-- These will be found and replaced in the order they appear here --> |
| 29 | + <MetricReplace This="physicaldisk\(.* (.*)\:\)" With="physicaldisk.#{CAPTUREGROUP}-drive"/> |
| 30 | + <MetricReplace This="^\\\\" With=""/> |
| 31 | + <MetricReplace This="\\\\" With=""/> |
| 32 | + <MetricReplace This="\/" With="-"/> |
| 33 | + <MetricReplace This=":" With="."/> |
| 34 | + <MetricReplace This="\\" With="."/> |
| 35 | + <MetricReplace This="\(" With="."/> |
| 36 | + <MetricReplace This="\)" With=""/> |
| 37 | + <MetricReplace This="\]" With=""/> |
| 38 | + <MetricReplace This="\[" With=""/> |
| 39 | + <MetricReplace This="\%" With=""/> |
| 40 | + <MetricReplace This="\s+" With=""/> |
| 41 | + <MetricReplace This="\.\." With="."/> |
| 42 | + <MetricReplace This="_" With=""/> |
| 43 | + <MetricReplace This="\#" With="num"/> |
| 44 | + <MetricReplace This="\.processor\." With=".cpu."/> |
| 45 | + <MetricReplace This="\.cpu\.total\.processortime" With=".cpu.usage"/> |
| 46 | + <MetricReplace This="\.networkinterface\." With=".nic."/> |
| 47 | + <MetricReplace This="\.physicaldisk\." With=".hdd."/> |
| 48 | + <MetricReplace This="\.intel[a-zA-Z0-9]+\." With=".intel."/> |
| 49 | + <MetricReplace This="\.realtek[a-zA-Z0-9]+\." With=".realtek."/> |
| 50 | + <MetricReplace This="\.memory\." With=".mem."/> |
| 51 | + </MetricCleaning> |
| 52 | + <Filtering> |
| 53 | + <MetricFilter Name="isatap"/> |
| 54 | + <MetricFilter Name="teredo tunneling"/> |
| 55 | + </Filtering> |
| 56 | + <MSSQLMetics> |
| 57 | + <MetricPath>datacenter1.sqlmetrics</MetricPath> |
| 58 | + <MetricSendIntervalSeconds>60</MetricSendIntervalSeconds> |
| 59 | + <SQLConnectionTimeoutSeconds>5</SQLConnectionTimeoutSeconds> |
| 60 | + <SQLQueryTimeoutSeconds>5</SQLQueryTimeoutSeconds> |
| 61 | + <SQLServers> |
| 62 | + <!-- A SQL Server Connection Using SQL Authentication --> |
| 63 | + <SQLServer ServerInstance="(localdb)\v11.0" Username="sa" Password="PASSWORD1!"> |
| 64 | + <Query Database="mydb" MetricName="mydb.userlist.rowcount" TSQL="select count(userListID) From [dbo].[userList]"/> |
| 65 | + <Query Database="mydb" MetricName="mydb.userlist.ukemails" TSQL="select count(userListID) From [dbo].[userList] Where Emails like '%.uk%'"/> |
| 66 | + </SQLServer> |
| 67 | + <!-- A SQL Server Connection Using Windows Authentication. The credentials from the running PowerShell session will be used. --> |
| 68 | + <SQLServer ServerInstance="MSSQLServer" Username="" Password=""> |
| 69 | + <Query Database="citydb" MetricName="citydb.cities.navadwipkota" TSQL="Select COUNT (city) from [dbo].[cities] Where City = 'Navadwip' OR City = 'Kota'"/> |
| 70 | + <!-- An example query SQL query using a greater-than symbol. The symbol must be replaced with an XML Entity References. List here - http://msdn.microsoft.com/en-us/library/windows/desktop/dd892769%28v=vs.85%29.aspx --> |
| 71 | + <Query Database="addressbook" MetricName="people.ages.over30" TSQL="Select COUNT (personid) from [dbo].[tblAddressBook] Where Age > 30"/> |
| 72 | + </SQLServer> |
| 73 | + </SQLServers> |
| 74 | + </MSSQLMetics> |
| 75 | + <Logging> |
| 76 | + <VerboseOutput>True</VerboseOutput> |
| 77 | + </Logging> |
53 | 78 | </Configuration>
|
0 commit comments