<?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 Simplifying event displays in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Simplifying-event-displays/m-p/62859#M180235</link>
    <description>&lt;HR /&gt;

&lt;P&gt;Hi there,&lt;/P&gt;

&lt;P&gt;I have XML logs that I bring into spunk.  Unfortunately, there is far too much not required information for me to go through,&lt;/P&gt;

&lt;P&gt;eg, an event will contain,&lt;/P&gt;

&lt;P&gt;2   12/12/12 3:53:39.945 PM &lt;BR /&gt;
&lt;RECORD&gt;&lt;DATE&gt;2012.12.12 20:53:39.945 GMT&lt;/DATE&gt;&lt;MILLIS&gt;1355345619945&lt;/MILLIS&gt;&lt;TIMEZONE&gt;America/New_York&lt;/TIMEZONE&gt;&lt;TIMEZONEOFFSET&gt;0&lt;/TIMEZONEOFFSET&gt;&lt;SYNCDATE&gt;2012.12.12 20:53:39.945 GMT&lt;/SYNCDATE&gt;&lt;SYNCMILLIS&gt;1355345619945&lt;/SYNCMILLIS&gt;&lt;SEQUENCE&gt;46985&lt;/SEQUENCE&gt;&lt;HOSTNAME&gt;burl-cap2&lt;/HOSTNAME&gt;&lt;PID&gt;8996&lt;/PID&gt;&lt;PROCNAME&gt;AvidLicenseService&lt;/PROCNAME&gt;&lt;LEVEL&gt;FINER&lt;/LEVEL&gt;&lt;MESSAGE&gt;Doing Overdue Cleanup task...&lt;/MESSAGE&gt;&lt;THREAD&gt;42&lt;/THREAD&gt;&lt;THREADNAME&gt;Overdue Cleanup Thread&lt;/THREADNAME&gt;&lt;LOGGER&gt;com.avid.workgroup.license.service.provider.behavior&lt;/LOGGER&gt;&lt;CLASS&gt;com.avid.workgroup.license.service.provider.behavior.LicenseRequest$OverdueCleanupTask&lt;/CLASS&gt;&lt;METHOD&gt;run&lt;/METHOD&gt;&lt;/RECORD&gt;&lt;/P&gt;

&lt;P&gt;I really want to filter it down to &lt;/P&gt;

&lt;P&gt;2012.12.12 20:53:39.945 GMT&lt;HOSTNAME&gt;burl-cap2&lt;PROCNAME&gt;AvidLicenseService&lt;LEVEL&gt;FINER&lt;MESSAGE&gt;Doing Overdue Cleanup task...&amp;lt;&lt;LOGGER&gt;com.avid.workgroup.license.service.provider.behavior&lt;/LOGGER&gt;&lt;CLASS&gt;com.avid.workgroup.license.service.provider.behavior.LicenseRequest$OverdueCleanupTask&amp;lt;    &lt;/CLASS&gt;&lt;/MESSAGE&gt;&lt;/LEVEL&gt;&lt;/PROCNAME&gt;&lt;/HOSTNAME&gt;&lt;/P&gt;

&lt;P&gt;As you can see, a lot less detail.&lt;/P&gt;

&lt;P&gt;Anyone have any ideas - thanks&lt;/P&gt;</description>
    <pubDate>Thu, 13 Dec 2012 18:47:50 GMT</pubDate>
    <dc:creator>rdb_splunk</dc:creator>
    <dc:date>2012-12-13T18:47:50Z</dc:date>
    <item>
      <title>Simplifying event displays</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Simplifying-event-displays/m-p/62859#M180235</link>
      <description>&lt;HR /&gt;

&lt;P&gt;Hi there,&lt;/P&gt;

&lt;P&gt;I have XML logs that I bring into spunk.  Unfortunately, there is far too much not required information for me to go through,&lt;/P&gt;

&lt;P&gt;eg, an event will contain,&lt;/P&gt;

