Getting Data In

CHECK_FOR_HEADER identifying incorrect delimiter in CSV header

scaster
New Member

We have a system, Splunk 4.2.1 (build 98164), that scans a directory to read in CSV files, which include comma-delimited header lines.

This usually works fine, but periodically, instead of properly interpreting the header line, the CHECK_FOR_HEADER/AutoHeader function identifies a space as the delimiter, even though there are no spaces in the header line, and creates an AutoHeader in which the entire comma-delimited header is identified as one big field name:

[AutoHeader-11]
DELIMS = " "
FIELDS = "SessionID,AnalyzerIP,AnalyzerID,PopNm,TimeStamp,Date,Hour,Minute,TzOfstMins,TzDst,TzNm,TzDstNm,ClientIP,ServerIP,Protocol,Tag,TimeStampFrac,ProtocolEventID,ID,Proto,Type,Name,Class,TTL,Rdata"

The line in the file is perfectly ordinary, formatted identically to header lines that are processed correctly. In fact, earlier in transforms.conf, the exact same header is identified correctly:

[AutoHeader-7]
DELIMS = ","
FIELDS = "SessionID", "AnalyzerIP", "AnalyzerID", "PopNm", "TimeStamp", "Date", "Hour", "Minute", "TzOfstMins", "TzDst", "TzNm", "TzDstNm", "ClientIP", "ServerIP", "Protocol", "Tag", "TimeStampFrac", "ProtocolEventID", "ID", "Proto", "Type", "Name", "Class", "TTL", "Rdata"

Does anyone have any idea what could cause this?

0 Karma

ogdin
Splunk Employee
Splunk Employee

We've deprecated CHECK_FOR_HEADER in Splunk 6 and replaced it with more robust header controls. See:

http://docs.splunk.com/Documentation/Splunk/latest/Data/Extractfieldsfromfileheadersatindextime

0 Karma
Get Updates on the Splunk Community!

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...

What's new in Splunk Cloud Platform 9.1.2312?

Hi Splunky people! We are excited to share the newest updates in Splunk Cloud Platform 9.1.2312! Analysts can ...