Reputation: 11
I have Successfully installed Zabbix 3.2 server on ubuntu 14.0 The Z on the host is green.Unfortunately, JMX is red.
Zabbix Server : 192.168.1.112 Linux Server with tomcat : 12.8.9.20
Followed https://www.zabbix.com/forum/showpos...00&postcount=7
Step 1: Create a host or add JMX interface to existing. Step 2: Add the Zabbix agent to tomcat server (12.8.9.20) Step 3: Configure the Zabbix agent Step 4: install the Os Linux template. Step 5: On zabbix Server install zabbix-java-gateway Step 6: The following are the only 3 changes that I've made in the file /etc/zabbix/zabbix_java_gateway.conf ... LISTEN_IP="192.168.1.112" ( / Not sure about this should i keep the ip address to 127.0.0.1) LISTEN_PORT=10052 START_POLLERS=5
So the Question should i install java-gateway on tomcat machine . What other settings I have to configure ?
Upvotes: 1
Views: 9087
Reputation: 485
I have the exact same problem with the similar versions of:
And IPv4 networking:
After a lot (really a lot) of testing, googling, tcpdumping, stracing, etc, I finally change the catalina.sh
file wit this conf:
CATALINA_OPTS="$CATALINA_OPTS \
-Dcom.sun.management.jmxremote \
-Dcom.sun.management.jmxremote.port=12345 \
-Dcom.sun.management.jmxremote.ssl=false \
-Dcom.sun.management.jmxremote.authenticate=false \
-Djava.rmi.server.hostname=192.168.56.38"
Where the IP 192.168.56.38
is the tomcat IP address (not the zabbix IP address) and finally it worked!!
I went through all these links:
but all of them indicates to use the remote server address (zabbix in my case) but never worked.
I suspecteded that it was a Zabbix issue, but I could replicate the same problem with Tomcat + Remote JConsole, so it's a Java thing. I really don't understand why, but it's working with the conf mentioned
Upvotes: 2
Reputation: 9
Your configuration file says that JMX is running on port 10052. Check on which port the JMXis running and make sure that this JMX port is opened bidirectional connection with Zabbix agent and Zabbix server. If the port is not opened, request your network team to open the bidirectional connection.
Upvotes: 0
Reputation: 1
Please find the attachment of the error message. 1.) Do I have to enable this step on tomcat server which I'm trying to monitor ?
java \
-Dcom.sun.management.jmxremote \
-Dcom.sun.management.jmxremote.port=12345 \
-Dcom.sun.management.jmxremote.authenticate=false \
-Dcom.sun.management.jmxremote.ssl=false \
-jar /usr/share/doc/openjdk-6-jre-headless/demo/jfc/Notepad/Notepad.jar
2.) Do i need make any other change zabbix_agentd.conf or any other file. I change javagatewaypoll
# Size of history index cache, in bytes.
ption: StartEscalators
# Number of pre-forked instances of escalators.
#
# Mandatory: no
# Range: 0-100
# Default:
# StartEscalators=1
### Option: JavaGateway
# IP address (or hostname) of Zabbix Java gateway.
# Only required if Java pollers are started.
#
# Mandatory: no
# Default:
JavaGateway=127.0.0.1
### Option: JavaGatewayPort
# Port that Zabbix Java gateway listens on.
#
# Mandatory: no
# Range: 1024-32767
# Default:
JavaGatewayPort=10052
### Option: StartJavaPollers
# Number of pre-forked instances of Java pollers.
#
# Mandatory: no
# Range: 0-1000
# Default:
# StartJavaPollers=0
StartJavaPollers=5
### Option: StartVMwareCollectors
# Number of pre-forked vmware collector instances.
#
# Mandatory: no
# Range: 0-250
# Default:
# StartVMwareCollectors=0
### Option: VMwareFrequency
# How often Zabbix will connect to VMware service to obtain a new data.
#
# Mandatory: no
# Range: 10-86400
# Default:
# VMwareFrequency=60
### Option: VMwarePerfFrequency
# How often Zabbix will connect to VMware service to obtain performance data.
#
# Mandatory: no
# Range: 10-86400
# Default:
# VMwarePerfFrequency=60
Upvotes: 0