<?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 create a table from syslog event? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-table-from-syslog-event/m-p/183834#M52927</link>
    <description>&lt;P&gt;Well, just as you said, a space happened and it messed up the table. See below for the raw syslog:&lt;/P&gt;

&lt;P&gt;Sep  2 07:53:25 192.168.10.18 Sep  2 07:53:24 WestAnnex1 MAC Authentication failed for [0030.a103.b3f4 ] on port 0/1/48 (Invalid User) &lt;BR /&gt;
Aug 29 13:38:49 192.168.10.18 Aug 29 13:38:49 WestAnnex1 MAC Authentication failed for [0050.b980.10c9 ] on port 0/1/47 (Invalid User)&lt;/P&gt;

&lt;P&gt;I changed the 7 to a 9 before Source and that fixed it but it will just go back when we hit Sept 10&lt;/P&gt;

&lt;P&gt;Thoughts?&lt;/P&gt;</description>
    <pubDate>Tue, 02 Sep 2014 16:07:22 GMT</pubDate>
    <dc:creator>wiredmonkey</dc:creator>
    <dc:date>2014-09-02T16:07:22Z</dc:date>
    <item>
      <title>How to create a table from syslog event?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-table-from-syslog-event/m-p/183830#M52923</link>
      <description>&lt;P&gt;I want to create a table from the following syslog entry:&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Aug 14 15:37:34 192.168.10.18 Aug 14 15:37:33 WestAnnex1 MAC Authentication failed for [0013.72eb.7330 ] on port 0/1/47 (Invalid User)&lt;/STRONG&gt; &lt;/P&gt;

&lt;P&gt;The problem I'm having is the fields I'm interested in aren't being created (I'm new to splunk, forgive me) I want the following table:&lt;/P&gt;

&lt;P&gt;Time/Date&lt;BR /&gt;
Source (WestAnnex1 for this example, maybe be able to re-label this to West Annex Switch)&lt;BR /&gt;
Mac Address (0013.72eb.7330 for this example)&lt;BR /&gt;
Port (0/1/47 for this example)&lt;/P&gt;

&lt;P&gt;Hope I'm making sense and someone can help.&lt;BR /&gt;
Thanks!&lt;/P&gt;</description>
      <pubDate>Fri, 15 Aug 2014 16:46:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-table-from-syslog-event/m-p/183830#M52923</guid>
      <dc:creator>wiredmonkey</dc:creator>
      <dc:date>2014-08-15T16:46:49Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a table from syslog event?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-table-from-syslog-event/m-p/183831#M52924</link>
      <description>&lt;P&gt;Try this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;your base search &amp;lt;&amp;lt;index=A sourcetype=B...&amp;gt;&amp;gt; | rex "(?i)^(?:[^ ]* ){7}(?P&amp;lt;Source&amp;gt;[^ ]+).*\[(?P&amp;lt;MAC_Address&amp;gt;[^\]]+)\].*\sport\s(?P&amp;lt;Port&amp;gt;[^\s]+)" | table _time Source MAC_Address Port
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Date/Time should already be extracted as _time by Splunk. &lt;/P&gt;</description>
      <pubDate>Fri, 15 Aug 2014 18:01:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-table-from-syslog-event/m-p/183831#M52924</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2014-08-15T18:01:34Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a table from syslog event?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-table-from-syslog-event/m-p/183832#M52925</link>
      <description>&lt;P&gt;That worked like charm! Thanks! &lt;/P&gt;

&lt;P&gt;I ended up doing this:&lt;/P&gt;

&lt;P&gt;index=main sourcetype=syslog mac authentication | ....&lt;/P&gt;

&lt;P&gt;One more quick question, if the source (WestAnnex1) changes, that is it says NorthAnnex1 (more characters and/or less) will I have to alter anything?&lt;/P&gt;</description>
      <pubDate>Fri, 15 Aug 2014 20:32:36 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-table-from-syslog-event/m-p/183832#M52925</guid>
      <dc:creator>wiredmonkey</dc:creator>
      <dc:date>2014-08-15T20:32:36Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a table from syslog event?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-table-from-syslog-event/m-p/183833#M52926</link>
      <description>&lt;P&gt;No don't have to, unless the value contains a space(currently I am taking all characters before a space is encountered).&lt;/P&gt;</description>
      <pubDate>Fri, 15 Aug 2014 20:39:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-table-from-syslog-event/m-p/183833#M52926</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2014-08-15T20:39:57Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a table from syslog event?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-table-from-syslog-event/m-p/183834#M52927</link>
      <description>&lt;P&gt;Well, just as you said, a space happened and it messed up the table. See below for the raw syslog:&lt;/P&gt;

&lt;P&gt;Sep  2 07:53:25 192.168.10.18 Sep  2 07:53:24 WestAnnex1 MAC Authentication failed for [0030.a103.b3f4 ] on port 0/1/48 (Invalid User) &lt;BR /&gt;
Aug 29 13:38:49 192.168.10.18 Aug 29 13:38:49 WestAnnex1 MAC Authentication failed for [0050.b980.10c9 ] on port 0/1/47 (Invalid User)&lt;/P&gt;

&lt;P&gt;I changed the 7 to a 9 before Source and that fixed it but it will just go back when we hit Sept 10&lt;/P&gt;

&lt;P&gt;Thoughts?&lt;/P&gt;</description>
      <pubDate>Tue, 02 Sep 2014 16:07:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-table-from-syslog-event/m-p/183834#M52927</guid>
      <dc:creator>wiredmonkey</dc:creator>
      <dc:date>2014-09-02T16:07:22Z</dc:date>
    </item>
  </channel>
</rss>

