Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to install GlassFish v2 on my Macintosh. The installation instructions say that it should prompt for an admin password, but it doesn't, and now I can't log into the admin console on localhost:4848. And I can't change it with asadmin change-admin-password because it needs the old one. I think I installed GlassFish with NetBeans a few months ago and might have started it up once or twice, but I don't remember what password I used back then. Is there a command I can give or a file I can delete to make it forget that old password and prompt me for a new one?

share|improve this question

migrated from Jul 18 '09 at 0:43

This question came from our site for system and network administrators.

Why it's "migrated from" ? – linux_is_for_desktop Aug 13 '09 at 9:41
Because somebody decided it wasn't sysadmin-ish enough for ServerFault. – Paul Tomblin Aug 13 '09 at 11:37
up vote 4 down vote accepted

The default password is built into the app, and at the risk of making unsecure apps even more unsecure. Default password is "adminadmin".

share|improve this answer
Ok, that gave me the clue. Evidently the default password is built into the app, and at the risk of making unsecure apps even more unsecure, it's "adminadmin". – Paul Tomblin Jul 18 '09 at 1:07
Paul: That is...awesome. – TheTXI Jul 18 '09 at 1:09
Link is dead... – Nowaker Jan 22 '12 at 22:13
glassfish default master password is "changeit" I think, FWIW (distinct from admin password). – Thufir Mar 12 '15 at 9:49

The content of glassfish3\glassfish\domains\domain1\config\local_password file is a backup password to log in as admin.

(let's pack some rep after the years)

share|improve this answer
But then how do you reset the normal (i.e., admin-keyfile) password? – John K Jun 11 '15 at 22:15

You can also create a new domain, set the admin password there to whatever you like and move the password files over to your original domain. Here's a blog post explaining the process:

share|improve this answer
There's even better answer in that post now. Go to glassfish3\glassfish\domains\domain1\config\local_password file - its contents are a backup password to log in as admin. – Victor Sergienko May 7 '12 at 10:35
@VictorSergienko Wow, that was a great tip!! Thanks! Worked beautifully! – René Nov 30 '12 at 11:48
@VictorSergienko Wow worked for me too – shareef Jan 18 '13 at 10:16
file not present in glassfish 4 – dendini Oct 15 '13 at 14:33
@VictorSergienko Thank you. – Ravindra Gullapalli Jul 28 '14 at 9:17

With Glassfish, at least, you can replace the domain\config\admin-keyfile contents with the following:


This will give you a username of 'admin' and password 'changeit'.

share|improve this answer
Works for me on Glassfish 4.1. – Douglas Junior Oct 2 '15 at 14:57
  1. Login to asadmin and start Glassfish from the command line:

    asadmin>  start-domain  
  2. The admin port should be 4848, other port causes fail in attempt to change the password. Reset password as an empty string:

    asadmin> set --user admin server.jms-service.jms-host.default_JMS_host.admin-password=
  3. asadmin> exit

It is useful for testing and development. NetBeans doesn't allow integrating Glassfish with password, password is always not accepted. To remove password is workaround.

share|improve this answer

Under glassfish 4 you have a shiny new option as shown in the example below (and I'm giving my admin password for free for real ;))


share|improve this answer
that does not change or reset the glassfish password, it just set the password that will be used by netbeans to start glassfish server – yeradis Nov 18 '13 at 11:10
He said he installed GlassFish with NetBeans therefore Glassfish is automatically set up by NetBeans installer, as of Netbeans 7.X this password is set randomly by NetBeans and can only be seen by looking inside the Servers option. No need to reset it if you can read it! – dendini Nov 25 '13 at 9:37

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .