Oracle WebLogic has some interesting traits to help developers frustrate. From Weblogic 10.3.4 and above the Apache Derby Database is included in the installation. That’s fine but from 12.1.2 release it also starts automatically which is usually unwanted, useless and waste of resources. Previous versions of WebLogic didn’t automatically start the Derby database.
Fortunately you can disable it as basically there is a simple IF statement in the “$WL_DOMAIN_HOME$\bin\setDomainEnv.cmd” file:
@REM Set DERBY_FLAG, if derby is available. if exist %WL_HOME%\common\derby\lib\derby.jar ( set DERBY_FLAG=true )
If you want to prevent Derby form starting you have three options:
- Rename “derby.jar” to something else
- Delete the IF statement from start-up script
- Set the DERBY_FLAG to false in the startWeblogic.cmd script
I couldn’t find Oracle’s documentation about Derby in Weblogic but those four options seems to work. I prefer the third option which is quite easy to configure. (via Oracle Community)
In my “$WL_DOMAIN_HOME$\bin\startWebLogic.cmd” I added
... @REM Call setDomainEnv here. @REM Disabling Derby set DERBY_FLAG = false ...