Getting Data In

How to remove some event from log while indexing..

gajananh999
Contributor

Hello Everyone,

I want to remove some lines from log file while indexing the data. my log file is like

date time s-computername Client-IP cs-uri-stem cs-uri-query s-contentpath sc-status cs(Referer) sc-win32-status sc-bytes cs-bytes W3WP-PrivateBytes cs-username cs(User-Agent) time-local TimeTakenMS sc-substatus s-sitename s-ip s-port RequestsPerSecond s-proxy cs-version c-protocol cs-method cs(Host) EndRequest-UTC local date CPU-Utilization cs(Cookie) BeginRequest-UTC date BeginRequest-UTC local

10/5/2012 00:01.2 AEPLWEB2 66.249.73.41 /research/comparecars/compareAllFeatures.aspx car1=1587&car2=343&car3=&car4= E:\sites\carwale\research\comparecars\compareAllFeatures.aspx 200 - 0 8575 332 - - Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html) 30:01.2 9469 0 WWW.CARWALE.COM 192.168.1.15 80 0.9863 - HTTP/1.1 http GET www.carwale.com 10/5/2012 00:01.2 10/5/2012 59.09 - 10/5/2012 59:51.7

error..... 121

error......186

So Here i want to remove the lline which is starting with error and starting date which is first line .

Please can anybody help me on this?

Thanks

Gajanan Hiroji

Tags (1)
0 Karma

MuS
Legend

Hi gajananh999,

find all needed information and examples in the docs about Discard specific events and keep the rest.

cheers, MuS

0 Karma
Get Updates on the Splunk Community!

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...

Introducing the 2024 Splunk MVPs!

We are excited to announce the 2024 cohort of the Splunk MVP program. Splunk MVPs are passionate members of ...