Getting Data In

Instruct Splunk PHP SDK to connect via HTTP not HTTPS

EricLloyd79
Builder

I am having an issue connecting to a Splunk search head with the Splunk PHP SDK:
http://x.x.x.x

I get the error below. It is attempt to connect to https://.. and then gives me an SSL error. When I attempt to connect to https://x.x.x.x through my web browser it gives me a similar error so clearly I need to connect to this search head using http, not https.
I cannot figure out how to tell the SDK to connect with http: instead of https. Help?

PHP Fatal error: Uncaught exception 'Splunk_ConnectException' with message 'SSL connect error' in /var/www/html/eventcount/src/SplunkIndexMonitor/Splunk/Splunk/Http.php:196
Stack trace:

0 /var/www/html/eventcount/src/SplunkIndexMonitor/Splunk/Splunk/Http.php(94): Splunk_Http->requestWithCurl('post', 'https://x.x.x...', Array, 'username=abc&pa...')

1 /var/www/html/eventcount/src/SplunkIndexMonitor/Splunk/Splunk/Http.php(45): Splunk_Http->request('post', 'https://x.x.x...', Array, 'username=abc&pa...')

2 /var/www/html/eventcount/src/SplunkIndexMonitor/Splunk/Splunk/Context.php(94): Splunk_Http->post('https://x.x.x...', Array)

3 /var/www/html/eventcount/src/SplunkIndexMonitor/abc-prod04-run.php(127): Splunk_Context->login()

4 {main}

thrown in /var/www/html/eventcount/src/SplunkIndexMonitor/Splunk/Splunk/Http.php on line 196

0 Karma
Get Updates on the Splunk Community!

Announcing Scheduled Export GA for Dashboard Studio

We're excited to announce the general availability of Scheduled Export for Dashboard Studio. Starting in ...

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics GA in US-AWS!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...