tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Patrick Flaherty <pflah...@rampageinc.com>
Subject Re: Setting initial memory for a Tomcat Windows Service
Date Tue, 18 Sep 2012 15:29:01 GMT

On Sep 18, 2012, at 10:11 AM, David kerber wrote:

> On 9/18/2012 10:03 AM, Patrick Flaherty wrote:
>> Hello,
>>
>> Is this a bug or am I doing this wrong ?
>
> I'm not totally sure what you're asking about, but I have found that  
> tomcat7w does not always reflect the current settings if you have  
> made changes.  IIRC, I usually need to restart it to get it to pick  
> up changes.  The other option is to look in the registry for the  
> values; the changes will appear there by hitting Refresh.

I'm am looking at the registry keys and they are not changing. If I  
use tomcatw.exe and make the change to max mem then I see the registry  
change to reflect the
change I make in the interface.

But I need to configure this via command-line !


>
>
>>
>> Thanks again,
>> Pat
>>
>>
>> Begin forwarded message:
>>
>>> From: Patrick Flaherty <pflahrty@rampageinc.com>
>>> Date: September 13, 2012 6:19:34 PM EDT
>>> To: "Tomcat Users List" <users@tomcat.apache.org>
>>> Subject: Re: Setting initial memory for a Tomcat Windows Service
>>>
>>>
>>> On Sep 13, 2012, at 5:37 PM, Christopher Schultz wrote:
>>>
>>>> -----BEGIN PGP SIGNED MESSAGE-----
>>>> Hash: SHA1
>>>>
>>>> Patrick,
>>>>
>>>> On 9/13/12 11:41 AM, Patrick Flaherty wrote:
>>>>> I'm trying to change the max memory (java heap -Xmx) using
>>>>> Tomcat's //US// switch. I type it according to the Windows service
>>>>> how-to. We would like to script this into our Tomcat deployment
>>>>> script which right now simply installs the service using "service
>>>>> install".
>>>>>
>>>>> With the service already installed I tried the following command
>>>>> line options:
>>>>>
>>>>> tomcat7.exe //US//tomcat7 --JvmMs=512 --JvmMx=1024
>>>>
>>>> Hmm.
>>>>
>>>>> tomcat7.exe //US//tomcat7 --JvmOptions -Xms512m -Xmx1024m
>>>>>
>>>>> Although I get no error, I know its not taking because after
>>>>> starting tomcat.exe I look in the Windows process manager and it
>>>>> shows its only using 50MB of ram instead of 512MB of ram (the -Xms
>>>>> value)
>>>>
>>>> Silly question: how do you start Tomcat? (tomcat.exe does not  
>>>> exist).
>>>
>>> It's a Windows service. While testing this I'm just using the  
>>> Services
>>> Control Manager to stop and start the service.
>>>>
>>>>> Any help would be greatly appreciated.
>>>>
>>>> You didn't follow the instructions for --JvmOptions:
>>>> http://tomcat.eu.apache.org/tomcat-7.0-doc/windows-service-howto.html
>>>
>>> I did follow the instructions. There are options for *just* min/max
>>> heap size (JvmMS & JvmMx)
>>>>
>>>> You want:
>>>>
>>>> - --JvmOptions -Xms=512#-Xmx=1024
>>>
>>> No, this did not work.
>>>
>>>>
>>>> After you do either of your commands, what do you see if you do:
>>>>
>>>> C:\> tomcat7w.exe //ES//tomcat7
>>>
>>> I'm just launching tomcat7w.exe in Windows and checking the Java tab
>>> to see if it took.
>>>
>>>>
>>>> That should show you the current configuration (and let you edit
>>>> everything if you want).
>>>>
>>>> Remember that you are only editing the service definition: you will
>>>> have to launch Tomcat via the service if you want that  
>>>> configuration
>>>> to take effect. Also, if Tomcat is running when you change the
>>>> configuration, you'll have to restart the service to notice any  
>>>> change.
>>>>
>>>> - -chris
>>>> -----BEGIN PGP SIGNATURE-----
>>>> Version: GnuPG/MacGPG2 v2.0.17 (Darwin)
>>>> Comment: GPGTools - http://gpgtools.org
>>>> Comment: Using GnuPG with Mozilla - http://www.enigmail.net/
>>>>
>>>> iEYEARECAAYFAlBSUhAACgkQ9CaO5/Lv0PBzPgCePlVSr8zUutRBQleANxuTXNBw
>>>> WFQAoK+cTorm2zEbfAdgnfgMzNz6ouWi
>>>> =XEix
>>>> -----END PGP SIGNATURE-----
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>>>> For additional commands, e-mail: users-help@tomcat.apache.org
>>>>
>>>
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>


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


Mime
View raw message