Getting Data In

Jenkins Build logs to Splunk

Maries
Explorer

Team,

I'm trying to push Jenkins Build Logs to Splunk.

 

Installed Splunk Plugin (1.10.1) in my Cloudbees Jenkins. Configured HTTP host,  port & token - Tested Connection and it looks good.

 

In Splunk, created a HEC Input in the below file with the content as below

File name :  /opt/app/splunk/etc/apps/splunk_httpinput/local/inputs.conf

 

[http://jenkins_build_logs]

description = Jenkins build Logs

disabled = 0

index = infra

indexes = infra

sourcetype = jenkins:build

token = 

useACK = 0

 

Getting the below error in the Splunk logs - 

/opt/app/splunk/var/log/splunk

02-08-2025 04:52:07.704 +0000 ERROR HttpInputDataHandler [17467 HttpDedicatedIoThread-1] - Failed processing http input, token name=jenkins_build_logs, channel=n/a, source_IP=10.212.102.217, reply=7, status_message="Incorrect index", status=400, events_processed=1, http_input_body_size=381, parsing_err="invalid_index='jenkins_console'"

02-08-2025 04:54:14.617 +0000 ERROR HttpInputDataHandler [17467 HttpDedicatedIoThread-1] - Failed processing http input, token name=jenkins_build_logs, channel=n/a, source_IP=10.212.100.150, reply=7, status_message="Incorrect index", status=400, events_processed=1, http_input_body_size=317, parsing_err="invalid_index='jenkins_statistics'"

Labels (2)
0 Karma

kiran_panchavat
Champion

@Maries 

NOTE:  You can keep the index to the default (main, in general) or ‘jenkins’  or whatever you prefer while setting up the token, as the Splunk app for Jenkins is capable of filtering the events and redirecting them to the correct pre-configured indexes(this app ships with 

four indexes – Jenkins, Jenkins_statistics, Jenkins_console, Jenkins_artifact).

Did this help? If yes, please consider giving kudos, marking it as the solution, or commenting for clarification — your feedback keeps the community going!

Maries
Explorer

Configured as below.. Now the error is resolved - But not getting the jenkins logs into splunk . only seeing the below response in Splunk

 

Configuration : 

[http://jenkins_build_logs]

description = Jenkins build Logs

disabled = 0

sourcetype = jenkins:build

token = 

useACK = 0

 

Logs in splunk

ping from jenkins plugin raw event ping

0 Karma

kiran_panchavat
Champion

@Maries Check this 

https://plugins.jenkins.io/splunk-devops/ 

https://medium.com/cloud-native-daily/monitoring-made-easy-enhancing-ci-cd-with-splunk-and-jenkins-i... 

Did this help? If yes, please consider giving kudos, marking it as the solution, or commenting for clarification — your feedback keeps the community going!

kiran_panchavat
Champion

@MariesDid you create the index on the indexer?

Did this help? If yes, please consider giving kudos, marking it as the solution, or commenting for clarification — your feedback keeps the community going!
0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Community Content Calendar, September edition

Welcome to another insightful post from our Community Content Calendar! We're thrilled to continue bringing ...

Splunkbase Unveils New App Listing Management Public Preview

Splunkbase Unveils New App Listing Management Public PreviewWe're thrilled to announce the public preview of ...

Leveraging Automated Threat Analysis Across the Splunk Ecosystem

Are you leveraging automation to its fullest potential in your threat detection strategy?Our upcoming Security ...