Notifications
Clear all

How to resolve the JVM Bind Exception On Server start up?

7 Posts
5 Users
0 Reactions
1,409 Views
0
Topic starter

On startup, the server complains about not being able to bind to port 80.

5 Answers
0
Topic starter

Go to Services -> Stop the Web Deployment Agent Service and restart the server.

0

Bind exception means that some other process is listening on the same port. For example, if you are running PLT on port 80 and trying bring up another server on same port, you will see this error.
It can also be some program you installed that uses port 80 by default.

So check to see if you are already running another instance from command prompt or as a service.
As almost all developer machines are windows, you can try running netstat -ab to find processes running on a port. In my case, I was running two PLT servers, one on port 80 and one on port 90.
You can notice that above command listed them with java.exe processes.

 image 1
GregMerrill 2013-02-27 11:02:00

Other common culprits of eating port 80 include Skype, IIS, and the Web Deployment Agent Service mentioned by Sangeeth.

Skype solution: http://www.mydigitallife.info/disable-skype-from-using-opening-and-listening-on-port-80-and-443-on-local-computer/

dchisholm 2013-02-27 12:02:00

The tcpview tool from Microsoft's SysinternalsSuite is very good at finding conflicts. The suite includes many other helpful tools too, and there's no installer. Just download and unzip. http://technet.microsoft.com/en-us/sysinternals/bb842062.aspx

0

Another interesting scenario can be found here in the "HTTP (HTTP.SYS) Hidden Driver/Service" section: http://www.devside.net/wamp-server/opening-up-port-80-for-apache-to-use-on-windows

Apparently there is a "HTTP front-end proxy service" which can cause this issue on some machines. On a recent Windows 10 laptop, we were able to disable this only by following the "administrative privledged command-line" example given and restarting the machine.

0

http://stackoverflow.com/questions/142868/change-oracle-port-from-port-8080

Interesting article on changing Oracle XE ports. In some cases it can default to 80.

0

There can be many problems -- some even related to the particular vendor such as my Asus Laptop. It is a 2-1 Flip that has a power manager service FilpWifiPowerManager.svc. It turns out that it puts a dependency on http such that it MUST start and it WILL NOT stop as long as this service is running.

To make matters more confusing, if you do "net stop http /y" BEFORE this service is terminated then http can not tell you what is dependent. If you also run "sc config http start=disabled" then you can not even determine dependency on reboot -- it will always appear to stopping or stopped.

So..

netstat -o -n -a | findstr 0.0.0:80
netstat -o -n -a | findstr 127.0.0.1:80

Look up the pid in TaskManager. If it is System (always PID 4 on my machine) then you know it is with one of these process.

netsh http show urlacl

Find any entry that looks like...

Reserved URL : http://+:80/FilpWifiPowerManager.svc/

Look up the human readable name for the service so you can find it in services. Disable it.

THEN

net stop http /y

if it is successful, you will see it close SSDP, Print Spooler, and finally you see...

The HTTP Serivce serice was stopped successfully.

At that point, port 80 will be free. test by running app OR netstat -o -n -a

If it's free then...

sc config http start=disabled

If you disabled the dependent service AND disabled http THEN you will have 80 free everytime you boot (unless you have Skype or another app that blocks 80 🙂 )