Wednesday, 24 February 2016

How to force configuration changes in Weblogic

At a recent client deployment. I faced the issue that the datasource properties were not getting configured from the Weblogic Admin Console.

Symptoms - 
Activate changes button click hangs in-definately.
JDBC_datasource.xml file on node 2 of weblogic cluster is zero bytes.
Weblogic Version 10.3.6

The downtime was limited and there was no scope of troubleshooting the console.

This is what you do in the above scenario and force the changes from the background instead of the console.

Solution -

1. Shut down the admin server. Make sure you don't have any applications running in the admin server.

2. Backup or tar the config directory in the domain_home

3. Go inside the DOMAIN_HOME/pending folder. There you can see the config.xml and other changed configuration files like JDBC and JMS config files.
These are temporary config files which are cached with changes made from the console. Once you do activate changes, config.xml and other config files from here replaces the original config.xml and other configuration files inside the DOMAIN_HOME/config folder.

4. Move (do not copy) config.xml and all other config files from DOMAIN_HOME/pending folder to DOMAIN_HOME/config folder and replace the ones which are there.

5. Delete edit.lok inside DOMAIN_HOME and config.lok inside DOMAIN_HOME/config folder and restart Admin Server.

6. Log into the console and verify that the changes have taken effect.

This issue usually occurs with the admin console running in https mode rather than http mode.