<?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 to insert host name into event in All Apps and Add-ons</title>
    <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29119#M1021</link>
    <description>&lt;P&gt;Did you ever get this resolved?  Have the same challenge and am not finding a solution&lt;/P&gt;</description>
    <pubDate>Thu, 14 Jul 2016 16:44:37 GMT</pubDate>
    <dc:creator>tlmayes</dc:creator>
    <dc:date>2016-07-14T16:44:37Z</dc:date>
    <item>
      <title>How to insert host name into event</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29113#M1015</link>
      <description>&lt;P&gt;I have a real need to insert a hostname into an event at collection\index time not at search time.  Seeing that most of the IP's that I'm looking to resolve to hostnames change very frequently I need to capture the hostname and include it in the event when it is indexed.  Does anyone know a way to do that?  I looked at these articles but they don't seem to be helpful to do it at index time.  &lt;/P&gt;

&lt;P&gt;So basically a quick reverse DNS lookup and insert it into the event as a "hostname" field would be perfect.  This will allow me to follow specific hosts and have information on every IP that host had.&lt;/P&gt;

&lt;OL&gt;
&lt;LI&gt;&lt;A href="http://splunk-base.splunk.com/answers/1884/lookups-using-them-to-replace-the-host-field"&gt;http://splunk-base.splunk.com/answers/1884/lookups-using-them-to-replace-the-host-field&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;A href="http://splunk-base.splunk.com/answers/27840/ip-address-vs-hostname"&gt;http://splunk-base.splunk.com/answers/27840/ip-address-vs-hostname&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;A href="http://blogs.splunk.com/2009/12/15/reverse-dns-lookups-for-host-entries/"&gt;http://blogs.splunk.com/2009/12/15/reverse-dns-lookups-for-host-entries/&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;A href="http://splunk-base.splunk.com/answers/61853/resolve-ip-address"&gt;http://splunk-base.splunk.com/answers/61853/resolve-ip-address&lt;/A&gt;&lt;/LI&gt;
&lt;/OL&gt;

&lt;P&gt;Thanks,&lt;BR /&gt;
-Ben&lt;/P&gt;</description>
      <pubDate>Thu, 08 Aug 2013 14:51:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29113#M1015</guid>
      <dc:creator>benspader</dc:creator>
      <dc:date>2013-08-08T14:51:39Z</dc:date>
    </item>
    <item>
      <title>Re: How to insert host name into event</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29114#M1016</link>
      <description>&lt;P&gt;In inputs.conf using connection_host = dns doesn't work for you?&lt;/P&gt;

&lt;P&gt;This should set the host to the reverse DNS of the computer sending you data.&lt;/P&gt;</description>
      <pubDate>Thu, 08 Aug 2013 14:56:36 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29114#M1016</guid>
      <dc:creator>krugger</dc:creator>
      <dc:date>2013-08-08T14:56:36Z</dc:date>
    </item>
    <item>
      <title>Re: How to insert host name into event</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29115#M1017</link>
      <description>&lt;P&gt;But doesn't that just give me the hostname of the computer that is sending me data?  I would like hostname of the src_IP seen within the event, this will be different than the computer\appliance sending me the data.&lt;/P&gt;</description>
      <pubDate>Thu, 08 Aug 2013 15:01:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29115#M1017</guid>
      <dc:creator>benspader</dc:creator>
      <dc:date>2013-08-08T15:01:39Z</dc:date>
    </item>
    <item>
      <title>Re: How to insert host name into event</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29116#M1018</link>
      <description>&lt;P&gt;Hi, did you find out how to do this? I'm having the same requirement.&lt;/P&gt;</description>
      <pubDate>Tue, 18 Aug 2015 00:10:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29116#M1018</guid>
      <dc:creator>cespinoz</dc:creator>
      <dc:date>2015-08-18T00:10:42Z</dc:date>
    </item>
    <item>
      <title>Re: How to insert host name into event</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29117#M1019</link>
      <description>&lt;P&gt;This is a 2-step process, because there are limited things you can do at index time and because we want to do as little as possible during index time for optimal performance. So without further ado, here goes:&lt;/P&gt;

&lt;OL&gt;
&lt;LI&gt;Rewrite the host field using the source IP in your event --&amp;gt; 
transforms.conf:&lt;BR /&gt;
REGEX = ^\w{3}\s+\d+\s+[\d:]{8}\s+(\S+)
DEST_KEY = MetaData:Host
FORMAT = host::$1

&lt;OL&gt;
&lt;LI&gt;Create a lookup of ips to hostnames using a saved search to be run at scheduled intervals: &lt;A href="http://docs.splunk.com/Documentation/Splunk/latest/Knowledge/Addfieldsfromexternaldatasources?r=searchtip#Use_search_results_to_populate_a_lookup_table"&gt;http://docs.splunk.com/Documentation/Splunk/latest/Knowledge/Addfieldsfromexternaldatasources?r=searchtip#Use_search_results_to_populate_a_lookup_table&lt;/A&gt;&lt;/LI&gt;
&lt;/OL&gt;&lt;/LI&gt;
&lt;/OL&gt;</description>
      <pubDate>Tue, 18 Aug 2015 19:00:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29117#M1019</guid>
      <dc:creator>mreynov_splunk</dc:creator>
      <dc:date>2015-08-18T19:00:27Z</dc:date>
    </item>
    <item>
      <title>Re: How to insert host name into event</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29118#M1020</link>
      <description>&lt;P&gt;I tried this method, doesn't take into consideration dynamic IP addressing (DHCP Scope) - I need the dns entry to be added at the time of index and remain fixed. Anyone else found a way around this? I assume it is possible to add a field at index time from a external dns lookup but haven't found a way to implement it....&lt;/P&gt;</description>
      <pubDate>Tue, 03 May 2016 22:41:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29118#M1020</guid>
      <dc:creator>LewisWheeler</dc:creator>
      <dc:date>2016-05-03T22:41:59Z</dc:date>
    </item>
    <item>
      <title>Re: How to insert host name into event</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29119#M1021</link>
      <description>&lt;P&gt;Did you ever get this resolved?  Have the same challenge and am not finding a solution&lt;/P&gt;</description>
      <pubDate>Thu, 14 Jul 2016 16:44:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29119#M1021</guid>
      <dc:creator>tlmayes</dc:creator>
      <dc:date>2016-07-14T16:44:37Z</dc:date>
    </item>
    <item>
      <title>Re: How to insert host name into event</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29120#M1022</link>
      <description>&lt;P&gt;Nope - I was told its not possible. Only way to do it would be to get the forwarder to grab the host name and send it across as part of the event. Didn't end up doing it that way though.&lt;/P&gt;</description>
      <pubDate>Fri, 15 Jul 2016 08:15:20 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-insert-host-name-into-event/m-p/29120#M1022</guid>
      <dc:creator>LewisWheeler</dc:creator>
      <dc:date>2016-07-15T08:15:20Z</dc:date>
    </item>
  </channel>
</rss>

