Uma Ilango
Uma Ilango

Reputation: 978

Netbeans 7.1.2 - Unable to add glassfish server 3.1.2

I downloaded glassfish server from http://glassfish.java.net/downloads/3.1.2.2-final.html and installed in separately.

Now I am trying to add this in Netbeans. But it does not work. I did the below steps

  1. Open Netbeans as administrator
  2. Open Tools -> Servers
  3. Click "Add Server" button
  4. Choose GlassFish Server 3+
  5. Specify a name as "GlassFish"
  6. Choose the installation folder location - C:\glassfish3

Now it displays the error "Not a valid Glassfish server Installation".

I am new to Netbeans & Glassfish & now don't know how to continue. My glassfish server is running successfully at localhost:8181

Can someone please help?

Upvotes: 4

Views: 28325

Answers (6)

Jay TD
Jay TD

Reputation: 1

I know this is an old question, but for anyone facing this now, here's how I resolved it.

  • Go to glassfish GitHub release page And download glassfish separately.
  • Close NetBeans and open again
  • Follow the server adding steps and instead of install glassfish through NetBeans choose the downloaded folder
  • In case error still comes try uninstall and reinstalling NetBeans and follow these steps.

Mostly Java 08 works with older versions of glassfish servers without an issue.

Upvotes: 0

JohnRose
JohnRose

Reputation: 409

Reason for Not a valid Glassfish server Installation could be you may not give correct Server(Glassfish/Tomcat) installation folder. Adding server to your project is as follows

Go to Services tab , Select Servers then right click on it. Select Add Server. Select your server(Glassfish) and name it then click next.

In Server Location give correct installation location (in my pc, c:\Program Files\glassfish-3.1) the click next. Give Domain name as you like it. Do not use default port. Leave Target name, username, password then click Finish. It will show Domain creation successful.

For Ref: Creating server in netbeans

Upvotes: 0

user1021738
user1021738

Reputation: 1

For windows 7 I searched for the GlassFish path (it was installed with NetBeans). I found it in

C:\Program Files\glassfish-3.1.2.2\glassfish\lib\install\applications__admingui\WEB-INF\lib

the rename in the posts above did not help.

So I removed the folders from the path until I got to this shortened path C:\Program Files\glassfish-3.1.2.2\glassfish where the next button became active and I could install GlassFish.

Upvotes: 0

Jitesh
Jitesh

Reputation: 1382

There is one simpler workaround. Just change the name of the jar in glassfish installation (c:\glassfish3\glassfish\lib\install\applications__admingui\WEB-INF\lib\console-core-3.1.2.jar) Then our server 3.1.2.x will be recognized by the netbeans as version 3.1.2 ;-) Works fine.

Upvotes: 2

Pawn
Pawn

Reputation: 161

I had this same issue and was able to fix it by following what was done in the video found here: http://happilyblogging.wordpress.com/2012/10/04/not-a-valid-glassfish-server-installation-netbeans/

Essentially, you must stop the gf3 server and rename the console-core-X.X.X.jar located in \glassfish3\glassfish\lib\install\applications__admingui\WEB-INF\lib to console-core-3.1.2.jar

Upvotes: 6

Uma Ilango
Uma Ilango

Reputation: 978

  1. I uninstalled Netbeans & Glassfish current installations.
  2. Opened http://netbeans.org/downloads/index.html, Clicked "Download" button under "All" column (240MB). Downloaded the exe file & installed it
  3. This installed Netbeans & Glassfish as a bundle
  4. Now creating a web application project displayed Glassfish 3.1.2 in the list automatically.

Problem solved.

Please note that separate installation still doesn't work. I am still unable to register a separate glassfish3 installation. I think bundled installation has some fix in it.

Upvotes: 1

Related Questions