问题
I am trying to test my web application in GlassFish 4 from eclipse. When I am starting GlassFish 4 with a file (startserv.bat), it works fine, but when I am trying to run it from Eclipse, it starts loading, but then the startup process gets stuck at 69%, on a message Launching Delegate...
After several minutes in that condition, it gives me an error message:
After a few re-tries, I got this message:
Even though nothing is running on the port 8080 (GlassFish's port) and 4848 (GlassFIsh's admin port)
It worked fine for me before, but now for some reason, it just doesn't, I haven't done anything to it's settings or anything. How can I resolve this problem?
Here is my startup console log: http://pastebin.com/XL0Lh5zw (using pastebin to avoid making the post to big)
回答1:
I had the same problem, with the same messages.
After a long search, I gave up and I removed the server.
And I removed the Server Runtime Environment
The Glassfish files were not removed only the eclipse configurations, and then I re-created the Server Runtime and the Server using the existent glassfish server and the problem was fixed :D.
回答2:
I got the same issue. I'm using Eclipse Luna.
I downgraded my GlassFish Tools to 7.2 and I got the server started back again. http://download.oracle.com/otn_software/oepe/12.1.3.1/luna/repository
回答3:
I didn't see any errors in the log, just some warnings about Hibernate stuff, which shouldn't crash the launch. It could be that it is taking too long to initialize with all of the eclipse overhead, but most likely it could be a locking issue, which could cause the timeout, since eclipse would be left infinitely waiting for a resource it could never obtain. Are you sure the server is only being accessed by eclipse, and is not already running or owned by another process?
回答4:
I was also getting this issue all the week. But in our team we finally fixed it. It seems that Glassfish needs JDK 8 (not JRE 8 default given entry in Eclipse Luna) so you have to firstly install JDK 8 from Oracle web site and after configure Eclipse to point on it in Windows -> Preference -> Java -> Installed JREs Click on "Add" choose "Standard VM" click on "Next" and use "Directory" button to point on your -freshly installed- JDK8 directory if you didn't change any thing during the installation , on windows it would be "C:\Program Files\Java\jdk1.8.0_20".
Just because Glassfish and Glassfish Tools for Luna need JDK8 to perfectly work.
回答5:
I had the very same issue with GF 3.1.
When looking into the problem I noticed that in the Eclipse console Glassfish appeared to be still running. I deleted the application using the web console and then I quit Eclipse. I then checked the active Java process (i.e. ps -e | grep java
) and noticed an zombie Glassfish process.
Sometimes it happens that Eclipse is not able to startup / shutdown Glassfish correctly, "loosing" a process doing so. Usually killing the zombie process fixes Glassfish and related integration with Eclipse.
Another thing to try in this case is to remove the applications from the Server and remove the server from Servers panel in Eclipse, then adding the server and applications again.
I'm using Eclipse Glassfish 3.1.1, Luna 4.4.1, Java 1.7.0_71, OS X Yosemite.
回答6:
Changing debug port (properties->glassfish->debug port) to current+1 (eg. from 8008 to 8009) every time it happens makes it work for me. I'm using eclipse neon 4.6.0 + glassfish 4.1
回答7:
If any one is still stuck go to your glassfish folder domain > domain1 > config edit domain.xml change network listener port no. to any other port number. Restart eclipse and glassfish. assuming you have glassfish 4.1.1 it worked for me.
回答8:
I fixed the problem by using Eclipse Neon (4.6) and GlassFish 4.1.1.
回答9:
Had the same problem, no idea why this happens. Anyway, I deleted Glassfish from Eclipse and had a new GF set up. Worked for me just fine!
回答10:
Using Eclipse Mars and Glassfish 3.2. I used Eclipse > Help > Check for Updates. Two updates were found and one was Glassfish tools. Allowed the update to do its thing and it seems to have resolved the problem.
回答11:
Go to below path:
C:\glassfish4\glassfish\domains\domain1\config
Also the path where your server location configured into the eclipse and open domain.xml file.
- Find out the 8080 port number and change different port number like 8081...
- Save and close the file.
In eclipse:
- Remove the added server and add fresh Glashfish server.
- Start the server. This will solve the problem.
来源:https://stackoverflow.com/questions/27684353/glassfish-server-fails-to-launch-from-eclipse-it-gets-stuck-at-69