Splunk Search

How to chart the count of requests to a website with the website's shannon value (ut_shannon)?

phudinhha
Explorer

Dear Team,

I am trying to build a chart like this:
- x-axis is the website name
- y-axis is the number of request to that website
- on top of the bar for Website, I want to display the ut_shannon value of that website.

Is there anyway that we can do it?

0 Karma

ashutoshsharma1
Path Finder
SearchTerm (anything like sourcetype="access*" ) | chart count as "Number of Request to Website" over websitename

1) save this report to a dashboard.
2) Add panel new >Event > type same search and extract that field (ut_shannon )
3) Save this panel on top of your dashboard.

please upvote and mark my answer correct if this works for you thanks 🙂
don't hesitate to ask me for any further doubt

0 Karma

maclel
Engager

Hi,

Similar to this question it appears:
https://answers.splunk.com/answers/111704/values-on-the-bar-chart.html

Which is using this as the search:

....<your search using chart/stats like count by somefield> | eval somefield=somefield."-".count

but instead yours will be something along the lines of:

 * | chart ... by somefield | eval <whatever>=somefield." - ".ut_shannon

Then in 6.3 and later you should be able to show the values on the actual chart by:

Format > General > Show Data Values > On

0 Karma

phudinhha
Explorer

Yes, i will try both solutions now to see which one is working. Thank you everyone.

0 Karma
Get Updates on the Splunk Community!

Index This | I am a number, but when you add ‘G’ to me, I go away. What number am I?

March 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...