agebhar1 / jvmtop

Automatically exported from code.google.com/p/jvmtop
0 stars 0 forks source link

ERROR: Connection refused/access denied #56

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
# cat /etc/SuSE-release
SUSE Linux Enterprise Server 11 (x86_64)
VERSION = 11
PATCHLEVEL = 0

# java -version
java version "1.6.0_45"
Java(TM) SE Runtime Environment (build 1.6.0_45-b06)
Java HotSpot(TM) 64-Bit Server VM (build 20.45-b01, mixed mode)

# echo $JAVA_HOME
/home/app_env_1/app/Java/jdk1.6.0_45/

# ./jvmtop.sh --once --verbose
Sep 30, 2014 12:28:59 PM com.jvmtop.JvmTop main
FINE: Verbosity mode.
Sep 30, 2014 12:29:00 PM com.jvmtop.monitor.VMInfo attachToVM
FINE: connection refused (PID=25393)
java.rmi.ConnectException: Connection refused to host: 10.249.140.239; nested 
exception is:
        java.net.ConnectException: Connection refused
        at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:601)
        at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:198)
        at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:184)
        at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:110)
        at javax.management.remote.rmi.RMIServerImpl_Stub.newClient(Unknown Source)
        at javax.management.remote.rmi.RMIConnector.getConnection(RMIConnector.java:2327)
        at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:277)
        at javax.management.remote.JMXConnectorFactory.connect(JMXConnectorFactory.java:248)
        at javax.management.remote.JMXConnectorFactory.connect(JMXConnectorFactory.java:207)
        at com.jvmtop.openjdk.tools.ProxyClient.tryConnect(Unknown Source)
        at com.jvmtop.openjdk.tools.ProxyClient.connect(Unknown Source)
        at com.jvmtop.monitor.VMInfo.attachToVM(Unknown Source)
        at com.jvmtop.monitor.VMInfo.processNewVM(Unknown Source)
        at com.jvmtop.view.VMOverviewView.scanForNewVMs(Unknown Source)
        at com.jvmtop.view.VMOverviewView.printView(Unknown Source)
        at com.jvmtop.JvmTop.run(Unknown Source)
        at com.jvmtop.JvmTop.main(Unknown Source)
Caused by: java.net.ConnectException: Connection refused
        at java.net.PlainSocketImpl.socketConnect(Native Method)
        at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:351)
        at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:213)
        at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:200)
        at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
        at java.net.Socket.connect(Socket.java:529)
        at java.net.Socket.connect(Socket.java:478)
        at java.net.Socket.<init>(Socket.java:375)
        at java.net.Socket.<init>(Socket.java:189)
        at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:22)
        at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(RMIMasterSocketFactory.java:128)
        at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:595)
        ... 16 more
 JvmTop 0.8.0 alpha - 12:28:59,  amd64,  2 cpus, Linux 2.6.27.19, load avg 0.03
 http://code.google.com/p/jvmtop

  PID MAIN-CLASS      HPCUR HPMAX NHCUR NHMAX    CPU     GC    VM USERNAME   #T DL
14392 m.jvmtop.JvmTop   12m 1747m   10m  130m 57.69%  0.00% S6U45     root   13
25393 artup.Bootstrap [ERROR: Connection refused/access denied]

 # ps aux | grep tomcat | grep -v grep
1001     25393  1.2 16.1 2801376 1299808 pts/9 Sl   Sep15 276:12 
/home/app_env_1/APP/Java/jdk1.6.0_45/jre/bin/java 
-Djava.util.logging.config.file=/home/app_env_1/APP/app-manager/conf/server/logg
ing.properties 
-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager 
-Dapp.conf=/home/app_env_1/APP/app-manager/conf -server -Xms1G -Xmx1G 
-XX:+UseCodeCacheFlushing -XX:ReservedCodeCacheSize=64M 
-XX:+HeapDumpOnOutOfMemoryError -XX:MaxPermSize=1024M 
-Djavax.net.debug=ssl,handshake -Dcom.sun.management.jmxremote 
-Dcom.sun.management.jmxremote.port=8004 
-Dcom.sun.management.jmxremote.authenticate=false 
-Dcom.sun.management.jmxremote.ssl=false 
-Djava.rmi.server.hostname=10.249.140.239 -Denv=KIEV_DEV 
-Doutput.dir=/home/app_env_1/APP/logs 
-Dapp.app=/home/app_env_1/APP/app-application 
-Dapp.conf=/home/app_env_1/app/limits-manager/conf -Dapp.version=4.7.0.qa.99 
-Djava.endorsed.dirs=/home/app_env_1/app/app-server/common/endorsed -classpath 
/home/app_env_1/APP/app-server/bin/bootstrap.jar:/home/app_env_1/APP/app-server/
bin/tomcat-juli.jar -Dcatalina.base=/home/app_env_1/APP/app-server 
-Dcatalina.home=/home/app_env_1/APP/app-server 
-Djava.io.tmpdir=/home/app_env_1/APP/app-server/temp 
org.apache.catalina.startup.Bootstrap -config 
/home/app_env_1/APP/app-manager/conf/server/server.xml start

