Skip to main content

Strange JMX problem w/GFv2r2

4 replies [Last post]
Joined: 2003-06-13

We are encountering a very strange JMX problem against Glassfish.

Simply put, we're doing classic JMX client/server stuff.

The MBeans are being defined in a Web App, registered, etc.

For running against glassfish, we connect to my host (localhost) and port 8686 (default).

I have a test client that sends and receives data through JMX. Some of this data are serializable Java Beans that we have written.

So, here's the rub.

On my version of Glassfish, v2r2, this works a champ. Just peachy.

On my colleagues system, it does not. We downloaded a new GF jar, installed it, set it up, deployed, connected to it, and boom. No bueno. Most aggravating.

After messing around with it for 1 or 2 hours, we finally fired up the Netbeans bundled Tomcat, added the JMX properties for the JVM, and deployed our war.

On my colleagues machine, JMX works fine with Tomcat, but not Glassfish.

JMX seems to be having some problem serializing Beans for the RETURN trip from the server. The client can send beans TO the server, but when the server returns them as method return results, we get the exception on the client.

The exception is below, talking about a Malformed URL (and boy, is it). The question is why we would be getting this strange URL from our fresh Glassfish install, and why does this work just on my GF install, and just fine on a random Tomcat install.

Any thoughts appreciated, I'd rather not deploy to Tomcat long term.


Exception Stacktrace:


at $Proxy0.getAgentServer(Unknown Source)

at org.hosscollab.client_src.Shell.listAgentServer(

at org.hosscollab.client_src.Shell.commandListAll(

at org.hosscollab.client_src.Shell.executeCommand(

at org.hosscollab.client_src.Shell.runConsole(

at org.hosscollab.client_src.Shell.runShell(


at org.hosscollab.client_src.Shell.(

at org.hosscollab.client_src.Shell.main(
Caused by: java.rmi.UnmarshalException: error unmarshalling return; nested exception is: no protocol: Files/glassfish-v2ur2/domains/domain1/generated/ejb/j2ee-modules/hossconfigserver/

at sun.rmi.server.UnicastRef.invoke(Unknown Source)

at com.sun.jmx.remote.internal.PRef.invoke(Unknown Source)

at Source)

at$RemoteMBeanServerConnection.invoke(Unknown Source)

at Source)

... 9 more
Caused by: no protocol: Files/glassfish-v2ur2/domains/domain1/generated/ejb/j2ee-modules/hossconfigserver/

at Source)

at Source)

at Source)

at sun.rmi.server.LoaderHandler.pathToURLs(Unknown Source)

at sun.rmi.server.LoaderHandler.loadClass(Unknown Source)

at java.rmi.server.RMIClassLoader$2.loadClass(Unknown Source)

at java.rmi.server.RMIClassLoader.loadClass(Unknown Source)

at sun.rmi.server.MarshalInputStream.resolveClass(Unknown Source)

at Source)

at Source)

at Source)

at Source)

at Source)

at sun.rmi.server.UnicastRef.unmarshalValue(Unknown Source)

... 14 more

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Joined: 2005-10-28

Hmmm. Something Fishy here :)

I see "Files/glassfish-v2ur2/domains/ ..." and assume that it is a substring of "C:/Program Files/...".

So, are you on Windows when it fails and on better platforms when it works?


Joined: 2005-03-30

Or perhaps both installations are on Windows but your installation is not in \Program Files\ while your colleague's is?

- Tim

Joined: 2003-06-13

Hot damn! That could well be it! I will get back to you in a bit...good find.

Joined: 2003-06-13

Yup, that was it.

Thanks a lot all!

In hindsight I've heard mumblings about this issue, and having the Unix chromosome, this has never been an issue for me. But my colleague is Different, so this was an obvious choice. Even when we resintalled GF, he moved it (before running setup) in to Program Files and, of course, that didn't work either.

No matter, all betta, just need to brand that one on my arm.

Thanx again!