<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to display top 10 CPU intensive windows processes using Splunk Dashboard in Dashboards &amp; Visualizations</title>
    <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-top-10-CPU-intensive-windows-processes-using/m-p/337497#M40197</link>
    <description>&lt;P&gt;Thanks for your response.  I want to list processes that are consuming CPU when CPU usage goes to &amp;gt;=70%.&lt;/P&gt;

&lt;P&gt;Eg. Say if McAfee is utilizing max CPU usage i should be able to see that in my dashboard.&lt;/P&gt;

&lt;P&gt;My current query results CPU Time as 21.2222 but i want it to display in %.  Say if McAfee is using 75% of CPU, i should be able to see on Dashboard McAfee under Instance and 75% under CPU Time by Host&lt;/P&gt;

&lt;P&gt;Hope it clarifies.&lt;/P&gt;</description>
    <pubDate>Wed, 13 Dec 2017 04:33:47 GMT</pubDate>
    <dc:creator>rahulsaxena015</dc:creator>
    <dc:date>2017-12-13T04:33:47Z</dc:date>
    <item>
      <title>How to display top 10 CPU intensive windows processes using Splunk Dashboard</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-top-10-CPU-intensive-windows-processes-using/m-p/337495#M40195</link>
      <description>&lt;P&gt;Hi Team,&lt;/P&gt;

&lt;P&gt;I am developing a dashboard that will list Windows Processes that are CPU intensive.  My query looks like below:&lt;/P&gt;

&lt;P&gt;index=platform_connect_os earliest=-5m host=host* source="Perfmon:Process"  counter="% Processor Time"  (instance!="_Total" AND instance!="Idle" AND instance!="System") | stats avg(Value) as "CPU Time by Host" by host ,instance| sort 0 -host,-AvgValue | streamstats count as sno by host | where sno&amp;gt;4 | fields - sno&lt;/P&gt;

&lt;P&gt;I am getting the below output:&lt;BR /&gt;
&lt;IMG src="https://community.splunk.com/storage/temp/220021-cpuprocess.png" alt="alt text" /&gt;&lt;/P&gt;

&lt;P&gt;Can someone confirm whether the results are correct or not?  What is the unit of CPU Time by Host.  I can't understand these numbers.  Basically i want to display something like below:&lt;BR /&gt;
&lt;IMG src="https://community.splunk.com/storage/temp/220022-cpu-process.png" alt="alt text" /&gt;&lt;/P&gt;

&lt;P&gt;I want to list process followed by CPU in human readable format in Splunk dashboard.&lt;/P&gt;

&lt;P&gt;Please help.&lt;/P&gt;

&lt;P&gt;Thanks,&lt;BR /&gt;
Rahul&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 17:13:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-top-10-CPU-intensive-windows-processes-using/m-p/337495#M40195</guid>
      <dc:creator>rahulsaxena015</dc:creator>
      <dc:date>2020-09-29T17:13:16Z</dc:date>
    </item>
    <item>
      <title>Re: How to display top 10 CPU intensive windows processes using Splunk Dashboard</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-top-10-CPU-intensive-windows-processes-using/m-p/337496#M40196</link>
      <description>&lt;P&gt;hello there,&lt;/P&gt;

&lt;P&gt;you are on the right track, leveraging the right values and fields.&lt;BR /&gt;
can you elaborate on what is it exactly you would like to accomplish? its hard for me to understand if you would like to see cpu by a single host? across hosts? per process?&lt;BR /&gt;
worthwhile to pay attention to your perfmon counter pull interval, check in inputs.conf.&lt;BR /&gt;
lastly, many articles about your use case, start here:&lt;BR /&gt;
&lt;A href="http://docs.splunk.com/Documentation/SplunkCloud/6.6.3/Data/MonitorWindowsperformance"&gt;http://docs.splunk.com/Documentation/SplunkCloud/6.6.3/Data/MonitorWindowsperformance&lt;/A&gt;&lt;BR /&gt;
describes some caveats on this particular counter (roll almost all the way down)&lt;BR /&gt;
and more articles and answers:&lt;BR /&gt;
&lt;A href="https://answers.splunk.com/answers/122302/how-to-get-a-good-measure-of-load-or-cpu-utilization-in-windows.html"&gt;https://answers.splunk.com/answers/122302/how-to-get-a-good-measure-of-load-or-cpu-utilization-in-windows.html&lt;/A&gt;&lt;BR /&gt;
&lt;A href="https://www.octamis.com/octamis-blog/windows-performance-monitoring-tips-with-splunk/"&gt;https://www.octamis.com/octamis-blog/windows-performance-monitoring-tips-with-splunk/&lt;/A&gt;&lt;BR /&gt;
there are plenty more out there&lt;/P&gt;