&lt;P&gt;2   12/12/12 3:53:39.945 PM &lt;BR /&gt;
&lt;RECORD&gt;&lt;DATE&gt;2012.12.12 20:53:39.945 GMT&lt;/DATE&gt;&lt;MILLIS&gt;1355345619945&lt;/MILLIS&gt;&lt;TIMEZONE&gt;America/New_York&lt;/TIMEZONE&gt;&lt;TIMEZONEOFFSET&gt;0&lt;/TIMEZONEOFFSET&gt;&lt;SYNCDATE&gt;2012.12.12 20:53:39.945 GMT&lt;/SYNCDATE&gt;&lt;SYNCMILLIS&gt;1355345619945&lt;/SYNCMILLIS&gt;&lt;SEQUENCE&gt;46985&lt;/SEQUENCE&gt;&lt;HOSTNAME&gt;burl-cap2&lt;/HOSTNAME&gt;&lt;PID&gt;8996&lt;/PID&gt;&lt;PROCNAME&gt;AvidLicenseService&lt;/PROCNAME&gt;&lt;LEVEL&gt;FINER&lt;/LEVEL&gt;&lt;MESSAGE&gt;Doing Overdue Cleanup task...&lt;/MESSAGE&gt;&lt;THREAD&gt;42&lt;/THREAD&gt;&lt;THREADNAME&gt;Overdue Cleanup Thread&lt;/THREADNAME&gt;&lt;LOGGER&gt;com.avid.workgroup.license.service.provider.behavior&lt;/LOGGER&gt;&lt;CLASS&gt;com.avid.workgroup.license.service.provider.behavior.LicenseRequest$OverdueCleanupTask&lt;/CLASS&gt;&lt;METHOD&gt;run&lt;/METHOD&gt;&lt;/RECORD&gt;&lt;/P&gt;

&lt;P&gt;I really want to filter it down to &lt;/P&gt;

&lt;P&gt;2012.12.12 20:53:39.945 GMT&lt;HOSTNAME&gt;burl-cap2&lt;PROCNAME&gt;AvidLicenseService&lt;LEVEL&gt;FINER&lt;MESSAGE&gt;Doing Overdue Cleanup task...&amp;lt;&lt;LOGGER&gt;com.avid.workgroup.license.service.provider.behavior&lt;/LOGGER&gt;&lt;CLASS&gt;com.avid.workgroup.license.service.provider.behavior.LicenseRequest$OverdueCleanupTask&amp;lt;    &lt;/CLASS&gt;&lt;/MESSAGE&gt;&lt;/LEVEL&gt;&lt;/PROCNAME&gt;&lt;/HOSTNAME&gt;&lt;/P&gt;

&lt;P&gt;As you can see, a lot less detail.&lt;/P&gt;

&lt;P&gt;Anyone have any ideas - thanks&lt;/P&gt;</description>
      <pubDate>Thu, 13 Dec 2012 18:47:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Simplifying-event-displays/m-p/62859#M180235</guid>
      <dc:creator>rdb_splunk</dc:creator>
      <dc:date>2012-12-13T18:47:50Z</dc:date>
    </item>
    <item>
      <title>Re: Simplifying event displays</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Simplifying-event-displays/m-p/62860#M180236</link>
      <description>&lt;P&gt;Yep.&lt;/P&gt;

&lt;P&gt;You can write a sed filter to alter the event before its indexed.&lt;BR /&gt;
I assume this is what you want.&lt;BR /&gt;
DISCLAIMER - the original event is lost for good, you can't get back the data you strip out.&lt;/P&gt;

&lt;P&gt;Put this in your props.conf under a stanza that represents this sourcetype/source/whatever&lt;/P&gt;

&lt;P&gt;change 'date|hostname|level|message' to be the list of fields you want to keep.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;SEDCMD-reduce_xml = s/(?:(?!&amp;lt;record&amp;gt;)&amp;lt;((?!(?:date|hostname|level|message)&amp;gt;)[^&amp;gt;]+)&amp;gt;.*?&amp;lt;\/\1&amp;gt;)|&amp;lt;\/?record&amp;gt;//g
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;You'll need to restart splunk for the change to take effect&lt;/P&gt;</description>
      <pubDate>Thu, 13 Dec 2012 22:20:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Simplifying-event-displays/m-p/62860#M180236</guid>
      <dc:creator>jonuwz</dc:creator>
      <dc:date>2012-12-13T22:20:19Z</dc:date>
    </item>
    <item>
      <title>Re: Simplifying event displays</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Simplifying-event-displays/m-p/62861#M180237</link>
      <description>&lt;P&gt;If you're just doing this because you want to browse through events more easily and don't want to actually lose any data, another route you could take is to extract the XML values to fields (have a look at the &lt;CODE&gt;xmlkv&lt;/CODE&gt; and &lt;CODE&gt;spath&lt;/CODE&gt; commands), and then use &lt;CODE&gt;table&lt;/CODE&gt; to show only the fields in the XML events that you're interested in.&lt;/P&gt;</description>
      <pubDate>Thu, 13 Dec 2012 22:27:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Simplifying-event-displays/m-p/62861#M180237</guid>
      <dc:creator>Ayn</dc:creator>
      <dc:date>2012-12-13T22:27:08Z</dc:date>
    </item>
  </channel>
</rss>

