Deployment Architecture

Splunk Error on Start When Configuring to Use CORS

jscraig2006
Communicator

Hi,

we have an API that we are starting to send data to HEC. When I place 

 

 

[httpServer]
crossOriginSharingHeaders = "http://<FQDN>:<PORT>"

 

 

in the server.conf under /etc/system/local, I get an error upon restarting Splunk. 

 

Checking prerequisites...
Checking http port [8000]: open
Checking mgmt port [8089]: open
Checking appserver port [127.0.0.1:8065]: open
Checking kvstore port [8191]: open
Traceback (most recent call last):
File "/opt/splunk/lib/python3.7/site-packages/splunk/clilib/cli.py", line 39, in <module>
from splunk.rcUtils import makeRestCall, CliArgError, NoEndpointError, InvalidStatusCodeError
File "/opt/splunk/lib/python3.7/site-packages/splunk/rcUtils.py", line 17, in <module>
from splunk.search import dispatch, getJob, listJobs
File "/opt/splunk/lib/python3.7/site-packages/splunk/search/__init__.py", line 2238, in <module>
TEST_NAMESPACE = splunk.getDefault('namespace')
File "/opt/splunk/lib/python3.7/site-packages/splunk/__init__.py", line 79, in getDefault
setDefault()
File "/opt/splunk/lib/python3.7/site-packages/splunk/__init__.py", line 66, in setDefault
getLocalServerInfo()
File "/opt/splunk/lib/python3.7/site-packages/splunk/__init__.py", line 36, in getLocalServerInfo
mergeHostPath(hostpath, True)
File "/opt/splunk/lib/python3.7/site-packages/splunk/__init__.py", line 136, in mergeHostPath
setDefault('port', int(port))
ValueError: invalid literal for int() with base 10: '4200""\nhttps://127.0.0.1:8089'

What would cause Splunk from starting?

Thanks in advince,

~John

Labels (1)
0 Karma
1 Solution

jscraig2006
Communicator

ok I figured it out.. It does not like the quotes around the hostname. After removing them, Splunk was able to restart. 

View solution in original post

0 Karma

jscraig2006
Communicator

ok I figured it out.. It does not like the quotes around the hostname. After removing them, Splunk was able to restart. 

0 Karma
Get Updates on the Splunk Community!

Last Chance to Submit Your Paper For BSides Splunk - Deadline is August 12th!

Hello everyone! Don't wait to submit - The deadline is August 12th! We have truly missed the community so ...

Ready, Set, SOAR: How Utility Apps Can Up Level Your Playbooks!

 WATCH NOW Powering your capabilities has never been so easy with ready-made Splunk® SOAR Utility Apps. Parse ...

DevSecOps: Why You Should Care and How To Get Started

 WATCH NOW In this Tech Talk we will talk about what people mean by DevSecOps and deep dive into the different ...