&lt;P&gt;hope it helps&lt;/P&gt;</description>
      <pubDate>Tue, 12 Dec 2017 16:03:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-top-10-CPU-intensive-windows-processes-using/m-p/337496#M40196</guid>
      <dc:creator>adonio</dc:creator>
      <dc:date>2017-12-12T16:03:56Z</dc:date>
    </item>
    <item>
      <title>Re: How to display top 10 CPU intensive windows processes using Splunk Dashboard</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-top-10-CPU-intensive-windows-processes-using/m-p/337497#M40197</link>
      <description>&lt;P&gt;Thanks for your response.  I want to list processes that are consuming CPU when CPU usage goes to &amp;gt;=70%.&lt;/P&gt;

&lt;P&gt;Eg. Say if McAfee is utilizing max CPU usage i should be able to see that in my dashboard.&lt;/P&gt;

&lt;P&gt;My current query results CPU Time as 21.2222 but i want it to display in %.  Say if McAfee is using 75% of CPU, i should be able to see on Dashboard McAfee under Instance and 75% under CPU Time by Host&lt;/P&gt;

&lt;P&gt;Hope it clarifies.&lt;/P&gt;</description>
      <pubDate>Wed, 13 Dec 2017 04:33:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-top-10-CPU-intensive-windows-processes-using/m-p/337497#M40197</guid>
      <dc:creator>rahulsaxena015</dc:creator>
      <dc:date>2017-12-13T04:33:47Z</dc:date>
    </item>
    <item>
      <title>Re: How to display top 10 CPU intensive windows processes using Splunk Dashboard</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-top-10-CPU-intensive-windows-processes-using/m-p/337498#M40198</link>
      <description>&lt;P&gt;Based on your suggestions i added wmi.conf file and executed below query:&lt;/P&gt;

&lt;P&gt;index=windows host=host* sourcetype="WMI:process" Name!=_Total Name!=Idle&lt;BR /&gt;
| reverse | streamstats current=f last(PercentProcessorTime) as last_PercentProcessorTime last(Timestamp_Sys100NS) as last_Timestamp_Sys100NS by Name&lt;BR /&gt;
| eval cputime = 100 * (PercentProcessorTime - last_PercentProcessorTime) / (Timestamp_Sys100NS - last_Timestamp_Sys100NS)&lt;BR /&gt;
| search cputime &amp;gt; 0&lt;BR /&gt;
| stats avg(cputime) as cputime by _time,host,Name&lt;BR /&gt;
| rex field=Name "(?[^#]*)#{0,}"&lt;BR /&gt;
| stats sum(cputime) as cputime by _time,host,Command&lt;BR /&gt;
| timechart limit=50 useother=f avg(cputime) as cputime by Command&lt;/P&gt;

&lt;P&gt;This query returns an error: "Error in 'rex' command: Encountered the following error while compiling the regex '(?[^#]*)#{0,}': Regex: unrecognized character after (? or (?- "&lt;/P&gt;

&lt;P&gt;I am not sure where in regex it is failing.  Can you help please?&lt;/P&gt;

&lt;P&gt;At the same time if i execute the following query, it works without any problem:&lt;/P&gt;

&lt;P&gt;index=windows hosts=host* sourcetype="WMI:process" Name!=_Total Name!=Idle&lt;BR /&gt;
| reverse | streamstats current=f last(PercentProcessorTime) as last_PercentProcessorTime last(Timestamp_Sys100NS) as last_Timestamp_Sys100NS by Name&lt;BR /&gt;
| eval cputime = 100 * (PercentProcessorTime - last_PercentProcessorTime) / (Timestamp_Sys100NS - last_Timestamp_Sys100NS)&lt;BR /&gt;
| search cputime &amp;gt; 0&lt;BR /&gt;
| timechart limit=50 useother=f avg(cputime) by Name&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 17:13:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-top-10-CPU-intensive-windows-processes-using/m-p/337498#M40198</guid>
      <dc:creator>rahulsaxena015</dc:creator>
      <dc:date>2020-09-29T17:13:59Z</dc:date>
    </item>
  </channel>
</rss>

