Refine your search:

Hello,

I am writing a search to integrate with my dashboard.

Goal:
Display current license usage in megabytes as an integer in a "Single Value" type graph.

Error:
When I run the search, I get "N/A" back.

Current Search:
index=internal source=metrics.log group=per_index_thruput series!= | eval totalMB = kb/1024 | chart sum(totalMB) as total

Any help is appreciated!

asked 30 Apr '12, 05:03

mchandx's gravatar image

mchandx
5115
accept rate: 75%


3 Answers:

Believe that I may have this resolved.

index=_internal source=*metrics.log group=per_index_thruput series!=_* | eval totalMB = kb/1024 | chart sum(totalMB) as total
link

answered 30 Apr '12, 05:30

mchandx's gravatar image

mchandx
5115
accept rate: 75%

edited 30 Apr '12, 05:30

Here is an example that works. You can modify accordingly.

index=_internal todaysbytesindexed startdaysago=30 | eval MB_Indexed = todaysBytesIndexed/1024/1024 | stats sum(MB_Indexed) by date_month

There are also several references on this post.

How to determine daily license usage in GB? on Splunk Answers

link

answered 30 Apr '12, 05:12

sdaniels's gravatar image

sdaniels ♦
4.6k49
accept rate: 34%

I have tried this before as this is what is in the documentation, but it displays the incorrect information.

(30 Apr '12, 05:27) mchandx

There are 2 alternatives to show the current (today's) license usage:

| rest /services/licenser/pools | stats sum(used_bytes) as used | eval used=round(used/1024/1024)

or

index=_internal source=*license_usage.log type=Usage earliest=@d | stats sum(b) as bytes | eval mb=round(bytes/1024/1024) | fields mb
link

answered 30 Apr '12, 05:41

ziegfried's gravatar image

ziegfried ♦
10.3k1618
accept rate: 52%

Post your answer
toggle preview

Follow this question

Log In to enable email subscriptions

RSS:

Answers

Answers + Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "Title")
  • image?![alt text](/path/img.jpg "Title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×185
×47
×38
×19
×1

Asked: 30 Apr '12, 05:03

Seen: 579 times

Last updated: 30 Apr '12, 05:41

Copyright © 2005-2012 Splunk Inc. All rights reserved.