You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Matthias Müller <mm...@googlemail.com> on 2012/09/20 11:41:57 UTC
Setting JVM Parameters in Windows Service for Tomcat7
Hi,
I want to set JVM Parameters in a Windows Service (Windows7) for
Tomcat7 (7.0.30)
The documentation tells, that this could be done by calling "tomcat7
//US//Tomcat7 ..."
This method works, but it is not practicable for our production
environment, because these settings are stored in the registry.
Is it possible to specify these parameters in setenv.bat or somewhere else?
When I start tomcat with "catalina.bat run" the setenv.bat is read.
But when I start tomcat as a windows service the setenv.bat is ignored.
Matthias
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
André,
On 9/22/12 3:36 PM, André Warnier wrote:
> Patrick Flaherty wrote:
>> Is this a Windows platform ?
>
> :-) If you manage to run tomcat.exe on a platform other than
> Windows, let us know. It would greatly simplify the Tomcat
> releases.
I wonder if any of this makes any sense under Wine. I dunno why
anyone, given the choice, would run the win32-version of something in
an environment where Wine is being used when the outside environment
is likely to provide superior support, but I've heard of stranger
things in the IT world before.
- -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/
iEYEARECAAYFAlBgsEoACgkQ9CaO5/Lv0PBMVgCgou+uminujuA05wzY8s/fWdpV
+/YAn0M5ybbM1cv7vXfSkQ+uEOWfMdXo
=Max9
-----END PGP SIGNATURE-----
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by André Warnier <aw...@ice-sa.com>.
Patrick Flaherty wrote:
> Hi Mikolaj,
>
> Is this a Windows platform ?
:-) If you manage to run tomcat.exe on a platform other than Windows, let us know.
It would greatly simplify the Tomcat releases.
>
> -Pat
>
> On Sep 20, 2012, at 10:16 AM, Mikolaj Rydzewski wrote:
>
>> On 20.09.2012 15:59, Patrick Flaherty wrote:
>>
>>> Have you tried this and gotten it to work ? My check to see if it
>>> took has been to open tomcatw.exe and check the values there.
>>> No matter what I've tried I cannot get it to take.
>>
>> Yes, it works for me in both ways (either via CLI or GUI).
>> In fact I use ant script to modify service parameters (please forgive
>> broken lines):
>>
>> <target name="update-tomcat-service">
>> <exec executable="${root}\\bin\\tomcat6.exe" dir="${root}\\bin">
>> <arg line="//US//Tomcat6 --Startup=auto --JvmMs
>> ${tomcat.memory.size} --JvmMx ${tomcat.memory.size} --StartPath
>> "${root}" --JvmOptions
>> -Dcom.sun.management.jmxremote;-verbose:gc;-XX:-DisableExplicitGC;-XX:+PrintGCTimeStamps;-XX:+PrintGCDetails;-Xloggc:logs\gc.log;-XX:+HeapDumpOnOutOfMemoryError;-XX:HeapDumpPath=logs;-XX:+UseConcMarkSweepGC;-XX:+UseParNewGC;-XX:+CMSClassUnloadingEnabled;-XX:MaxPermSize=256m"/>
>>
>> </exec>
>> </target>
>>
>>
>> --
>> Mikolaj Rydzewski <mi...@ceti.pl>
>>
>> ---------------------------------------------------------------------
>> 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
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by David kerber <dc...@verizon.net>.
On 9/20/2012 3:02 PM, Matthias Müller wrote:
> Hi,
>
>> Environment variables are irrelevant when running services. That's why
>> the registry values exist.
>
> That's a good point!
> Thanks for the nice discussion.
>
>> Matthias - can you please elaborate on exactly what "it is not practicable
>> for our production environment" means?
>
> I want to put the configuration files and property settings in a local
> VCS (e.g. a local git) so that I can track the changes.
> But now I see, that there are some technical reasons for using the registry.
> I think I will use a batch-script then which sets the registry.
>
> Matthias
>
> PS
> There are two ways of setting the registry:
>
> 1. CLI via "tomcat.exe //US//Tomcat7 ..."
> There are some examples in the service.bat file.
> 2. gui via tomcatw.exe
>
> But I think both ways are not compatible.
> I.E. when using "tomcat.exe //US//Tomcat7" I won't find the values in
> tomcatw.exe
I think you will if you completely stop and restart tomcatw.exe, but not
if you leave it running while making the changes.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
RE: Setting JVM Parameters in Windows Service for Tomcat7
Posted by Jeffrey Janner <Je...@PolyDyne.com>.
> -----Original Message-----
> From: Matthias Müller [mailto:mm4242@googlemail.com]
> Sent: Thursday, September 20, 2012 2:02 PM
> To: Tomcat Users List
> Subject: Re: Setting JVM Parameters in Windows Service for Tomcat7
>
> Hi,
>
> >Environment variables are irrelevant when running services. That's why
> >the registry values exist.
>
> That's a good point!
> Thanks for the nice discussion.
>
> > Matthias - can you please elaborate on exactly what "it is not
> > practicable for our production environment" means?
>
> I want to put the configuration files and property settings in a local
> VCS (e.g. a local git) so that I can track the changes.
> But now I see, that there are some technical reasons for using the
> registry.
> I think I will use a batch-script then which sets the registry.
>
> Matthias
>
> PS
> There are two ways of setting the registry:
>
> 1. CLI via "tomcat.exe //US//Tomcat7 ..."
> There are some examples in the service.bat file.
> 2. gui via tomcatw.exe
>
> But I think both ways are not compatible.
> I.E. when using "tomcat.exe //US//Tomcat7" I won't find the values in
> tomcatw.exe But that's not a problem for me.
Not to nitpick, but there is a 3rd way. (Not that I'd really recommend it for someone who can't get the Tomcat GUI to work for them.)
Use regedit to export the Procrun branch of the registry tree to a "registry merge file", which you can then modify with notepad.exe. Then all you have to do is double-click the merge file to have the setting replace those in the registry.
Remember, I don't recommend this unless you really know what you're doing. It's by far easier to use the GUI.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by Patrick Flaherty <pf...@rampageinc.com>.
On Sep 20, 2012, at 3:02 PM, Matthias Müller wrote:
> Hi,
>
>> Environment variables are irrelevant when running services. That's
>> why
>> the registry values exist.
>
> That's a good point!
> Thanks for the nice discussion.
>
>> Matthias - can you please elaborate on exactly what "it is not
>> practicable
>> for our production environment" means?
>
> I want to put the configuration files and property settings in a local
> VCS (e.g. a local git) so that I can track the changes.
> But now I see, that there are some technical reasons for using the
> registry.
> I think I will use a batch-script then which sets the registry.
>
> Matthias
>
> PS
> There are two ways of setting the registry:
>
> 1. CLI via "tomcat.exe //US//Tomcat7 ..."
> There are some examples in the service.bat file.
> 2. gui via tomcatw.exe
>
> But I think both ways are not compatible.
> I.E. when using "tomcat.exe //US//Tomcat7" I won't find the values in
> tomcatw.exe
> But that's not a problem for me.
I do not see the compatibility issue you describe. When I was
struggling to get the command-line (tomcat7.exe //US//) to work. I was
using the tomcatw.exe
GUI to see if my command-line was taking (I also check the registry).
Now that I have figured out how to change the min/max heap via the
command-line
I use tomcatw.exe and it reflects any change I make via the command-
line. At least that is my experience.
>
> ---------------------------------------------------------------------
> 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
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by Matthias Müller <mm...@googlemail.com>.
Hi,
>Environment variables are irrelevant when running services. That's why
>the registry values exist.
That's a good point!
Thanks for the nice discussion.
> Matthias - can you please elaborate on exactly what "it is not practicable
> for our production environment" means?
I want to put the configuration files and property settings in a local
VCS (e.g. a local git) so that I can track the changes.
But now I see, that there are some technical reasons for using the registry.
I think I will use a batch-script then which sets the registry.
Matthias
PS
There are two ways of setting the registry:
1. CLI via "tomcat.exe //US//Tomcat7 ..."
There are some examples in the service.bat file.
2. gui via tomcatw.exe
But I think both ways are not compatible.
I.E. when using "tomcat.exe //US//Tomcat7" I won't find the values in
tomcatw.exe
But that's not a problem for me.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Martin,
On 9/20/12 11:37 AM, Martin Gainty wrote:
> if passing the -D options are not working for you when running
> service why not SET JAVA_OPTS=-Xms1024m -Xmx1024m
>
> and then run the service?
Environment variables are irrelevant when running services. That's why
the registry values exist.
> net start will *usually* display running services so you can see if
> TC star
I don't think he's having a problem starting Tomcat. Just having a
problem applying his preferred parameters to the JVM.
- -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/
iEYEARECAAYFAlBbO9MACgkQ9CaO5/Lv0PA1qgCbByLNXB642fmUh+Yrvh/maV4v
EAUAn1SE2EuW5B0AojEZ8xMpO7gPV+fa
=75x5
-----END PGP SIGNATURE-----
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
RE: Setting JVM Parameters in Windows Service for Tomcat7
Posted by Martin Gainty <mg...@hotmail.com>.
Hi Patrick
if passing the -D options are not working for you when running service why not
SET JAVA_OPTS=-Xms1024m -Xmx1024m
and then run the service?
net start will *usually* display running services so you can see if TC star
Martin Gainty
______________________________________________
Verzicht und Vertraulichkeitanmerkung/Note de déni et de confidentialité
Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene Empfaenger sein, so bitten wir hoeflich um eine Mitteilung. Jede unbefugte Weiterleitung oder Fertigung einer Kopie ist unzulaessig. Diese Nachricht dient lediglich dem Austausch von Informationen und entfaltet keine rechtliche Bindungswirkung. Aufgrund der leichten Manipulierbarkeit von E-Mails koennen wir keine Haftung fuer den Inhalt uebernehmen.
Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas le destinataire prévu, nous te demandons avec bonté que pour satisfaire informez l'expéditeur. N'importe quelle diffusion non autorisée ou la copie de ceci est interdite. Ce message sert à l'information seulement et n'aura pas n'importe quel effet légalement obligatoire. Étant donné que les email peuvent facilement être sujets à la manipulation, nous ne pouvons accepter aucune responsabilité pour le contenu fourni.
> Date: Thu, 20 Sep 2012 16:47:05 +0200
> From: miki@ceti.pl
> To: users@tomcat.apache.org
> Subject: Re: Setting JVM Parameters in Windows Service for Tomcat7
>
> On 20.09.2012 16:39, Patrick Flaherty wrote:
>
> > Is this a Windows platform ?
>
> Looking at the path I suppose so :-)
>
> "${root}\\bin\\tomcat6.exe"
>
> --
> Mikolaj Rydzewski <mi...@ceti.pl>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by Mikolaj Rydzewski <mi...@ceti.pl>.
On 20.09.2012 16:39, Patrick Flaherty wrote:
> Is this a Windows platform ?
Looking at the path I suppose so :-)
"${root}\\bin\\tomcat6.exe"
--
Mikolaj Rydzewski <mi...@ceti.pl>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by Patrick Flaherty <pf...@rampageinc.com>.
Hi Mikolaj,
Is this a Windows platform ?
-Pat
On Sep 20, 2012, at 10:16 AM, Mikolaj Rydzewski wrote:
> On 20.09.2012 15:59, Patrick Flaherty wrote:
>
>> Have you tried this and gotten it to work ? My check to see if it
>> took has been to open tomcatw.exe and check the values there.
>> No matter what I've tried I cannot get it to take.
>
> Yes, it works for me in both ways (either via CLI or GUI).
> In fact I use ant script to modify service parameters (please
> forgive broken lines):
>
> <target name="update-tomcat-service">
> <exec executable="${root}\\bin\\tomcat6.exe" dir="${root}\
> \bin">
> <arg line="//US//Tomcat6 --Startup=auto --JvmMs $
> {tomcat.memory.size} --JvmMx ${tomcat.memory.size} --StartPath "
> ${root}" --JvmOptions -Dcom.sun.management.jmxremote;-
> verbose:gc;-XX:-DisableExplicitGC;-XX:+PrintGCTimeStamps;-XX:
> +PrintGCDetails;-Xloggc:logs\gc.log;-XX:+HeapDumpOnOutOfMemoryError;-
> XX:HeapDumpPath=logs;-XX:+UseConcMarkSweepGC;-XX:+UseParNewGC;-XX:
> +CMSClassUnloadingEnabled;-XX:MaxPermSize=256m"/>
> </exec>
> </target>
>
>
> --
> Mikolaj Rydzewski <mi...@ceti.pl>
>
> ---------------------------------------------------------------------
> 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
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by Patrick Flaherty <pf...@rampageinc.com>.
Hi Mikolaj,
I got it to work. I was not using a space after the --JvmMs and --
JvmMx switches.
So in summary the following works: \tomcat7.exe //US//tomcat7 --JvmMs
512 --JvmMx 1024
Thanks for everyone's help.
-Pat
On Sep 20, 2012, at 10:16 AM, Mikolaj Rydzewski wrote:
> On 20.09.2012 15:59, Patrick Flaherty wrote:
>
>> Have you tried this and gotten it to work ? My check to see if it
>> took has been to open tomcatw.exe and check the values there.
>> No matter what I've tried I cannot get it to take.
>
> Yes, it works for me in both ways (either via CLI or GUI).
> In fact I use ant script to modify service parameters (please
> forgive broken lines):
>
> <target name="update-tomcat-service">
> <exec executable="${root}\\bin\\tomcat6.exe" dir="${root}\
> \bin">
> <arg line="//US//Tomcat6 --Startup=auto --JvmMs $
> {tomcat.memory.size} --JvmMx ${tomcat.memory.size} --StartPath "
> ${root}" --JvmOptions -Dcom.sun.management.jmxremote;-
> verbose:gc;-XX:-DisableExplicitGC;-XX:+PrintGCTimeStamps;-XX:
> +PrintGCDetails;-Xloggc:logs\gc.log;-XX:+HeapDumpOnOutOfMemoryError;-
> XX:HeapDumpPath=logs;-XX:+UseConcMarkSweepGC;-XX:+UseParNewGC;-XX:
> +CMSClassUnloadingEnabled;-XX:MaxPermSize=256m"/>
> </exec>
> </target>
>
>
> --
> Mikolaj Rydzewski <mi...@ceti.pl>
>
> ---------------------------------------------------------------------
> 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
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by Mikolaj Rydzewski <mi...@ceti.pl>.
On 20.09.2012 15:59, Patrick Flaherty wrote:
> Have you tried this and gotten it to work ? My check to see if it
> took has been to open tomcatw.exe and check the values there.
> No matter what I've tried I cannot get it to take.
Yes, it works for me in both ways (either via CLI or GUI).
In fact I use ant script to modify service parameters (please forgive
broken lines):
<target name="update-tomcat-service">
<exec executable="${root}\\bin\\tomcat6.exe"
dir="${root}\\bin">
<arg line="//US//Tomcat6 --Startup=auto --JvmMs
${tomcat.memory.size} --JvmMx ${tomcat.memory.size} --StartPath
"${root}" --JvmOptions
-Dcom.sun.management.jmxremote;-verbose:gc;-XX:-DisableExplicitGC;-XX:+PrintGCTimeStamps;-XX:+PrintGCDetails;-Xloggc:logs\gc.log;-XX:+HeapDumpOnOutOfMemoryError;-XX:HeapDumpPath=logs;-XX:+UseConcMarkSweepGC;-XX:+UseParNewGC;-XX:+CMSClassUnloadingEnabled;-XX:MaxPermSize=256m"/>
</exec>
</target>
--
Mikolaj Rydzewski <mi...@ceti.pl>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by Patrick Flaherty <pf...@rampageinc.com>.
On Sep 20, 2012, at 9:25 AM, Brett Delle Grazie wrote:
> On 20 September 2012 13:53, Mikolaj Rydzewski <mi...@ceti.pl> wrote:
>> On 20.09.2012 14:49, Patrick Flaherty wrote:
>>
>>> I sent a question out a few days ago that I could *not* get the JVM
>>> Parameters set via the command-line using //US//.
>>>
>>> Can you give me an example of the syntax that worked for you ? I'm
>>> just looking to set the min/max heap sizes.
>>
>>
>> http://commons.apache.org/daemon/procrun.html
>>
>> Syntax is not so easy to use.
>> The easiest way is to use tomcatw.exe - unless you have to use CLI.
>
> http://tomcat.apache.org/tomcat-7.0-doc/windows-service-howto.html
>
> The default service name is 'Tomcat7' so presuming %CATALINA_HOME%
> represents the tomcat home directory:
> Note that for updating the service via command line you need to use
> tomcat7.exe not tomcat7w.exe
> so to increase your default heap size from 256 to 512 Mb you would
> use:
> %CATALINA_HOME%/bin/tomcat.exe //US//Tomcat7 --JvmMx=512
Hi Mikolaj,
Have you tried this and gotten it to work ? My check to see if it took
has been to open tomcatw.exe and check the values there.
No matter what I've tried I cannot get it to take.
Thanks
Pat
>
>>
>> --
>> Mikolaj Rydzewski <mi...@ceti.pl>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>
> --
> Best Regards,
>
> Brett Delle Grazie
>
> ---------------------------------------------------------------------
> 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
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by Brett Delle Grazie <br...@gmail.com>.
On 20 September 2012 13:53, Mikolaj Rydzewski <mi...@ceti.pl> wrote:
> On 20.09.2012 14:49, Patrick Flaherty wrote:
>
>> I sent a question out a few days ago that I could *not* get the JVM
>> Parameters set via the command-line using //US//.
>>
>> Can you give me an example of the syntax that worked for you ? I'm
>> just looking to set the min/max heap sizes.
>
>
> http://commons.apache.org/daemon/procrun.html
>
> Syntax is not so easy to use.
> The easiest way is to use tomcatw.exe - unless you have to use CLI.
http://tomcat.apache.org/tomcat-7.0-doc/windows-service-howto.html
The default service name is 'Tomcat7' so presuming %CATALINA_HOME%
represents the tomcat home directory:
Note that for updating the service via command line you need to use
tomcat7.exe not tomcat7w.exe
so to increase your default heap size from 256 to 512 Mb you would use:
%CATALINA_HOME%/bin/tomcat.exe //US//Tomcat7 --JvmMx=512
>
> --
> Mikolaj Rydzewski <mi...@ceti.pl>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
--
Best Regards,
Brett Delle Grazie
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by Mikolaj Rydzewski <mi...@ceti.pl>.
On 20.09.2012 14:49, Patrick Flaherty wrote:
> I sent a question out a few days ago that I could *not* get the JVM
> Parameters set via the command-line using //US//.
>
> Can you give me an example of the syntax that worked for you ? I'm
> just looking to set the min/max heap sizes.
http://commons.apache.org/daemon/procrun.html
Syntax is not so easy to use.
The easiest way is to use tomcatw.exe - unless you have to use CLI.
--
Mikolaj Rydzewski <mi...@ceti.pl>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by Patrick Flaherty <pf...@rampageinc.com>.
HI Matthias,
I sent a question out a few days ago that I could *not* get the JVM
Parameters set via the command-line using //US//.
Can you give me an example of the syntax that worked for you ? I'm
just looking to set the min/max heap sizes.
Thanks
Pat
On Sep 20, 2012, at 5:41 AM, Matthias Müller wrote:
> Hi,
>
> I want to set JVM Parameters in a Windows Service (Windows7) for
> Tomcat7 (7.0.30)
>
> The documentation tells, that this could be done by calling "tomcat7
> //US//Tomcat7 ..."
> This method works, but it is not practicable for our production
> environment, because these settings are stored in the registry.
>
> Is it possible to specify these parameters in setenv.bat or
> somewhere else?
> When I start tomcat with "catalina.bat run" the setenv.bat is read.
> But when I start tomcat as a windows service the setenv.bat is
> ignored.
>
> Matthias
>
> ---------------------------------------------------------------------
> 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
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by je...@bull.net.
Hi Matthias,
Mikolaj is right, you can set the tomcat and java properties by running tomcatw.exe (%CATALINA_HOME%\bin)
Hope this helps
Jean-Louis
-----Matthias Müller <mm...@googlemail.com> a écrit : -----
A : users@tomcat.apache.org
De : Matthias Müller <mm...@googlemail.com>
Date : 20/09/2012 11:57
Objet : Setting JVM Parameters in Windows Service for Tomcat7
Hi,
I want to set JVM Parameters in a Windows Service (Windows7) for
Tomcat7 (7.0.30)
The documentation tells, that this could be done by calling "tomcat7
//US//Tomcat7 ..."
This method works, but it is not practicable for our production
environment, because these settings are stored in the registry.
Is it possible to specify these parameters in setenv.bat or somewhere else?
When I start tomcat with "catalina.bat run" the setenv.bat is read.
But when I start tomcat as a windows service the setenv.bat is ignored.
Matthias
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by chris derham <ch...@derham.me.uk>.
>
> The documentation tells, that this could be done by calling "tomcat7
> //US//Tomcat7 ..."
> This method works, but it is not practicable for our production
> environment, because these settings are stored in the registry.
>
> Matthias - can you please elaborate on exactly what "it is not practicable
for our production environment" means?
Thanks
Chris
Re: Setting JVM Parameters in Windows Service for Tomcat7
Posted by Mikolaj Rydzewski <mi...@ceti.pl>.
On 20.09.2012 11:41, Matthias Müller wrote:
> The documentation tells, that this could be done by calling "tomcat7
> //US//Tomcat7 ..."
> This method works, but it is not practicable for our production
> environment, because these settings are stored in the registry.
>
> Is it possible to specify these parameters in setenv.bat or somewhere
> else?
> When I start tomcat with "catalina.bat run" the setenv.bat is read.
> But when I start tomcat as a windows service the setenv.bat is
> ignored.
There's helper application (tomcat.exe or tomcatw.exe, I always forget
which one is which) located in bin folder. You can specify service
properties there.
--
Mikolaj Rydzewski <mi...@ceti.pl>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org