<?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: List all reporting devices per Splunk server in Reporting</title>
    <link>https://community.splunk.com/t5/Reporting/List-all-reporting-devices-per-Splunk-server/m-p/11298#M54</link>
    <description>&lt;P&gt;Just use:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| metadata type=hosts
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Unfortunately, the &lt;CODE&gt;|metadata&lt;/CODE&gt; command always runs in distributed mode and does not break out results by splunk_server, so you might have to figure out a way to run it in non-distributed mode on each individual server to get the list for each indexer.&lt;/P&gt;

&lt;P&gt;You could also just go into the &lt;CODE&gt;$SPLUNK_HOME/var/lib/splunk/defaultdb/db/&lt;/CODE&gt; directory (or wherever you keep your indexes hot/warm db) and look in the &lt;CODE&gt;Hosts.data&lt;/CODE&gt; file on each server, and repeat for each index you're interested in.&lt;/P&gt;</description>
    <pubDate>Tue, 13 Apr 2010 21:10:00 GMT</pubDate>
    <dc:creator>gkanapathy</dc:creator>
    <dc:date>2010-04-13T21:10:00Z</dc:date>
    <item>
      <title>List all reporting devices per Splunk server</title>
      <link>https://community.splunk.com/t5/Reporting/List-all-reporting-devices-per-Splunk-server/m-p/11297#M53</link>
      <description>&lt;P&gt;Hi There, &lt;/P&gt;

&lt;P&gt;Here goes my first question.&lt;/P&gt;

&lt;P&gt;I need to generate a list of all hosts reporting to each splunk server so I can properly migrate the servers reporting to Splunk-A server to a different Splunk-B instanc on a different data center.&lt;/P&gt;

&lt;P&gt;Since most servers don' report every day I need to search on a large timeframe (some report once a week and others once a month).&lt;/P&gt;

&lt;P&gt;The first command command that came to my mind is below:&lt;/P&gt;

&lt;P&gt;index=company_host OR index=company_network startdaysago=30 | stats distinct_count(host) by splunk_server,host&lt;/P&gt;

&lt;P&gt;It does the job but it is incredibly slow and heavy on the Splunk infrastructure.&lt;/P&gt;

&lt;P&gt;Is there any magic way to get it done faster without relying on summary indexes?&lt;/P&gt;

&lt;P&gt;Best Regards&lt;/P&gt;</description>
      <pubDate>Tue, 13 Apr 2010 10:09:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/List-all-reporting-devices-per-Splunk-server/m-p/11297#M53</guid>
      <dc:creator>rbruno7</dc:creator>
      <dc:date>2010-04-13T10:09:01Z</dc:date>
    </item>
    <item>
      <title>Re: List all reporting devices per Splunk server</title>
      <link>https://community.splunk.com/t5/Reporting/List-all-reporting-devices-per-Splunk-server/m-p/11298#M54</link>
      <description>&lt;P&gt;Just use:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| metadata type=hosts
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Unfortunately, the &lt;CODE&gt;|metadata&lt;/CODE&gt; command always runs in distributed mode and does not break out results by splunk_server, so you might have to figure out a way to run it in non-distributed mode on each individual server to get the list for each indexer.&lt;/P&gt;

&lt;P&gt;You could also just go into the &lt;CODE&gt;$SPLUNK_HOME/var/lib/splunk/defaultdb/db/&lt;/CODE&gt; directory (or wherever you keep your indexes hot/warm db) and look in the &lt;CODE&gt;Hosts.data&lt;/CODE&gt; file on each server, and repeat for each index you're interested in.&lt;/P&gt;</description>
      <pubDate>Tue, 13 Apr 2010 21:10:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/List-all-reporting-devices-per-Splunk-server/m-p/11298#M54</guid>
      <dc:creator>gkanapathy</dc:creator>
      <dc:date>2010-04-13T21:10:00Z</dc:date>
    </item>
    <item>
      <title>Re: List all reporting devices per Splunk server</title>
      <link>https://community.splunk.com/t5/Reporting/List-all-reporting-devices-per-Splunk-server/m-p/11299#M55</link>
      <description>&lt;P&gt;This was the magic answer I was looking for!&lt;BR /&gt;
Thank you!&lt;/P&gt;</description>
      <pubDate>Wed, 14 Apr 2010 00:01:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/List-all-reporting-devices-per-Splunk-server/m-p/11299#M55</guid>
      <dc:creator>rbruno7</dc:creator>
      <dc:date>2010-04-14T00:01:41Z</dc:date>
    </item>
    <item>
      <title>Re: List all reporting devices per Splunk server</title>
      <link>https://community.splunk.com/t5/Reporting/List-all-reporting-devices-per-Splunk-server/m-p/11300#M56</link>
      <description>&lt;P&gt;great answer&lt;/P&gt;</description>
      <pubDate>Mon, 26 May 2014 06:41:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/List-all-reporting-devices-per-Splunk-server/m-p/11300#M56</guid>
      <dc:creator>blebit</dc:creator>
      <dc:date>2014-05-26T06:41:41Z</dc:date>
    </item>
  </channel>
</rss>

