VISUALVM Adding remote management-centos

Source: Internet
Author: User
Tags visualvm

1. Modify the catalina.sh file in the Tomcat/bin directory

Java_opts= "$JAVA _opts-djava.rmi.server.hostname=${host_ip}
-dcom.sun.management.jmxremote.port=9999
-dcom.sun.management.jmxremote.ssl=false
-dcom.sun.management.jmxremote.authenticate=false "

Restart Tomcat. It is necessary to ensure that the added port is not occupied by other services. Method: NETSTAT-TLNP | grep 9999.

2. Open VISUALVM to add a new target host by remote. Right-click the added target host and add the JMX connection. Add 9999 to the.

Trouble Shoot the wrong line

If the connection does not occur. Check that the ports are open first.

Telnet HOST_IP 9999 will prompt connect refused if it is not open.

If not open. You need to edit iptables to open it.

/sbin/iptables-i input-p TCP--dport 8000-j ACCEPT #开启8000端口

/etc/rc.d/init.d/iptables Save #保存配置

/etc/rc.d/init.d/iptables Restart #重启服务

See if the port is open

Service Iptables Status

If it is not open, enter

/sbin/iptables-i input-p TCP--dport 9999-j ACCEPT #开启9999 TCP port

Service Iptables Save #保存配置

Service iptables Restart #重启服务

If the iptables is still invalid after editing. Iptables can be closed first

Service Iptables stop shutdown

Service Iptables Start

VISUALVM Adding remote management-centos

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.