Jenny Pouwels
Jenny Pouwels

Reputation: 3

Netbeans IDE8 Glassfish 4, GlassFish Server: Administrator port is occupied by null

I just downloaded Netbeans IDE7 with the Glassfish 4.

I just made a project to test it out and see how it goes, and I got this error right from the start:

Could not start GlassFish Server: DAS port is occupied while server is not running
[location]: Deployment error: Could not start GlassFish Server: DAS port is occupied while server is not running
See the server log for details.
BUILD FAILED (total time: 1 second)

I have reinstalled it three times, with the Glassfish and without and then later add it to Netbeans, i changed the domain.xml name="admin-listener" port="4848" to something different

i did this cmd code netstat -aon | find ":80" | find "LISTENING" and closed the programm.

i ran as administrator i think i did almost everyting but it wont simply run, and it keeps returning to the same error

usually i would have given up but this software is required for a school project.

i will try everything.

i hope someone can help me.

Thx in advance

Upvotes: 0

Views: 30998

Answers (10)

Hafiz Hamza
Hafiz Hamza

Reputation: 309

If you changed the host of Glassfish server then set it to localhost it should work.

image

Upvotes: 0

Alberto
Alberto

Reputation: 1

May be late but I solved this issue by deleting the app server from the Netbeans and by adding it again. In my case Netbeans 8.2 and Payara 4.1 instead of Glassfish.

Upvotes: 0

qwertz
qwertz

Reputation: 81

I had the same error message. Turned out it was caused because my firewall blocked port 4848

Upvotes: 0

mr.aishwary
mr.aishwary

Reputation: 1

Go to Task Manager -> Services -> Stop Process whose PID IS 3136,2268,2468 ,23.... and near Range in PID. All processes near to the web server's PID.

It works for me on Windows 8.1 pro & Windows 7.

Upvotes: 0

João Quintas
João Quintas

Reputation: 851

In my case when using the command

netstat -aon | find ":4848" | find "LISTENING"

I noticed that one process was occupying this port. When checked what it was I noticed it was VMWare NAT controller, because I previously had configured a network adapter to listen to this port.

Just stopped all VMWare related services (in my case I didn't need them for development purposes), and solved the problem.

Upvotes: 0

John Wooten
John Wooten

Reputation: 745

Note that this isn't the only problem. I run on a Mac and can use the asadmin start command successfully on the remote server. IF I try to start it from NetBeans, it gives me this message.

One hint might be that the domain.xml file is set so that the listening port is 9090, the properties screen for the remote server, which I entered 9090 for, tells me the HTTP port is 23043. I can't edit it. Everytime I try to create that remote server it sets it to this value. The server will run fine if I start it by hand on the remote server, but NetBeans doesn't think it is running.

This occurs because I had to select domain2 because NetBeans says domain1 is already registered on my local machine. I wanted to have a local domain1 and a remote domain1 that are identical so I can test locally, and then deploy remotely.

Upvotes: 1

miksiii
miksiii

Reputation: 2496

You have to find the process that has taken the port you need. You can try finding it by running the terminal with the command:

netstat -aon | find ":80" | find "LISTENING"

Find the information you need and than kill the process with specific PID in Task Manager.

I hope you find this useful,

Thanks.

Upvotes: 5

java_user
java_user

Reputation: 1

By my experience with this over win 8.1 + Netbeans 8.0 + Glassfish 4.0

The problem resides in permission of folder in windows that block the server execution

I solve the problem changing the permission of the glassfish/domain/domain1 folder for xxxx/user to totalcontrol

If this not solve your problem, try launch the server over console:

asadmin start-domain --verbose

And read the exceptions to try solve the problem.

-EDIT: Reading other post to try help:

like this: Glassfish server started failed in netbeans 6.9

Or check your firewall:

allow >> C:\Program Files\glassfish-X.X\glassfish\modules\glassfish.jar

Upvotes: 0

user2512686
user2512686

Reputation:

This error message could be misleading, because it is the same when IP adress of glassfish server in netbeans settings is wrong (not port).

Upvotes: 0

John Clingan
John Clingan

Reputation: 3334

A few points:

  • Why not download NetBeans 8 that also includes GlassFish 4?
  • Assuming that you have successfully figured out that no other process is listening on port 4848, then Which version of the JDK are you using? Can you try JDK 7 if you are using JDK 8?
  • Looks like you are not alone - see NetBeans bug 237477.

Upvotes: 1

Related Questions