Netbeans error with glassfish server 3.1?

19.7k Views Asked by At

I'm trying to launch a project in netbeans but I keep getting the error

"Could not connect to admin listener for GlassFish server 3.1 Verify that NetBeans can make outbound connections to localhost:4848"

I've been tackling glassfish server problems since morning. Has anyone encountered this problem before?

8

There are 8 best solutions below

0
Preston On

There are a few things to look at.

1) Make sure GF is running or if it's not that you can start it. On the Services tab, expand servers, right click on your gf server and select start. 2) Verify the port it's using by mousing over the server (see image). Make sure that port isn't blocked by a firewall. 3) Earlier you were having problems installing it. Right click on the server and verify the properties. If that path isn't correct or what not. Add a new server point to where ever you installed it.

Glassfish admin port

0
Vintesh On

Start server using:

<glassfilshInstallationRoot>\glassfish\bin\startserv.bat

For me it also works in NetBeans.

0
Amanda meng On

I encounted the same problem today, cause I'm using it for rails, and I always use Webric to run rails project. If you don't use glassfish, you can just delete it. click 'tools -> service', and delete glassfish, then it works fine.

2
Jimmy Geers On

I encounted the same problem. It was because the server takes over the proxy settings of the IDE by default. You can deselect it by going to GlassFish Server 3.x properties and then click on the java tab ==> deselect Use IDE's proxy settings.

Afther that i could deploy my application.

0
guest On

This has happened to me too,and I figured out that the 'JavA(TM) Platform SE Auto updater ' service was not running.I checked the service after running msconfig->startup tab.An update automatically was installed and there after everything restarted working. Hope this might help. Cheers. Maiga

0
sam On

The best thing that I suggest you can do is:

  1. Download the separate source for Glassfish server application
  2. Uninstall all the default files of Glassfish which were installed while installing Netbeans.(You need to close your Netbeans while uninstalling it. Plus delete any files in the folder glassfish-3.1.2.2 for which your path may be "C:programfiles/glassfish-3.1.2.2")
  3. Install the new source of Glassfish into the folder glassfish-3.1.2.2 for which your path may be "C:programfiles/glassfish-3.1.2.2"

Finally, open your project in Netbeans. You will be able to see Glassfish server files. Build your file and run it.

0
user2468087 On

admin-listener port defined in domain.xml for glassfish should be same that of which netbeans is trying to connect, e.g. 4848 (default) as below:

<network-listener port="4848" protocol="admin-listener" transport="tcp" name="admin-listener" thread-pool="admin-thread-pool"></network-listener>
</network-listeners>

location of domain.xml:

<Glassfish Installation folder>\glassfish-3.1.2.2\glassfish\domains\<domain-name>\config

I had accidentally changed the admin port from 4848 to something else. Saving it to 4848 fixed the problem. I am not sure yet where configuration of netbeans resides for connecting GF admin port.

0
user3334260 On

same thing happend with me.then i checked my anti-virus setting and turned anti-virus firwall disable for some time.and then run my project again and it worked for me. hope this may work for you as well.