Getting Data In

Failed to receive logs from Docker with Splunk Logging Driver

xzou_splunk
Splunk Employee
Splunk Employee

Hi all,

I followed the instruction in https://github.com/splunk/docker-logging-plugin to install the log driver, and also setup the HEC in Splunk.
Tried following:
1. docker run --publish 4000:80 --log-driver=splunk-logging-plugin --log-opt splunk-token=xxxxx --log-opt splunk-url=https://127.0.0.1:8088 xxxx; No logs in Splunk
2. Change docker daemon as
{
"debug" : true,
"experimental" : false,
"log-driver": "splunk-logging-plugin",
"log-opts": {
"splunk-token": "xxxxxx",
"splunk-url": "https://127.0.0.1:8088",
"splunk-insecureskipverify": "true"
}
}
No logs in Splunk
3. curl -k https://127.0.0.1:8088/services/collector/event -H "Authorization: Splunk xxxxxx" -d '{"event": "hello world"}'
Receive return meg: {"text": "Success", "code": 0}, and got logs in Splunk

Any advice where is the problem or how should I debug this?

Thanks.

0 Karma
Get Updates on the Splunk Community!

Introducing the Splunk Community Dashboard Challenge!

Welcome to Splunk Community Dashboard Challenge! This is your chance to showcase your skills in creating ...

Built-in Service Level Objectives Management to Bridge the Gap Between Service & ...

Wednesday, May 29, 2024  |  11AM PST / 2PM ESTRegister now and join us to learn more about how you can ...

Get Your Exclusive Splunk Certified Cybersecurity Defense Engineer Certification at ...

We’re excited to announce a new Splunk certification exam being released at .conf24! If you’re headed to Vegas ...