If you need to change the memory allocation to your WebLogic administration server and/or managed server, the following guide will show you how. Note: This will raise the limit for both the WebLogic administration server and managed server. You can verify these settings by watching the server startup script. Optionally, if you are setting the memory for Oracle UCM, you can verify this setting on the System Audit Information page. Windows 1. Open the domain environment cmd file: <middleware home>\user_projects\domains\base_domain\bin\setDomainEnv.cmd 2. Locate the following remark, inside the cmd file: (‘Search’ -> “@REM IF USER_MEM_ARGS”) @REM IF USER_MEM_ARGS the environment variable is set, use it to override ALL MEM_ARGS values 3. Directly after this remark, add the following line: set USER_MEM_ARGS=-Xms256m -Xmx1024m -XX:CompileThreshold=8000 -XX:PermSize=128m -XX:MaxPermSize=512m 4. The portion of the file you have edited looks like this: @REM IF USER_MEM_ARGS the environment variable is set, use it to override ALL MEM_ARGS values set USER_MEM_ARGS=-Xms256m -Xmx1024m -XX:CompileThreshold=8000 -XX:PermSize=128m -XX:MaxPermSize=512m if NOT “%USER_MEM_ARGS%”==”" ( set MEM_ARGS=%USER_MEM_ARGS ) UNIX/Linux 1. Open the domain environment sh file: <middleware home>\user_projects\domains\base_domain\bin\setDomainEnv.sh 2. Locate the following remark, inside the sh file: (‘Search’ -> “#REM IF USER_MEM_ARGS”) #REM IF USER_MEM_ARGS the environment variable is set, use it to override ALL MEM_ARGS values 3. Directly after this remark, add the following line: USER_MEM_ARGS=-Xms256m -Xmx1024m -XX:CompileThreshold=8000 -XX:PermSize=128m - XX:MaxPermSize=512m 4. The portion of the file you have edited looks like this: #REM IF USER_MEM_ARGS the environment variable is set, use it to override ALL MEM_ARGS values USER_MEM_ARGS=-Xms256m -Xmx1024m -XX:CompileThreshold=8000 -XX:PermSize=128m -XX:MaxPermSize=512m if NOT “%USER_MEM_ARGS%”==”" ( MEM_ARGS=%USER_MEM_ARGS ) References Note that the basic difference between Windows and UNIX/Linux regarding this issue is the use of the “set” command for the Windows environment. Final Thoughts This is certainly not the only way to accomplish this task, and it does affect all managed servers in the domain. However, if you’re running a dev box with plenty of memory it is the simplest and gives you the best “umph” when running your various instances with the least amount of work.
5 Comments
Jack
4/4/2013 02:45:30 am
This is very intuitive! I liked how thorough you were!
Reply
Alex Li
7/8/2014 05:10:41 am
Great tutorial. This helped me solve a problem I was stuck on for days!
Reply
Tunio
2/18/2015 08:22:33 pm
Good one !
Reply
Supriya Gupta
6/7/2016 04:33:23 am
awesome explanation!!helped me in resolving my issue..thanks!!
Reply
manikandan
6/22/2017 12:35:38 pm
good 1 !!!
Reply
Leave a Reply. |
Categories
All
Archives
March 2017
|