Showing posts with label Weblogic. Show all posts
Showing posts with label Weblogic. Show all posts

Thursday, 29 May 2014

WebLogic Startup fails with Unable to obtain lock on Server may already be running

Issue : When weblogic server starting showing error "Unable to obtain lock" .
Root Cause: previous session has not been terminated cause <servername>.lok file exists

Solution:
-Go to>> $DOMAIN_HOME/servers/<servername>/tmp/
  Check <servername>.lok file exists in this location.
-Delete this <servername>.lok file and start admin server ,it will overcome the error ...

Note-this solution applicable for all managed server as well..

Wednesday, 21 May 2014

Unable to get a connection for pool - ResourceUnavailableException

Issue:
Unable to get a connection for pool - ResourceUnavailableException
Solution:
Either specify a time period to wait for resources to become available, or increase the size of the pool and retry..

>>increasing the values for initial capacity, maximum capacity and the capacity increment like 10, 50, 5
>>Open the jndi :  in /console - config tab - increase the initial and max conn capacity and save it. Retry the scenario

Thursday, 15 May 2014

weblogic server forcefully shutting down "Cannot Restart Managed Server : Weblogic because of Exception while getting default policy Provider "


Issue scenario :When weblogic not accessible through url and url shows url error then check disk space on server with command df –ah.
If disk space is 100% full and weblogic server forcefully shutting down then check with below solution .

Oracle metalink: ID 1348704.1
Error log shows as shown below,
Cannot Restart Managed Server : Weblogic because of Exception while getting default policy Provider
While starting the Weblogic Managed server or admin server I was getting the eorror:

Reason: weblogic.security.SecurityInitializationException: The loading of OPSS java security policy provider failed due to exception, see the exception stack trace or the server log file for root cause. If still see no obvious cause, enable the debug flag -Djava.security.debug=jpspolicy to get more information. Error message: oracle.security.jps.JpsException: [PolicyUtil] Exception while getting default policy Provider


weblogic.security.SecurityInitializationException: The loading of OPSS java security policy provider failed due to exception, see the exception stack trace or the server log file for root cause.
 
Caused By: oracle.security.jps.JpsException: [PolicyUtil] Exception while getting default policy Provider
Caused By: java.security.PrivilegedActionException: oracle.security.jps.JpsException: [PolicyUtil] Unable to obtain default JPS Context!
Caused By: oracle.security.jps.JpsException: [PolicyUtil] Unable to obtain default JPS Context!
Caused By: oracle.security.jps.JpsRuntimeException: Cannot read from policy store.
Caused By: oracle.security.jps.JpsRuntimeException: javax.xml.stream.XMLStreamException: javax.xml.stream.XMLStreamException: Premature end of file encountered
 
 
Cause:
 
this can happen when a non weblogic user tried to restart the managed server [may be root by mistake]
 
In my env, it had corrupted the :
system-jazn-data.xml [got 0 bytes in it]
 
so i had to restore it :


from : /app/oracle/product/wcpoc/11.1.0/oracle_common/modules/oracle.jps_11.1.1/domain_config/system-jazn-data.xml

to /app/oracle/product/wcpoc/11.1.0/user_projects/domains/wc_poc/config/fmwconfig

and was finally able to restart the managed servers.
 
thanks to Oracle metalink: ID 1348704.1