Saturday, May 21, 2016

How to Reset Oracle WebLogic Server Admin Password

Export Existing Users/groups and important for Production Server


Export *.dat files: Go to WebLogic Console>Security Realms>myrealm>Migration Tab>
Export Sub-Tab>Export Directory on Server: /u01/osbTempData and save

Setup CLASSPATH:

1. export MW_HOME=/u01/app/oracle/product/middleware
2. export DOMAIN_HOME=$MW_HOME/user_projects/domains/<domain_name> 
3. export CLASSPATH=$CLASSPATH:$MW_HOME/wlserver_10.3/server/lib/weblogic.jar

Shutdown your WebLogic domain:

4. $DOMAIN_HOME/bin/stopWebLogic.sh

Rename and backup the DefaultAuthenticatorInit.ldift file:

5. cd $DOMAIN_HOME/security
6. mv DefaultAuthenticatorInit.ldift DefaultAuthenticatorInit.ldift.old
7. java weblogic.security.utils.AdminAccount <username> <new_password> . [password+space+dot]

Rename and backup the following LDAP directory:

8. mv $DOMAIN_HOME/servers/AdminServer/data/ldap $DOMAIN_HOME/servers/AdminServer/data/ldap.old
(This LDAP directory will be recreated next time the WebLogic Admin server is started)

Edit the boot.properties file and update the password with the one you used above

9. cd $DOMAIN_HOME/servers/AdminServer/security
10. cp boot.properties properties.old

11. vi boot.properties

      password=<username>
      username=<new_password>

Now restart your WebLogic Domain:

12. $DOMAIN_HOME/startWebLogic.sh
13. Import myrealm security data that exported in the beginning.
14. Restart the server.

No comments:

Post a Comment