Activity Feed
- Posted How to show same data for different timezones in single timechart ? on Splunk Search. 06-15-2022 03:00 AM
- Posted Re: How to compare the columns values against another column on Splunk Search. 03-01-2022 09:39 AM
- Karma Re: How to compare the columns values against another column for venky1544. 03-01-2022 09:38 AM
- Posted Re: How to compare the columns values against another column on Splunk Search. 03-01-2022 09:36 AM
- Posted Re: How to compare the columns values against another column on Splunk Search. 03-01-2022 09:29 AM
- Posted How to compare the columns values against another column on Splunk Search. 03-01-2022 06:17 AM
- Posted How to plot a barchart based on String rather than numbers on Dashboards & Visualizations. 08-09-2021 09:41 AM
- Posted How to search for last 6 months for event indexed every month? on Splunk Search. 07-23-2021 01:15 AM
- Posted Re: Invalid Date using Job in the UI on Dashboards & Visualizations. 07-19-2021 11:21 PM
- Karma Re: Invalid Date using Job in the UI for kamlesh_vaghela. 07-19-2021 11:20 PM
- Posted Re: Invalid Date using Job in the UI on Dashboards & Visualizations. 07-19-2021 04:21 AM
- Posted Re: Invalid Date using Job in the UI on Dashboards & Visualizations. 07-19-2021 04:20 AM
- Posted Invalid Date using Job in the UI on Dashboards & Visualizations. 07-19-2021 12:40 AM
- Karma Re: How to avoid un-responsive dropdown input with 100K or more results using Simple XML for niketn. 05-26-2021 10:38 PM
- Posted How to compare last column with previously violated column under foreach? on Splunk Search. 05-26-2021 06:32 AM
- Posted Re: How to get the latest violator value and its month and the number of times it has violated on Splunk Search. 12-03-2020 12:29 AM
- Posted How to get the latest violator value and its month and the number of times it has violated on Splunk Search. 12-02-2020 02:45 AM
- Posted Re: How to get the Max out of row and field name of the max value on Splunk Search. 11-30-2020 09:56 PM
- Posted How to get the Max out of row and field name of the max value on Splunk Search. 11-30-2020 03:13 AM
- Got Karma for Re: How to pass earliest and latest based on week number under drilldown. 09-04-2020 09:25 AM
Topics I've Started
Subject | Karma | Author | Latest Post |
---|---|---|---|
0 | |||
0 | |||
0 | |||
0 | |||
0 | |||
0 | |||
0 | |||
0 | |||
0 | |||
0 |
06-15-2022
03:00 AM
I have a panel which shows the usage of a dashboard in GMT timezone. Is it possible to show the same data in different timezones (PST, EST, IST, etc) as different lines in same chart? Below is the query which shows count in GMT timezones index="_internal" user!="-" sourcetype=splunkd_ui_access "GET" "sample" | rex field=uri "\/app\/(?<App_Value>\w+)\/(?<dashboard>[^?\/]+)" | search App_Value="sample" dashboard = "daily_health" |timechart count How can we modify this query to show in different timezone in single chart?
... View more
Labels
- Labels:
-
count
-
field extraction
-
timechart
03-01-2022
09:39 AM
Thanks for you response. This would work too. But I want more of a count rather than OK or NOT. Appreciate your effort. Thanks again
... View more
03-01-2022
09:36 AM
ITWhisperer Is there a possible way to consider only the latest date column value alone and compare it with threshold field?
... View more
03-01-2022
09:29 AM
Thanks. It worked. Didnt know that I can use Threshold field inside foreach without being included in foreach condition.
... View more
03-01-2022
06:17 AM
Hi Guys, I am having a query which would result as below, The above shows count by xyz for the user selected timerange. I would like to add one more column to this table as LessThanThreshold - which would tell the number of times the count in each day was below the corresponding Threshold value. To be precise for a row, if the value of 01-Mar-22 < Threshold then increment the new column LessThanThreshold by 1, if 28-Feb-22<Threshold, then increment LessThanThreshold by 1. Using Foreach I am not sure to compare between columns itself. Could someone please help me out here. Thanks
... View more
08-09-2021
09:41 AM
Hi, I have events with below format, 08/09/202109:27:00 +0000, search_name=sre_slo_BE_module_priority_monthly, search_now=1628501220.000, info_max_time=1628501220.000, info_search_time=1628501221.635, Module=InvoiceManagement, Priority=P4, LastViolationMonth="Jul-2021", MissedCount=1, LastViolationp90ResponseTime (s)="30.44", Deviation (%)="1.5" I would like to plot a graph which would have Y axis with values as P1, P2, P3, P4 & x axis with Month. I tried using below query to plot a graph by assigning values to the Priorities. But again, the Y axis becomes based on the Values assigned to the Priority rather than Priority itself. index=summary source=sre_slo_BE_module_priority_monthly Module="ControlCenter"
| eval convert_epoch = strftime(_time,"%m-%d-%Y")
| eval prevMonth=lower(strftime(relative_time(_time,"-1mon@d"),"%B"))
| eval MonthYear = prevMonth + "-" + date_year
| search convert_epoch!="08-01-2021"
| eval PriorityValue = case(Priority="P1", 4, Priority="P2", 3, Priority="P3", 2, Priority="P4", 1)
| stats values(PriorityValue) as PriorityValue by MonthYear, Priority Below is the graph which I get. Instead of PriorityValue on the Y axis, I need Priority itself. Could someone please help me out here @kamlesh_vaghela @diogofgm Is this something which you can assist with. Appreciate if you can help on this Thanks
... View more
- Tags:
- barchart layout
Labels
- Labels:
-
table
07-23-2021
01:15 AM
Hi, I have a summary index which gets indexed once in a month. I have a query which runs based on current month looks back at last 6 months and provides me a report. Is it possible to rewrite a query to show a trend which can go over each months' event and look back 6months of data for each month and provide a report? Here is the query which looks back at last 6 months from current month. I would like to do the same for all months (look back from each month) and provide a trend index=summary source=sre_slo_BE_qlatency_permodule_monthly
| where _time>=relative_time(now(),"-6mon@mon")
| eval Month=Month + "-" + Year
| chart values(p90Latency) as P90Latency by Month, Module useother=f limit=10000
| eval MonthYear=Month, Year=substr(Month,5,4), Month=substr(Month,0,3)
| fields - Year
| table MonthYear *
| transpose 20 header_field=MonthYear, column_name=Module
| foreach *20*
[ eval Max=case(Max>=if(isnull('<<FIELD>>'),0,'<<FIELD>>'),Max,true(),if(isnull('<<FIELD>>'),0,'<<FIELD>>'))]
| where Max>30000
| foreach *20*
[eval <<FIELD>>=ROUND(('<<FIELD>>')/1000,2)]
| fields - Max
| rename Module as MainModule
| eval RequestType="Business Event"
| lookup SLOHighToleranceLookup RequestType OUTPUTNEW Module | eval Module=if(isnull(Module), "null", Module)
| where MainModule != Module
| fields - Module, RequestType
| rename MainModule as Module
| eval ViolationCount=0, LastViolatedMonth="", LastViolatedResponse=0, TotalViolationCount=0
| foreach *-2020 or *-2021
[ | eval LastViolatedMonth = if('<<FIELD>>'>30,"<<FIELD>>", LastViolatedMonth)
, LastViolatedMonthNumber = substr(LastViolatedMonth, 0, 2)
, ViolationCount=if(('<<FIELD>>'>30), ViolationCount+1, ViolationCount)
, LastViolatedResponse=if('<<FIELD>>'>30,'<<FIELD>>', LastViolatedResponse)
, Deviation=case(LastViolatedResponse>30,round(((LastViolatedResponse-30)/30)*100,1))
, Priority = case(
(Deviation >= 100 AND ViolationCount >=1), "P1"
, ((Deviation >= 75 AND Deviation < 100) AND ViolationCount >=3), "P1"
, ((Deviation >= 75 AND Deviation < 100) AND (ViolationCount >= 0 AND ViolationCount < 3)), "P2"
, ((Deviation >= 50 AND Deviation < 75) AND ViolationCount >= 3), "P2"
, ((Deviation >= 50 AND Deviation < 75) AND (ViolationCount >= 0 AND ViolationCount < 3)), "P3"
, ((Deviation >= 25 AND Deviation < 50) AND ViolationCount >= 3), "P3"
, ((Deviation >= 25 AND Deviation < 50) AND (ViolationCount >= 1 AND ViolationCount < 3)), "P4"
, ((Deviation > 0 AND Deviation < 25) AND ViolationCount >= 0), "P4"
)]
| eval LastViolatedMonthNumber = substr(LastViolatedMonth, 0, 2)
, LastViolatedMonthYear = substr(LastViolatedMonth, 4, 4)
| eval LastViolatedMonth = case(LastViolatedMonthNumber==01, "Jan", LastViolatedMonthNumber==02, "Feb", LastViolatedMonthNumber==3, "Mar", LastViolatedMonthNumber==4, "Apr", LastViolatedMonthNumber==5, "May", LastViolatedMonthNumber==6, "Jun", LastViolatedMonthNumber==7, "Jul", LastViolatedMonthNumber==8, "Aug", LastViolatedMonthNumber==9, "Sep", LastViolatedMonthNumber==10, "Oct", LastViolatedMonthNumber==11, "Nov", LastViolatedMonthNumber==12, "Dec")
| eval LastViolatedMonth=LastViolatedMonth + "-" + LastViolatedMonthYear
| fields Module, LastViolatedMonth, LastViolatedResponse, ViolationCount, Deviation, Priority, LastViolatedMonthNumber, LastViolatedMonthYear
| sort - LastViolatedResponse
| rename LastViolatedMonth as "Last Violation Month", LastViolatedResponse as "Last Violation p90ResponseTime (s)", Deviation as "Deviation (%)", ViolationCount as "Missed Count"
| eval CurrentMonth = strftime(now(), "%m"), CurrentYear= strftime(now(), "%Y"), ViolationMonthDifference=if(CurrentYear>LastViolatedMonthYear, (12-LastViolatedMonthNumber)+CurrentMonth, CurrentMonth-LastViolatedMonthNumber)
| where ViolationMonthDifference<=3
| eval Priority = if(Priority=="P1" AND LastViolatedMonthNumber != CurrentMonth-1 , "P2", Priority)
| fields - LastViolatedMonthNumber, LastViolatedMonthYear, CurrentMonth, CurrentYear, ViolationMonthDifference Thanks
... View more
07-19-2021
11:21 PM
This works. Thanks for looking into this.
... View more
07-19-2021
04:21 AM
This doesnt work either
... View more
07-19-2021
04:20 AM
I am so sorry hear that. I didnt know. May his soul rest in peace. Didnt expect
... View more
07-19-2021
12:40 AM
@niketn I am trying to display the selected start and end time in the UI. I followed particularly the below answer given by you. https://community.splunk.com/t5/Dashboards-Visualizations/Setting-job-earliestTime-and-job-latestTime-tokens-for-the-date/m-p/345200/highlight/true#M22464 It was working fine but suddenly it stopped saying Invalid Date. We recently had a splunk Upgrade to Version:8.0.4.1. Could it be due to the upgrade? Was there any change. I couldnt narrow down to exact issue. Here is the code which you have shared <form>
<label>Show Time from Time Picker</label>
<!-- Dummy search to pull selected time range earliest and latest date/time -->
<search>
<query>| makeresults | addinfo </query>
<earliest>$field1.earliest$</earliest>
<latest>$field1.latest$</latest>
<done>
<eval token="tokEarliestTime">strftime(strptime('$job.earliestTime$',"%Y/%m/%dT%H:%M:%S.%3N %p"),"%m/%d/%y %I:%M:%S.%3N %p")</eval>
<eval token="tokLatestTime">strftime(strptime('$job.latestTime$',"%Y/%m/%dT%H:%M:%S.%3N %p"),"%m/%d/%y %I:%M:%S.%3N %p")</eval>
</done>
</search>
<fieldset submitButton="false">
<input type="time" token="field1">
<label></label>
<default>
<earliest>-24h@h</earliest>
<latest>now</latest>
</default>
</input>
</fieldset>
<row>
<panel>
<!-- sample HTML Panel to display results in required format -->
<html>
( $tokEarliestTime$ to $tokLatestTime$)
</html>
</panel>
</row>
</form> Attaching the screenshot of what is shown in the UI. Could you please suggest.
... View more
- Tags:
- invalid date
05-26-2021
06:32 AM
Hi I have a query which results me data in the below format, I am trying to put out a table assigning priority based on the response(>2s is violator) for module and number of times violation occurred. | foreach *-2020 or *-2021
[ | eval LastViolatedMonth = if('<<FIELD>>'>2,"<<FIELD>>", LastViolatedMonth)
, LastViolatedMonthNumber = substr(LastViolatedMonth, 0, 2)
, ViolationCount=if(('<<FIELD>>'>2), ViolationCount+1, ViolationCount)
, LastViolatedResponse=if('<<FIELD>>'>2,'<<FIELD>>', LastViolatedResponse)
, Deviation=case(LastViolatedResponse>2,round(((LastViolatedResponse-2)/2)*100,1))
, Priority = case(
(Deviation >= 100 AND ViolationCount >=1), "P1"
, ((Deviation >= 75 AND Deviation < 100) AND ViolationCount >=3), "P1"
, ((Deviation >= 75 AND Deviation < 100) AND (ViolationCount >= 0 AND ViolationCount < 3)), "P2"
, ((Deviation >= 50 AND Deviation < 75) AND ViolationCount >= 3), "P2"
)]
| fields Module, LastViolatedMonth, LastViolatedResponse, ViolationCount, Deviation, Priority Currently the Module is considered P1 violator when the violation count is >3. I would like to add one more condition to check for the previous month response - if it was a violator or not.If previous month is not a violator but the latest/last month is a violator and the violation count >=3, I want that module to be marked as P2(not P1). I am not sure how to check the previous column value(that is previous month value - to check if it violated then) against the last/latest month under for each statement. Could someone please help me out here. @bowesmana Can you help me on this. Thanks
... View more
- Tags:
- foreach
12-03-2020
12:29 AM
Thanks. This worked. I just had to change the Month name to month number for this to work.
... View more
12-02-2020
02:45 AM
Hi, I have a below search result which shows Violators as red in color. Violators are more than 2 sec I would like to get a resultset which would show the latest month when the violation happened, its response time and the number of times it has violated. Something like, Module LastViolatedMonth LastViolatedResponse ViolationCount AppSDK Nov-2020 3.17 10 DocumentExchange Oct-2020 2.29 6 FrieghtAudit Aug-2020 2.18 4 could someone please help me out here. Thanks
... View more
Labels
- Labels:
-
chart
-
field extraction
-
fields
-
stats
11-30-2020
09:56 PM
Thanks it worked
... View more
11-30-2020
03:13 AM
Hi, I have below resultset in place. How do I get the Max by row and the Month when the Max happened. Something like below result Module Month when Max occured Max Value AppSDK Aug-2020 4.21 Comments Aug-2020 0.10 ControlCenter Jan-2020 0.72 Thanks
... View more
09-04-2020
05:57 AM
1 Karma
Thanks a lot. This works for me. Just did few changes on the number of days to be selected for the week.
... View more
09-02-2020
05:45 AM
@niketn is this something which you can help me on? Could you please provide suggestion
... View more
09-02-2020
05:36 AM
Hi I have input fields which has value as week number. Based on the Weeknum selected, how do I pass on the earliest and latest date under my drilldown. Here is my input field <input type="dropdown" token="weeknum" searchWhenChanged="true"> And here is my drilldown section from one of the dashboard panel where time range gets passed to another page (sre_module_summary) in the name of token selectedearliest & selectedlatest. How to get the values for the token based on the weeknum selected from input panel. <drilldown target="_blank">
<eval token="Module">$click.value$</eval>
<eval token="HostType">$HostType$</eval>
<link>
<![CDATA[/app/sre/sre_module_summary?form.Module=$Module$&host=$HostType$&form.timerange.earliest=$selectedearliest$&form.timerange.latest=$selectedlatest$]]>
</link>
</drilldown> Could someone please help.
... View more
Labels
- Labels:
-
using Splunk Enterprise
09-01-2020
01:12 AM
Hi I have input fields which has value as week number. Based on the Weeknum selected, how do I pass on the earliest and latest date under my drilldown. Here is my input field <input type="dropdown" token="weeknum" searchWhenChanged="true"> And here is my drilldown section from one of the dashboard panel where time range gets passed to another page (sre_module_summary) in the name of token selectedearliest & selectedlatest. How to get the values for the token based on the weeknum selected from input panel. <drilldown target="_blank">
<eval token="Module">$click.value$</eval>
<eval token="HostType">$HostType$</eval>
<link>
<![CDATA[/app/sre/sre_module_summary?form.Module=$Module$&host=$HostType$&form.timerange.earliest=$selectedearliest$&form.timerange.latest=$selectedlatest$]]>
</link>
</drilldown> Could someone please help.
... View more
- Tags:
- drilldown
Labels
- Labels:
-
field extraction
06-11-2020
11:52 PM
Hi I have a table which displays duration for each category. I would like color code fields based on its duration. In the above screenshot, how do I write an expression to color code which are exceeding 1min. I would prefer using the color coding from the source rather than creating JSS because we dont have the permission to splunk servers as such to update config/put the JS scripts. Could someone please help me out here
... View more
Labels
- Labels:
-
using Splunk Enterprise
05-26-2020
01:53 AM
This Works. Thanks a lot
... View more
05-26-2020
01:45 AM
ok you are doing a compare of the max with each and every field. Got it. This should ideally work.
... View more
05-26-2020
12:39 AM
I have updated my query with the screenshot. As you can see, Mar-2020 is taken as the max field
... View more
05-26-2020
12:02 AM
@493669
It is not providing the max value instead for all the rows it takes max of fields name and not field value.
... View more