I forgot the master-password of my Glassfish 3.1.2.2. Is there a way to reset it? I spent a lot of time "googling around" but i didn't find a suitable answer.
In the domain1/config folder of GlassFish there's a file "admin-keyfile", make a backup copy of it. Change the admin line to read "admin; ;asadmin". Restart the server and you should be able to log in with just the user account "admin" and no password. Save this answer.
The default master password is changeit . Use the change-master-password subcommand in local mode to modify the master password. When the master password is changed, it is re-saved in the master-password keystore, which is a Java JCEKS type keystore.
GlassFish Server stores user credentials locally in a file named keyfile . The file realm is the initial default realm. The administration realm is also a file realm and stores administrator user credentials locally in a file named admin-keyfile .
There is a backup password that can be used to access the administrator panel even if you've forgotten the main one.
If you navigate to glassfish\domains\domain1\config\
you will find a file called local-password
.
The contents of that file can be used as a password to log in to the control panel as admin.
Please follow the below steps:
FYI, now you should also know why you want to protect the master password file using file permissions :-)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With