M.ES
M.ES

Reputation: 940

RMI registry Remote Exception Error

I am runing JBoss AS 5 on Unix. I want to start visualGC remotely from windows 7.

First, I have create an RMI Registry on port 31111 -because the RMI registery default port was busy- using the command rmiregistry 31111 &.

Second, I tried to start a jstatd server using the command jstatd -p 8725 -J-Djava.security.policy=/app/home/user/jstatd.policy.

Third, I started the Jboss Server.

Fourth, I got the process id of the server which is 9740.

Last, I returned to windows 7 and I tried to run this command visualgc [email protected]:31111.Unfortunately it returned with the following error:

Remote Exception attaching to rmi://[email protected]:31111

Can you please explain to me what I am doing wrong?

Thanks in advance.

Upvotes: 0

Views: 1815

Answers (3)

heikki
heikki

Reputation: 31

Maybe you need to provide java.rmi.server.hostname property to jstatd. Like so:

jstatd -p 8725 -J-Djava.security.policy=/app/home/user/jstatd.policy -J-Djava.rmi.server.hostname=XX.XXX.X.XX

See RMI RemoteException for details.

Upvotes: 3

M.ES
M.ES

Reputation: 940

I have found the answer to my own question.Unfortunately, the remote JMX do not always work with JBoss.

The following table summarize the cases:

JBoss Version - JDK - Works

4.2.3 ---- ---- 1.5 -- Yes

4.2.3 --------- 1.6 -- Yes

5.0.1 --------- 1.5 -- No

5.0.1 --------- 1.6 --- Yes

5.1 ----------- 1.5 -- No

5.1 ----------- 1.6 -- No

For more information refer to this.

Upvotes: 1

Santosh
Santosh

Reputation: 17923

I suggest you look at the policy file. There might be some permission issue when using VisualGC remotly . Please check out this link.

Upvotes: 0

Related Questions