<?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 do I search the license usage by sourcetype for a particular app? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-search-the-license-usage-by-sourcetype-for-a-particular/m-p/260425#M78075</link>
    <description>&lt;P&gt;thanks J.. solved my issue..&lt;/P&gt;</description>
    <pubDate>Tue, 02 Feb 2016 11:56:12 GMT</pubDate>
    <dc:creator>sunnyparmar</dc:creator>
    <dc:date>2016-02-02T11:56:12Z</dc:date>
    <item>
      <title>How do I search the license usage by sourcetype for a particular app?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-search-the-license-usage-by-sourcetype-for-a-particular/m-p/260423#M78073</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I have one app which doesn't have indexes in it. The dashboards under it are running via either source, sourcetype, and host. Now I have to find the license usage for that app by all the given modes i.e. source, sourcetype, and host. I have searched for all these three parameters, but when I am executing the search, it is showing all sources, sourcetypes, and hosts for all the apps in the result. Now the problem is I don't know which sources, sourcetypes, and hosts belong to that particular app out of all those, so how can I separate these three instances for that particular app from that results? Any suggestions would be appreciated.&lt;/P&gt;

&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 02 Feb 2016 09:41:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-I-search-the-license-usage-by-sourcetype-for-a-particular/m-p/260423#M78073</guid>
      <dc:creator>sunnyparmar</dc:creator>
      <dc:date>2016-02-02T09:41:55Z</dc:date>
    </item>
    <item>
      <title>Re: How do I search the license usage by sourcetype for a particular app?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-search-the-license-usage-by-sourcetype-for-a-particular/m-p/260424#M78074</link>
      <description>&lt;P&gt;The following query will give you the list of sourcetypes per app:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; | rest /services/saved/sourcetypes
 | fields title, "eai:acl.app"
 | rename title AS sourcetype, "eai:acl.app" AS app_name
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;If you then join that by sourcetype with your license query you should be able to list what you want.&lt;/P&gt;

&lt;P&gt;Something like this for instance:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=_internal source=*license_usage.log type="Usage" 
 | eval indexname = if(len(idx)=0 OR isnull(idx),"(UNKNOWN)",idx)
 | eval sourcetypename = st
 | bin _time span=1d 
 | stats sum(b) as b by _time, pool, indexname, sourcetypename
 | eval GB=round(b/1024/1024/1024, 3)
 | fields _time, indexname, sourcetypename, GB
 | join sourcetypename [
     | rest /services/saved/sourcetypes
     | fields title, "eai:acl.app"
     | rename title AS sourcetypename, "eai:acl.app" AS app_name
]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Thanks,&lt;BR /&gt;
J&lt;/P&gt;</description>
      <pubDate>Tue, 02 Feb 2016 10:02:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-I-search-the-license-usage-by-sourcetype-for-a-particular/m-p/260424#M78074</guid>
      <dc:creator>javiergn</dc:creator>
      <dc:date>2016-02-02T10:02:00Z</dc:date>
    </item>
    <item>
      <title>Re: How do I search the license usage by sourcetype for a particular app?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-search-the-license-usage-by-sourcetype-for-a-particular/m-p/260425#M78075</link>
      <description>&lt;P&gt;thanks J.. solved my issue..&lt;/P&gt;</description>
      <pubDate>Tue, 02 Feb 2016 11:56:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-I-search-the-license-usage-by-sourcetype-for-a-particular/m-p/260425#M78075</guid>
      <dc:creator>sunnyparmar</dc:creator>
      <dc:date>2016-02-02T11:56:12Z</dc:date>
    </item>
    <item>
      <title>Re: How do I search the license usage by sourcetype for a particular app?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-search-the-license-usage-by-sourcetype-for-a-particular/m-p/260426#M78076</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;
just to make sure I understand this search ('cause I have to solve a similar question...).&lt;/P&gt;

&lt;P&gt;The join returns a list of sourcetypes and the app where this sourcetype is defined/saved.... &lt;/P&gt;

&lt;P&gt;The first part of the search will break down the indexed volume by index and sourcetype.&lt;/P&gt;

&lt;P&gt;To my mind the question is only answered correctly if a sourcetype is only used in one specific app... &lt;/P&gt;

&lt;P&gt;If you use a generic sourcetype like access_combined... you'll see only "system" as "app"... because this sourcetype is simply defined in "system"... &lt;/P&gt;

&lt;P&gt;I am of the opinion that the question can only be answered if you define a custom sourcetype in your app and define inputs using this sourcetype only in this specific app (or an other single app because you might have a TA defining a sourcetype and a single app to provide dashboards/searches for this sourcetype).&lt;/P&gt;

&lt;P&gt;Please feel free to correct me if I am wrong. &lt;BR /&gt;
It might be possible that I did not get the whole idea &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt; &lt;/P&gt;

&lt;P&gt;Greetings,&lt;/P&gt;

&lt;P&gt;Holger&lt;/P&gt;</description>
      <pubDate>Mon, 09 Jan 2017 14:36:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-I-search-the-license-usage-by-sourcetype-for-a-particular/m-p/260426#M78076</guid>
      <dc:creator>hsesterhenn_spl</dc:creator>
      <dc:date>2017-01-09T14:36:07Z</dc:date>
    </item>
  </channel>
</rss>

