5 Replies Latest reply: Jan 8, 2013 5:18 AM by 890240 RSS

    Heap Size for weblogic Server


      Could you please let me know the recommended way to set the heap size for the managed weblogic server?

      If it is through setDomain.sh script,then where would i exactly set in it?
        • 1. Re: Heap Size for weblogic Server
          You can set the heap size in setDomainEnv.sh. Depending on the JDK used, you can modify the values in WLS_MEM_ARGS_64BIT or WLS_MEM_ARGS_32BIT.

          Another way to set the heap values is to modify the server start tab in the admin console and provide the -Xms and -Xmx values.

          You can also have a customized start script for each managed server and pass the heap values using JAVA_OPTIONS.
          • 2. Re: Heap Size for weblogic Server
            Kalyan Pasupuleti-Oracle
            Hi Guru,

            whether you have 32 bit or 64 bit.

            if you are running with 32 bit then Make sure to have upto 2 GB as Heap in case of Jrockit or if you are running in Sun JDK we can set 1.5GB Heap.

            So you can set min Heap and Max heap as same.

            If you are running with 64 bit then we can go with any heap setting.

            let me know if you need any more.

            • 3. Re: Heap Size for weblogic Server
              Thanks a lot Namgi!!!!!!

              Could you please helpme by showing any example?

              Lets say if i need to set heap size of around 2 GB.how can i set it?

              • 4. Re: Heap Size for weblogic Server
                Hi Guru,

                Update the below entries in setDomainEnv.sh with the values which are recommended for your environment. This depends upon the JDK type (Sun or Jrockit) and if it is 32 bit or 64 bit.

                The below example is for Jrockit 64 bit version. If you are using 32 bit Jrockit, please update XMS_JROCKIT_32BIT and XMX_JROCKIT_32BIT. 2048 in MB here is 2 GB

                export XMS_JROCKIT_64BIT

                export XMX_JROCKIT_64BIT

                If the JDK is SUN, below are the settings to be updated.



                You can also update the heap settings from admin console.
                Environment --> servers --> <server_name> --> server start

                go to Arguments and enter

                -Xms2048m -Xmx2048m

                Please restart the JVM once you made changes to setDomainEnv.sh or through console to see the new heap settings.

                Madhu Ponamgi
                • 5. Re: Heap Size for weblogic Server
                  Thanks a lot Madhu.