Code Snippet

Just another Code Snippet site

[Weblogic] Reset admin password

export MW_HOME=/u01/app/oracle/middleware
export DOMAIN_HOME=$MW_HOME/user_projects/domains/ClassicDomain

Shut down the WebLogic domain.

$ $DOMAIN_HOME/bin/stopWebLogic.sh

Rename/Remove the data folder.

$ mv $DOMAIN_HOME/servers/AdminServer/data $DOMAIN_HOME/servers/AdminServer/data-old

Rename/Remove the file

rm $DOMAIN_HOME/security/DefaultAuthenticatorInit.ldift

Set the environment variables.

$ . $DOMAIN_HOME/bin/setDomainEnv.sh

Reset the password using the following command. Remember to substitute the appropriate username and password.

$ cd $DOMAIN_HOME/security
$ java weblogic.security.utils.AdminAccount <username> <password> .

Update the “$DOMAIN_HOME/servers/AdminServer/security/boot.properties” file with the new username and password. The file format is shown below.

username=<username>
password=<password>

Start the WebLogic domain.

$ $DOMAIN_HOME/bin/startWebLogic.sh


Comments are currently closed.