Tomcat version 5.5.23 (yes, I know it is too old, but we must use it).
jvmtop 0.8.0

Same error if run jvmtop under Tomcat's user:

$ id
uid=1001(app_env_1)

$ ./jvmtop.sh --once --verbose
Sep 30, 2014 12:36:38 PM com.jvmtop.JvmTop main
FINE: Verbosity mode.
Sep 30, 2014 12:36:39 PM com.jvmtop.monitor.VMInfo attachToVM
FINE: connection refused (PID=25393)
java.rmi.ConnectException: Connection refused to host: 10.249.140.239; nested 
exception is:
        java.net.ConnectException: Connection refused
        at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:601)
        at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:198)
        at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:184)
        at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:110)
        at javax.management.remote.rmi.RMIServerImpl_Stub.newClient(Unknown Source)
        at javax.management.remote.rmi.RMIConnector.getConnection(RMIConnector.java:2327)
        at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:277)
        at javax.management.remote.JMXConnectorFactory.connect(JMXConnectorFactory.java:248)
        at javax.management.remote.JMXConnectorFactory.connect(JMXConnectorFactory.java:207)
        at com.jvmtop.openjdk.tools.ProxyClient.tryConnect(Unknown Source)
        at com.jvmtop.openjdk.tools.ProxyClient.connect(Unknown Source)
        at com.jvmtop.monitor.VMInfo.attachToVM(Unknown Source)
        at com.jvmtop.monitor.VMInfo.processNewVM(Unknown Source)
        at com.jvmtop.view.VMOverviewView.scanForNewVMs(Unknown Source)
        at com.jvmtop.view.VMOverviewView.printView(Unknown Source)
        at com.jvmtop.JvmTop.run(Unknown Source)
        at com.jvmtop.JvmTop.main(Unknown Source)
Caused by: java.net.ConnectException: Connection refused
        at java.net.PlainSocketImpl.socketConnect(Native Method)
        at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:351)
        at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:213)
        at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:200)
        at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
        at java.net.Socket.connect(Socket.java:529)
        at java.net.Socket.connect(Socket.java:478)
        at java.net.Socket.<init>(Socket.java:375)
        at java.net.Socket.<init>(Socket.java:189)
        at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:22)
        at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(RMIMasterSocketFactory.java:128)
        at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:595)
        ... 16 more
 JvmTop 0.8.0 alpha - 12:36:38,  amd64,  2 cpus, Linux 2.6.27.19, load avg 0.03
 http://code.google.com/p/jvmtop

  PID MAIN-CLASS      HPCUR HPMAX NHCUR NHMAX    CPU     GC    VM USERNAME   #T DL
14520 m.jvmtop.JvmTop    7m 1747m   10m  130m 80.65%  0.00% S6U45 lmt_env_   13
25393 artup.Bootstrap [ERROR: Connection refused/access denied]

User's Java:

 $ echo $JAVA_HOME
/home/app_env_1/LMS/Java/jdk1.6.0_45/

root's Java:

# echo $JAVA_HOME
/home/app_env_1/LMS/Java/jdk1.6.0_45/

Original issue reported on code.google.com by setev...@gmail.com on 30 Sep 2014 at 9:40

GoogleCodeExporter commented 9 years ago
Hi,
please check the 2nd question of the FAQ:
https://code.google.com/p/jvmtop/wiki/FAQ

If you answer all bullets with "yes", please let me know.

Original comment by patric.r...@gmail.com on 16 Feb 2015 at 4:27