The answer I expected is the JVM grows as much as to the available system 
memory of there are m min and max set.

-Gokul

Sent from iPhone

> On Feb 22, 2016, at 2:43 AM, André Warnier (tomcat) <a...@ice-sa.com> wrote:
> 
>> On 22.02.2016 03:44, Gokul.Baskaran wrote:
>> Thanks again, to make things clear. When I meant default, what is the 
>> default min and max that is given to an application if there nothing defined 
>> in the JVM ?
> 
> In how many different ways do you need to be told this ?
> Re-read the previous answers that you already received.  All the information 
> is there.
> 
>> In my case, the Tomcat is running on windows and I don't have setenv.bat or 
>> sentenv.sh or even catalina.bat and catalina.conf does not have the OPT 
>> config for min and max. HTH
>> 
>> Thank you
>> 
>> -Gokul
>> 
>> 
>> -----Original Message-----
>> From: Olaf Kock [mailto:tom...@olafkock.de]
>> Sent: Sunday, February 21, 2016 3:04 PM
>> To: Tomcat Users List <users@tomcat.apache.org>
>> Subject: Re: Tomcat memory
>> 
>> grep mx bin/* found only settings in setenv.sh in my installation - this 
>> lets me state that there are no defaults: setenv.sh is not contained in the 
>> distribution but will be read in case it's found in the file system.
>> Thus there's no tomcat default that I'm aware of. Anybody who distributes 
>> tomcat with a setenv.sh might have a sensible default for their embedded 
>> application, but the raw distribution AFAIK has none.
>> 
>> Safe assumption should be: Whatever the JVM thinks is appropriate is the 
>> default.
>> 
>> Create a setenv.sh or setenv.bat and set CATALINA_OPTS to the desired value, 
>> e.g. "-Xms 2048m -Xmx2048m" (but there will probably be more settings, e.g. 
>> for tuning the garbage collector...
>> 
>> (apologies in case this goes out after the problem has long been solved:
>> I'm in a hotel that blocks SMTP and have to find a way to send mail from
>> here)
>> 
>> Olaf
>> 
>>> Am 21.02.2016 um 18:23 schrieb Gokul.Baskaran:
>>> Question was for Java 7
>>> 
>>> It is a Tomcat / Application question as well, as memory default can be 
>>> configured in the application config.
>>> 
>>> I totally agree that the best practice is to set the Xms and -Xmx. As am 
>>> going to change the config, I would curious to know if the tomcat ui or the 
>>> catalina does not have a Xms and -Xmx, would it default to 400MB? I read 
>>> this in another forum.
>>> 
>>> -Gokul
>>> 
>>> 
>>> -----Original Message-----
>>> From: Olaf Kock [mailto:tom...@olafkock.de]
>>> Sent: Sunday, February 21, 2016 3:14 AM
>>> To: Tomcat Users List <users@tomcat.apache.org>
>>> Subject: Re: Tomcat memory
>>> 
>>> This is rather a Java than a tomcat question:
>>> 
>>> The JVM allocates memory based on whatever default your current JVM
>>> version decides (you don't mention what version of Java you're on)
>>> 
>>> From a text on
>>> http://docs.oracle.com/javase/7/docs/technotes/guides/vm/gc-ergonomics
>>> .html
>>> that's linked from my Java's manpage:
>>> 
>>>     *initial heap size*
>>> 
>>>         Larger of 1/64th of the machine's physical memory on the machine
>>>         or some reasonable minimum. Before J2SE 5.0, the default initial
>>>         heap size was a reasonable minimum, which varies by platform.
>>>         You can override this default using the |-Xms| command-line option.
>>> 
>>>     *maximum heap size*
>>> 
>>>         Smaller of 1/4th of the physical memory or 1GB. Before J2SE 5.0,
>>>         the default maximum heap size was 64MB. You can override this
>>>         default using the |-Xmx| command-line option.
>>> 
>>>     *Note:* The boundaries and fractions given for the heap size are
>>>     correct for J2SE 5.0. They are likely to be different in subsequent
>>>     releases as computers get more powerful.
>>> 
>>> Note that this is from JavaSE7 and even mentions 5 - with more power there 
>>> comes more initial and maximum memory defaults.
>>> 
>>> I'm not aware of the actual development of the default memory - mostly
>>> because I consider it good practice to know what an application uses
>>> and provide it explicitly, rather than relying on defaults. (and
>>> frankly, on the applications that I see, the default typically is not
>>> even enough - let alone a good basis for tuning)
>>> 
>>> While we're at it: For production systems I consider it good practice to 
>>> set -Xms and -Xmx to the same value. Reason: If you don't have enough 
>>> memory available, you want to know this when the process starts, not days 
>>> later when it tries to allocate "the rest" - typically sunday night at 3am.
>>> 
>>> Olaf
>>> 
>>>> Am 21.02.2016 um 03:39 schrieb Gokul.Baskaran:
>>>> Hi,
>>>> 
>>>> I am currently running tomcat 7 in Windows 2012.
>>>> 
>>>> The current JVM Heap memory parameters are set to empty, does the JVM Heap 
>>>> memory utilize the entire memory of the OS or does it default to a 
>>>> specific memory number?
>>>> 
>>>> Thank you
>>>> -Gokul
>>> 
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
>>> For additional commands, e-mail: users-h...@tomcat.apache.org
>> 
>> 
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
>> For additional commands, e-mail: users-h...@tomcat.apache.org
>> 
>> 
>> 
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
>> For additional commands, e-mail: users-h...@tomcat.apache.org
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to