Question

I downloaded Eclipse Juno a while ago but until now used its Java SE perspective only.

Today I downloaded GlassFish 4 for Windows and installed it. During installation I got a screen that showed that installation process didn't find Java JDK but allowed to browse for it. I found C:\Program Files\Java\jdk1.7.0_17 directory and selected it. i finished the installation and was able to start and stop domain and see both application and admin pages.

I also wanted to install GlassFish plug-in for Eclipse. I found it through Marketplace and downloaded and installed it.

I switched Eclipse's perspective to JavaEE and tried to pick GlassFish as a server. Such option was indeed there. However, I then got a screen titled New GlassFish 4.0 Runtime with the following error:

Glassfish server runtime requires full JDK instead of JRE

The only enabled buttons are Back and Cancel.

I Googled around but didn't find anything useful for such case.

Can somebody guess what could have happened and suggest troubleshooting steps?

Was it helpful?

Solution 2

On the screen where you define GlassFish runtime, there is a link labeled "Installed JRE preferences". If you click on that you will be directed to a screen that shows you all JRE and JDK installations that Eclipse knows about. You will need to add an entry for your JDK install. Then, when you return to the GF screen, select that new entry in the JRE drop-down list.

OTHER TIPS

1) make sure the jdk is installed. Look in C:\Program Files\Java\jdk1.7.XXXX

2) Go to Window > Preferences. Then under +Java+Installed JREs hit Add.

  • Select 'Standard VM' then Next
  • JRE Home = C:\Program Files\Java\jdk1.7.XXXX
  • the rest should fill in automagically.

3) Still in Preference Window -

  • Get to +Server, Runtime Environments
    • Select add an chose glassfish 4 (for example)
    • In JRE choose the new jdk added in step 2.
    • In glassfish server directory choose the path where you have setup glassfish, in my case is: D:\glassfish4\glassfish

4) Restart eclipse.

I also faced the same issue. Link "Installed JRE preferences" was not available.

Click on 'Manage Eclipse Java Runtimes'
Add your jdk version, you can also search for your jdk installation with 'search' button. If jdk is not installed, you need to install it first.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top