0
votes

I'm not a java programmer and don't know much about eclipse or web services. I needed to create a web service and then set this up on a windows server. So I set up a localhost Glassfish 3.1.2.2 in eclipse juno ee and created a web service. Now its to be transferred to a vm windows 2008 server.

The vm windows 2008 server has been setup with java 1.7 and Glassfish 3.1.2.2. The glassfish starts up and I can access the admin.

When tried to connect eclipse to this remote glassfish it failed. New Server Select glassfish 3.1.2 Server Host name :servername. Admin Port: 4848 Port :8080 User: admin ping server Cannot connect Hint: run asadmin enable-secure-admin I have run the asadmin enable-secure-admin but it still gives the same complaint.

asadmin –host servername –user admin –port 4848 –secure list-applications

Connects so the glassfish server is there.

asadmin --host servername --user admin --port 4848 get secure-admin.enable secure-admin.enabled=true

Command get executed successfully. So Glassfish is secure.

I can ping the windows server. I can login to the http//:servername:4848 from my pc. (it does complain about the certificate but still lets me in)

What have I missed? It doesn't appear to be trying or getting near the server the error appears as soon as the ping is pressed.

If it's something like a firewall how can I test/check this connection? The hint doesn't help is there an actual error message?

1

1 Answers

2
votes

This is really annoying bug, but there is a workaround.

  1. Create a localhost glassfish server with default settings. It should appear in the Servers tab.
  2. Open server settings and uncheck "Use Anonymous Connection for Admin Commands".
  3. Change IP address of a server from localhost to your server address. Now it will connect remotely using admin name and password.