All Apps and Add-ons

Splunk DB Connect - KeyError 'Elements' on setup

ezempel
Path Finder

I just installed a new copy of splunk and immediately installed the DB Connect app after initial setup. I am getting an Error 500: KeyError 'Elements' when I try to go through the setup the first time.

1 Solution

ezempel
Path Finder

Java Runtime Environment was not installed. Turns out it is not installed by default on OSX 10.8. To install, run the following command:

Java -version

This will result in a prompt to install Java.

I found this by combing the internal splunk log:

04-23-2013 16:40:53.648 -0400 ERROR AdminManager - Stack trace from python handler:\nTraceback (most recent call last):\n  File "/Applications/Splunk/lib/python2.7/site-packages/splunk/admin.py", line 70, in init\n    hand.execute(info)\n  File "/Applications/Splunk/lib/python2.7/site-packages/splunk/admin.py", line 488, in execute\n    if self.requestedAction == ACTION_LIST:     self.handleList(confInfo)\n  File "/Applications/Splunk/etc/apps/dbx/bin/spp/config.py", line 289, in handleList\n    self.process_list(output)\n  File "/Applications/Splunk/etc/apps/dbx/bin/rest_handler_dbx_setup.py", line 32, in process_list\n    output['java']['home'] = spp.java.autodetect_java_home()\n  File "/Applications/Splunk/etc/apps/dbx/bin/spp/java/__init__.py", line 185, in autodetect_java_home\n    return autodetect_java_home_osx()\n  File "/Applications/Splunk/etc/apps/dbx/bin/spp/java/__init__.py", line 197, in autodetect_java_home_osx\n    v = get_java_version(path)\n  File "/Applications/Splunk/etc/apps/dbx/bin/spp/java/__init__.py", line 172, in get_java_version\n    return JavaEnv(java_home=java_home).get_version(overrideOpts = overrideOpts)\n  File "/Applications/Splunk/etc/apps/dbx/bin/spp/java/__init__.py", line 59, in __init__\n    raise JavaVersionException("JAVA_HOME directory %s does not exist" % JAVA_HOME)\nJavaVersionException: JAVA_HOME directory /System/Library/Frameworks/JavaVM.framework/Home does not exist\n

View solution in original post

ezempel
Path Finder

Java Runtime Environment was not installed. Turns out it is not installed by default on OSX 10.8. To install, run the following command:

Java -version

This will result in a prompt to install Java.

I found this by combing the internal splunk log:

04-23-2013 16:40:53.648 -0400 ERROR AdminManager - Stack trace from python handler:\nTraceback (most recent call last):\n  File "/Applications/Splunk/lib/python2.7/site-packages/splunk/admin.py", line 70, in init\n    hand.execute(info)\n  File "/Applications/Splunk/lib/python2.7/site-packages/splunk/admin.py", line 488, in execute\n    if self.requestedAction == ACTION_LIST:     self.handleList(confInfo)\n  File "/Applications/Splunk/etc/apps/dbx/bin/spp/config.py", line 289, in handleList\n    self.process_list(output)\n  File "/Applications/Splunk/etc/apps/dbx/bin/rest_handler_dbx_setup.py", line 32, in process_list\n    output['java']['home'] = spp.java.autodetect_java_home()\n  File "/Applications/Splunk/etc/apps/dbx/bin/spp/java/__init__.py", line 185, in autodetect_java_home\n    return autodetect_java_home_osx()\n  File "/Applications/Splunk/etc/apps/dbx/bin/spp/java/__init__.py", line 197, in autodetect_java_home_osx\n    v = get_java_version(path)\n  File "/Applications/Splunk/etc/apps/dbx/bin/spp/java/__init__.py", line 172, in get_java_version\n    return JavaEnv(java_home=java_home).get_version(overrideOpts = overrideOpts)\n  File "/Applications/Splunk/etc/apps/dbx/bin/spp/java/__init__.py", line 59, in __init__\n    raise JavaVersionException("JAVA_HOME directory %s does not exist" % JAVA_HOME)\nJavaVersionException: JAVA_HOME directory /System/Library/Frameworks/JavaVM.framework/Home does not exist\n

splunkIT
Splunk Employee
Splunk Employee

When specifying java home, make sure path does not include bin directory.

Incorrect java home path:
/usr/lib/jvm/java-1.7.0-openjdk-1.7.0.71.x86_64/jre/bin

Correct java home path:
/usr/lib/jvm/java-1.7.0-openjdk-1.7.0.71.x86_64/jre/

chrisboy68
Contributor

I'm struggling figuring this out on Yosemite. I did the below, but it does not work. Any ideas?

[java]
home = /usr/bin/java

Thank you,

Chris

0 Karma

chrisboy68
Contributor

Figured it out for anyone else out there:

Here is the path that worked for me in Yosemite.

/Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home/bin/java

Thanks

Chris

0 Karma
Get Updates on the Splunk Community!

Detecting Remote Code Executions With the Splunk Threat Research Team

REGISTER NOWRemote code execution (RCE) vulnerabilities pose a significant risk to organizations. If ...

Observability | Use Synthetic Monitoring for Website Metadata Verification

If you are on Splunk Observability Cloud, you may already have Synthetic Monitoringin your observability ...

More Ways To Control Your Costs With Archived Metrics | Register for Tech Talk

Tuesday, May 14, 2024  |  11AM PT / 2PM ET Register to Attend Join us for this Tech Talk and learn how to ...