Glassfish 4 Admin not running from Netbeans 7.4 (Password Incorrect)

sokid picture sokid · Aug 21, 2013 · Viewed 44.7k times · Source

I am trying to run Glassfish 4 using Netbeans 7.4 IDE, but I am receiving an error dialog like

Please check server admin user name and password properties.

Also please check the server log file for other possible causes.

I am passing the correct user name and password, I have ensured the same by running the glassfish 4 from the windows command prompt, it is running properly, but it is not running from Netbeans 7.4

Server log also attached for your reference.

[2013-08-21T21:09:02.736+0530] [glassfish 4.0] [INFO] [NCLS-LOGGING-00009] [javax.enterprise.logging] [tid: _ThreadID=1 _ThreadName=main] [timeMillis: 1377099542736] [levelValue: 800] [[
  Running GlassFish Version: GlassFish Server Open Source Edition  4.0  (build 89)]]

[2013-08-21T21:09:02.740+0530] [glassfish 4.0] [INFO] [NCLS-LOGGING-00010] [javax.enterprise.logging] [tid: _ThreadID=1 _ThreadName=main] [timeMillis: 1377099542740] [levelValue: 800] [[
  Server log file is using Formatter class: com.sun.enterprise.server.logging.ODLLogFormatter]]

[2013-08-21T21:09:02.923+0530] [glassfish 4.0] [INFO] [realm.loaded.successfully] [javax.enterprise.system.core.security.com.sun.enterprise.security.auth.realm] [tid: _ThreadID=1 _ThreadName=main] [timeMillis: 1377099542923] [levelValue: 800] [[
  SEC1115: Realm [admin-realm] of classtype [com.sun.enterprise.security.auth.realm.file.FileRealm] successfully created.]]

[2013-08-21T21:09:02.928+0530] [glassfish 4.0] [INFO] [realm.loaded.successfully] [javax.enterprise.system.core.security.com.sun.enterprise.security.auth.realm] [tid: _ThreadID=1 _ThreadName=main] [timeMillis: 1377099542928] [levelValue: 800] [[
  SEC1115: Realm [file] of classtype [com.sun.enterprise.security.auth.realm.file.FileRealm] successfully created.]]

[2013-08-21T21:09:02.935+0530] [glassfish 4.0] [INFO] [realm.loaded.successfully] [javax.enterprise.system.core.security.com.sun.enterprise.security.auth.realm] [tid: _ThreadID=1 _ThreadName=main] [timeMillis: 1377099542935] [levelValue: 800] [[
  SEC1115: Realm [certificate] of classtype [com.sun.enterprise.security.auth.realm.certificate.CertificateRealm] successfully created.]]

[2013-08-21T21:09:03.466+0530] [glassfish 4.0] [INFO] [] [javax.enterprise.system.core] [tid: _ThreadID=1 _ThreadName=main] [timeMillis: 1377099543466] [levelValue: 800] [[
  Grizzly Framework 2.3.1 started in: 25ms - bound to [/0.0.0.0:8,080]]]

[2013-08-21T21:09:03.503+0530] [glassfish 4.0] [INFO] [] [javax.enterprise.system.core] [tid: _ThreadID=1 _ThreadName=main] [timeMillis: 1377099543503] [levelValue: 800] [[
  Grizzly Framework 2.3.1 started in: 3ms - bound to [/0.0.0.0:8,181]]]

[2013-08-21T21:09:03.516+0530] [glassfish 4.0] [INFO] [] [javax.enterprise.system.core] [tid: _ThreadID=1 _ThreadName=main] [timeMillis: 1377099543516] [levelValue: 800] [[
  Grizzly Framework 2.3.1 started in: 3ms - bound to [/0.0.0.0:4,848]]]

[2013-08-21T21:09:03.631+0530] [glassfish 4.0] [INFO] [] [javax.enterprise.system.core.security.org.glassfish.security.services.impl.authorization] [tid: _ThreadID=1 _ThreadName=main] [timeMillis: 1377099543631] [levelValue: 800] [[
  Authorization Service has successfully initialized.]]

