windowsglassfishportredeploy

Glassfish claims the port is occupied. Netsat disagree


I have succesfully deployed application on port 8080. After undeploy and killing all processes "java" and cleaning folders: "domains/domain1/osgi-cache/felix" and "domains/domain1/applications/" then I tried to redeploy application.

It occured the port is occupied. I could not find that port using netstat (like it was suggested on many other posts) so I guess port should be available.

I managed to deploy on different port (9090). I did again undeploy and rest of actions like killing and stopping domain... it occured the port is still occupied as well and I could not deploy app on port 8080 and 9090 now.

I am using glassfish 4.1.2 and Windows. Anyone have ideas what can I do more?

I also added my hostname under etc/host.


Solution

  • Actually, I did not find answer why the port is occupied. But if someone else found similar issue, this procedure of redeploy works for me: 1: go to admin panel of glassfish (by default :4848). Select application and click undeploy 2: stop domain using console (asadmin stop-domain domain1) 3: start domain using console (asadmin start-domain domain1) 4: go to admin panel(by default :4848), deploy application.

    This procedure worked for me, instead of clicking "redeploy" on admin panel.

    Glassfish and Windows...