<?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 Extract Hostname, Date and time from the log in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Extract-Hostname-Date-and-time-from-the-log/m-p/432753#M123659</link>
    <description>&lt;P&gt;Hi all&lt;/P&gt;

&lt;P&gt;I want to extract Hostname, date and time from the log, Kindly help&lt;/P&gt;

&lt;P&gt;sample log:&lt;BR /&gt;
Mar 12 09:13:46 hostname1  &amp;lt;118&amp;gt;1 2019-03-12T09:13:46.743+00:00 ip.address&lt;/P&gt;

&lt;P&gt;Hostname    Date    Time&lt;BR /&gt;
hostname1   2019-03-12 09:13:46&lt;/P&gt;</description>
    <pubDate>Fri, 15 Mar 2019 02:14:21 GMT</pubDate>
    <dc:creator>paullt12345</dc:creator>
    <dc:date>2019-03-15T02:14:21Z</dc:date>
    <item>
      <title>Extract Hostname, Date and time from the log</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extract-Hostname-Date-and-time-from-the-log/m-p/432753#M123659</link>
      <description>&lt;P&gt;Hi all&lt;/P&gt;

&lt;P&gt;I want to extract Hostname, date and time from the log, Kindly help&lt;/P&gt;

&lt;P&gt;sample log:&lt;BR /&gt;
Mar 12 09:13:46 hostname1  &amp;lt;118&amp;gt;1 2019-03-12T09:13:46.743+00:00 ip.address&lt;/P&gt;

&lt;P&gt;Hostname    Date    Time&lt;BR /&gt;
hostname1   2019-03-12 09:13:46&lt;/P&gt;</description>
      <pubDate>Fri, 15 Mar 2019 02:14:21 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extract-Hostname-Date-and-time-from-the-log/m-p/432753#M123659</guid>
      <dc:creator>paullt12345</dc:creator>
      <dc:date>2019-03-15T02:14:21Z</dc:date>
    </item>
    <item>
      <title>Re: Extract Hostname, Date and time from the log</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extract-Hostname-Date-and-time-from-the-log/m-p/432754#M123660</link>
      <description>&lt;P&gt;Hi  @paullt12345&lt;/P&gt;

&lt;P&gt;Try like&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| makeresults 
| eval log="Mar 12 09:13:46 hostname1  &amp;lt;118&amp;gt;1 2019-03-12T09:13:46.743+00:00 ip.address" 
| rex field=log ":\d{2}\s+(?P&amp;lt;Hostname&amp;gt;.+)\s+&amp;lt;.*(?P&amp;lt;Date&amp;gt;\d{4}\-\d{2}\-\d{2})T(?P&amp;lt;Time&amp;gt;\d{2}\:\d{2}\:\d{2})"
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 15 Mar 2019 02:16:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extract-Hostname-Date-and-time-from-the-log/m-p/432754#M123660</guid>
      <dc:creator>vnravikumar</dc:creator>
      <dc:date>2019-03-15T02:16:40Z</dc:date>
    </item>
    <item>
      <title>Re: Extract Hostname, Date and time from the log</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extract-Hostname-Date-and-time-from-the-log/m-p/432755#M123661</link>
      <description>&lt;P&gt;it works.. thanks..&lt;/P&gt;</description>
      <pubDate>Fri, 15 Mar 2019 02:19:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extract-Hostname-Date-and-time-from-the-log/m-p/432755#M123661</guid>
      <dc:creator>paullt12345</dc:creator>
      <dc:date>2019-03-15T02:19:27Z</dc:date>
    </item>
  </channel>
</rss>