[2013-08-21T21:09:03.709+0530] [glassfish 4.0] [INFO] [] [javax.enterprise.system.core] [tid: _ThreadID=1 _ThreadName=main] [timeMillis: 1377099543709] [levelValue: 800] [[
  Grizzly Framework 2.3.1 started in: 2ms - bound to [/0.0.0.0:3,700]]]

[2013-08-21T21:09:03.719+0530] [glassfish 4.0] [INFO] [] [org.glassfish.ha.store.spi.BackingStoreFactoryRegistry] [tid: _ThreadID=1 _ThreadName=main] [timeMillis: 1377099543719] [levelValue: 800] [[
  Registered org.glassfish.ha.store.adapter.cache.ShoalBackingStoreProxy for persistence-type = replicated in BackingStoreFactoryRegistry]]

[2013-08-21T21:09:03.992+0530] [glassfish 4.0] [INFO] [] [org.hibernate.validator.internal.util.Version] [tid: _ThreadID=53 _ThreadName=pool-6-thread-2] [timeMillis: 1377099543992] [levelValue: 800] [[
  HV000001: Hibernate Validator 5.0.0.Final]]

[2013-08-21T21:09:03.992+0530] [glassfish 4.0] [INFO] [NCLS-CORE-00017] [javax.enterprise.system.core] [tid: _ThreadID=1 _ThreadName=main] [timeMillis: 1377099543992] [levelValue: 800] [[
  GlassFish Server Open Source Edition  4.0  (89) startup time : Felix (3,785ms), startup services(1,359ms), total(5,144ms)]]

[2013-08-21T21:09:04.239+0530] [glassfish 4.0] [INFO] [] [org.glassfish.jersey.server.ApplicationHandler] [tid: _ThreadID=52 _ThreadName=pool-6-thread-1] [timeMillis: 1377099544239] [levelValue: 800] [[
  Initiating Jersey application, version Jersey: 2.0 2013-05-03 14:50:15...]]

[2013-08-21T21:09:05.470+0530] [glassfish 4.0] [INFO] [NCLS-JMX-00005] [javax.enterprise.system.jmx] [tid: _ThreadID=54 _ThreadName=Thread-6] [timeMillis: 1377099545470] [levelValue: 800] [[
  JMXStartupService has started JMXConnector on JMXService URL service:jmx:rmi://RAJESHWARAN-MOBI.TOSHIBA-TSIP.COM:8686/jndi/rmi://RAJESHWARAN-MOBI.TOSHIBA-TSIP.COM:8686/jmxrmi]]

[2013-08-21T21:09:05.501+0530] [glassfish 4.0] [INFO] [] [javax.enterprise.system.core] [tid: _ThreadID=1 _ThreadName=main] [timeMillis: 1377099545501] [levelValue: 800] [[
  Grizzly Framework 2.3.1 started in: 43ms - bound to [/0.0.0.0:7,676]]]

[2013-08-21T21:09:05.810+0530] [glassfish 4.0] [INFO] [NCLS-BOOTSTRAP-00027] [javax.enterprise.bootstrap] [tid: _ThreadID=1 _ThreadName=main] [timeMillis: 1377099545810] [levelValue: 800] [[
  Registered com.sun.enterprise.glassfish.bootstrap.osgi.EmbeddedOSGiGlassFishImpl@739168d7 as OSGi service registration: org.apache.felix.framework.ServiceRegistrationImpl@62c7f808.]]

[2013-08-21T21:09:05.857+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099545857] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.web.glue, null) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.web.glue [350]], State = [READY]]]

[2013-08-21T21:09:05.857+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099545857] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.web.javax.servlet.jsp, null) returned OSGiModuleImpl:: Bundle = [org.glassfish.web.javax.servlet.jsp [209]], State = [READY]]]

[2013-08-21T21:09:06.610+0530] [glassfish 4.0] [INFO] [] [javax.enterprise.system.tools.deployment.common] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546610] [levelValue: 800] [[
  visiting unvisited references]]

