All Apps and Add-ons

How do I troubleshoot a problem with jmx add-on

stevedarnowsky
Engager

I am trying to use the jmx add-on with Splunk Lite.
I followed the instructions in the jmx add-on document for the configuration from the command line. Copied the inputs file from default to local folder as directed and created a config.xml file in bin/config folder as follows:
<jmxpoller>
<jmxserver pidFile="/opt/amps/sm70/instances/ndsoa01/java.pid" jvmDescription="nd01M">
<mbean domain="java.lang" properties="type=Memory">
<attribute name="NonHeapMemoryUsage:used" outputname="nonHeapUsed"/>
<attribute name="NonHeapMemoryUsage:max" outputname="nonHeapMax"/>
<attribute name="HeapMemoryUsage:used" outputname="HeapUsed"/>
<attribute name="HeapMemoryUsage:max outputname="HeapMax"/>
</mbean>
</jmxserver>
</jmxpoller>

When I restart Splunk from the web I get a mail with this message:
Unable to initialize modular input "jmx" defined inside the app "Splunk_TA_jmx": Introspecting scheme=jmx: script running failed (exited with code 1).

I tried a suggestion for troubleshooting this error message and got this result:
$SPLUNK_HOME/bin/splunk cmd $SPLUNK_HOME/bin/splunk cmd $SPLUNK_HOME/bin/python /opt/amps/splunk/etc/apps/Splunk_TA_jmx/bin/jmx.py
Conf is currently being modified by process 19088.
Conf is currently being modified by process 19088.
Conf is currently being modified by process 19088.
Conf is currently being modified by process 19088.
Conf is currently being modified by process 19088.
Conf is currently being modified by process 19088.
Traceback (most recent call last):
File "/opt/amps/splunk/etc/apps/Splunk_TA_jmx/bin/jmx.py", line 122, in <module>
Conf is currently being modified by process 19088.
token = ET.fromstring(xml_str).find('session_key').text
File "/opt/amps/splunk/lib/python2.7/xml/etree/ElementTree.py", line 1301, in XML
return parser.close()
File "/opt/amps/splunk/lib/python2.7/xml/etree/ElementTree.py", line 1654, in close
self._raiseerror(v)
File "/opt/amps/splunk/lib/python2.7/xml/etree/ElementTree.py", line 1506, in _raiseerror
raise err
xml.etree.ElementTree.ParseError: no element found: line 1, column 0

Tags (1)

harsmarvania57
Ultra Champion

Hi

Please try below troubleshooting steps:

  1. Have you installed Java Runtime Environment 1.7+ ?
  2. Can you please try to run $SPLUNK_HOME/bin/splunk cmd $SPLUNK_HOME/bin/python $SPLUNK_HOME/etc/apps/SPLUNK4JMX/bin/jmx.py --scheme . When you run this command it shows output as below, if it runs without error otherwise it will throw an error

    <scheme>
        <title>JMX (Java Management Extensions)</title>
        <description>Monitor Java Virtual Machines via their exposed JMX MBean attributes, operations and notifications</description>
    .............
    .............
                </arg>
            </args>
        </endpoint>
    </scheme>
    

Thanks,
Harshil

0 Karma

banderson7
Communicator

Did you ever get anywhere w/ this?

0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

Design, Compete, Win: Submit Your Best Splunk Dashboards for a .conf26 Pass

Hello Splunkers,  We’re excited to kick off a Splunk Dashboard contest! We know that dashboards are a primary ...

May 2026 Splunk Expert Sessions: Security & Observability

Level Up Your Operations: May 2026 Splunk Expert Sessions Whether you are refining your security posture or ...

Network to App: Observability Unlocked [May & June Series]

In today’s digital landscape, your environment is no longer confined to the data center. It spans complex ...