[2013-08-21T21:09:06.865+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546865] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-common, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-common [76]], State = [READY]]]

[2013-08-21T21:09:06.867+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546867] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.hk2.hk2, 2.1.92) returned OSGiModuleImpl:: Bundle = [org.glassfish.hk2.hk2 [176]], State = [READY]]]

[2013-08-21T21:09:06.868+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546868] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-plugin-service, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-plugin-service [96]], State = [READY]]]

[2013-08-21T21:09:06.875+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546875] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.deployment.deployment-client, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.deployment.deployment-client [111]], State = [READY]]]

[2013-08-21T21:09:06.875+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546875] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.registration.registration-api, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.registration.registration-api [305]], State = [READY]]]

[2013-08-21T21:09:06.876+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546876] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.registration.registration-impl, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.registration.registration-impl [307]], State = [READY]]]

[2013-08-21T21:09:06.877+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546877] [levelValue: 800] [[
  this.makeModuleFor(javax.servlet-api, 3.1.0) returned OSGiModuleImpl:: Bundle = [javax.servlet-api [207]], State = [READY]]]

[2013-08-21T21:09:06.877+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546877] [levelValue: 800] [[
  this.makeModuleFor(javax.servlet.jsp-api, 2.3.1) returned OSGiModuleImpl:: Bundle = [javax.servlet.jsp-api [208]], State = [READY]]]

[2013-08-21T21:09:06.878+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546878] [levelValue: 800] [[
  this.makeModuleFor(com.sun.el.javax.el, 3.0.0) returned OSGiModuleImpl:: Bundle = [com.sun.el.javax.el [192]], State = [READY]]]

[2013-08-21T21:09:06.878+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546878] [levelValue: 800] [[
  this.makeModuleFor(com.sun.jsftemplating, 2.1.0) returned OSGiModuleImpl:: Bundle = [com.sun.jsftemplating [252]], State = [READY]]]

[2013-08-21T21:09:06.879+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546879] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.dataprovider, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.dataprovider [104]], State = [READY]]]

[2013-08-21T21:09:06.879+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546879] [levelValue: 800] [[
  this.makeModuleFor(com.sun.pkg.client, 1.0.0) returned OSGiModuleImpl:: Bundle = [com.sun.pkg.client [304]], State = [READY]]]

[2013-08-21T21:09:06.879+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546879] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-jca-plugin, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-jca-plugin [89]], State = [READY]]]

[2013-08-21T21:09:06.880+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546880] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-web-plugin, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-web-plugin [100]], State = [READY]]]

[2013-08-21T21:09:06.880+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546880] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-corba-plugin, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-corba-plugin [82]], State = [READY]]]

[2013-08-21T21:09:06.880+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546880] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-community-branding-plugin, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-community-branding-plugin [78]], State = [READY]]]

[2013-08-21T21:09:06.881+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546881] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-jts-plugin, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-jts-plugin [95]], State = [READY]]]

[2013-08-21T21:09:06.881+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546881] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-ejb-plugin, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-ejb-plugin [87]], State = [READY]]]

[2013-08-21T21:09:06.881+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546881] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-common-full-plugin, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-common-full-plugin [74]], State = [READY]]]

[2013-08-21T21:09:06.882+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546882] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-concurrent-plugin, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-concurrent-plugin [80]], State = [READY]]]

[2013-08-21T21:09:06.882+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546882] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-common, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-common [76]], State = [READY]]]

[2013-08-21T21:09:06.882+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546882] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-jms-plugin, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-jms-plugin [93]], State = [READY]]]

[2013-08-21T21:09:06.883+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546883] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-cluster-plugin, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-cluster-plugin [72]], State = [READY]]]

[2013-08-21T21:09:06.883+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546883] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-ejb-lite-plugin, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-ejb-lite-plugin [85]], State = [READY]]]

[2013-08-21T21:09:06.884+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546884] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-updatecenter-plugin, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-updatecenter-plugin [98]], State = [READY]]]

[2013-08-21T21:09:06.884+0530] [glassfish 4.0] [INFO] [] [] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099546884] [levelValue: 800] [[
  this.makeModuleFor(org.glassfish.main.admingui.console-jdbc-plugin, 4.0.0) returned OSGiModuleImpl:: Bundle = [org.glassfish.main.admingui.console-jdbc-plugin [91]], State = [READY]]]

[2013-08-21T21:09:07.475+0530] [glassfish 4.0] [INFO] [AS-WEB-GLUE-00198] [javax.enterprise.web] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099547475] [levelValue: 800] [[
  Created HTTP listener http-listener-1 on host/port 0.0.0.0:8080]]

[2013-08-21T21:09:07.493+0530] [glassfish 4.0] [INFO] [AS-WEB-GLUE-00198] [javax.enterprise.web] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099547493] [levelValue: 800] [[
  Created HTTP listener http-listener-2 on host/port 0.0.0.0:8181]]

[2013-08-21T21:09:07.502+0530] [glassfish 4.0] [INFO] [AS-WEB-GLUE-00198] [javax.enterprise.web] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099547502] [levelValue: 800] [[
  Created HTTP listener admin-listener on host/port 0.0.0.0:4848]]

[2013-08-21T21:09:07.563+0530] [glassfish 4.0] [INFO] [AS-WEB-GLUE-00200] [javax.enterprise.web] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099547563] [levelValue: 800] [[
  Created virtual server server]]

[2013-08-21T21:09:07.563+0530] [glassfish 4.0] [INFO] [AS-WEB-GLUE-00200] [javax.enterprise.web] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099547563] [levelValue: 800] [[
  Created virtual server __asadmin]]

[2013-08-21T21:09:07.875+0530] [glassfish 4.0] [INFO] [AS-WEB-CORE-00306] [javax.enterprise.web.core] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099547875] [levelValue: 800] [[
  Setting JAAS app name glassfish-web]]

[2013-08-21T21:09:07.875+0530] [glassfish 4.0] [INFO] [AS-WEB-GLUE-00201] [javax.enterprise.web] [tid: _ThreadID=72 _ThreadName=Thread-10] [timeMillis: 1377099547875] [levelValue: 800] [[
  Virtual server server loaded default web module ]]

Is it required to run Netbeans 7.4 in Administrator mode? (I have tried but the same error has received).

Please help me to run Glassfish 4 using Netbeans 7.4

Answer

Quaternion picture Quaternion · Dec 12, 2013

For some reason they have added randomly generated passwords to both the webservers installed with Netbeans 7.4 (currently Apache Tomcat 7.0.41.0 and GlassFishServer 4.0).

To find out what these passwords are:

  1. Click on the Services tab.
  2. Expand the Servers drop down node (if not already expanded).
  3. Right click the web server you want the password for > select Properties.
  4. In the dialogue window which opens there is a Password field, to the right a show button click show and you have your answer.

In one way it's kind of nice that that there are good passwords out of the box and so it takes care of external access issues right away. But it certainly was annoying figuring this out.

Here down is information for shell and gui-less concerns, no need to read further if above solved your issues.


Update: It turns out that this password is pulled from a text file, on my system this file is found at ~/glassfish-4.0/glassfish/domains/domain1/config/local-password

Warning: not a good idea, to manually update that file! (See Update 2)

The later is good if you're going to administer glassfish from the terminal.

Update 2: In some previous versions it was possible to update the above listed file directly, this will no longer work and will break things. To change the password to a known state on fresh glassfish installation without a gui.

Using Glassfish 4.1 or greater on a clean install execute the following from within the asadmin shell:

Enter: change-admin-password Now enter "admin" (the default) twice. Now enter a new non blank password twice. Enter: enable-secure-admin

With the above done, you can remotely log in from a different host. This setup is fine for development needs but for production needs please see glassfish documentation for further security constraints (how to restrict to a port of particular domain).

PS: If you did break the password file by editing it, because it is a new install, simply unzip the glassfish again and copy that file over it self.