Hello,

> -----Ursprüngliche Nachricht-----
> Von: Kumawat, Priyanka <priyanka.kuma...@dxc.com>
> Gesendet: Donnerstag, 29. September 2022 22:28
> An: Tomcat Users List <users@tomcat.apache.org>
> Betreff: RE: AW: MaxRequestWorkers error
> 
> Hi Thomas,
> 
> -> How much memory did you configure for your java environment? -->
> 
> -Xms4096m -Xmx8192m

This depends on the application and the server memory.
Every application is different. Depends on what they keep in memory. Some 
application eat a lot of memory, some less.
Maybe you can take a look at the requirements or ask developer if possible.

> -> Parameter If the java process eats too much memory, you can write a
> memory dump when an OOM exception occurs.
> 
> Do we need to run this cmd with the startup.sh tomcat cmd , or can we run
> this directly on server , before restarting the tomcat during OOM error.
> 
> -XX:+HeapDumpOnOutOfMemoryError -
> XX:HeapDumpPath=/opt/tomcat/apache-tomcat-8.5.5/logs/javadump.dmp
> 

All the -X... stuff are startup parameters / variables. Usually set via 
setenv.sh.
Please check e.g. 
https://crunchify.com/how-to-change-jvm-heap-setting-xms-xmx-of-tomcat/ 

> Also can we use the cmd's also for generating heap and thread dumps ,
> please suggest are these cmd's useful for these error condition.
> 
> kill -3 PID
> 
> /opt/tomcat/jdk1.8.0_121/bin
> ./jmap -F -dump:format=b,file=/tmp/heap.bin PID ./jmap -F -
> dump:format=b,file=/tmp/heap.hpof PID
> 

Kill and jmap can dump the memory during runtime, yes.
However you need tools like MAT https://www.eclipse.org/mat/ and the dumps in 
general are useful for the developers of the app.


> The below is the current memory foot print on the prod server now -
> 
> tomcat@[/tmp]$ free -m
>              total       used       free     shared    buffers     cached
> Mem:         32109      31422        687         69       1185      15452
> -/+ buffers/cache:      14783      17325
> Swap:        16383          0      16383
> tomcat@[/tmp]$ free -m
>              total       used       free     shared    buffers     cached
> Mem:         32109      31422        687         69       1185      15452
> -/+ buffers/cache:      14783      17325
> Swap:        16383          0      16383
> tomcat@[/tmp]$ free -m
>              total       used       free     shared    buffers     cached
> Mem:         32109      31422        687         69       1185      15452
> -/+ buffers/cache:      14783      17325
> Swap:        16383          0      16383
> 
> 
> > > You can also open a JMX port and inspect the memory using during
> > > runtime, e.g. with VirtualVM
> 
> We are still trying this option to get run , this is asking to have java 1.8 
> or
> higher , can we use any other option to check the Memory during runtime?.


VisualVM is best in my point of view. Don’t you have Java 8 or higher running?


> 
> Please suggest . Thankyou !
> 
> 
> Thanks & Regards,
> 
> Priyanka Kumawat | Middleware Admin
> T +91.7879364483
> EMail - priyanka.kuma...@dxc.com
> DL - ams-leveraged-webadmin-offsh...@dxc.com
> 
> DXC Technology
> 
> 
> 
> 
> 
> 
> 
> 
> -----Original Message-----
> From: Thomas Hoffmann (Speed4Trade GmbH)
> <thomas.hoffm...@speed4trade.com.INVALID>
> Sent: 28 September 2022 12:02
> To: Tomcat Users List <users@tomcat.apache.org>
> Subject: AW: AW: MaxRequestWorkers error
> 
> 
> 
> > -----Ursprüngliche Nachricht-----
> > Von: Rob Sargent <rsarg...@xmission.com>
> > Gesendet: Dienstag, 27. September 2022 23:26
> > An: users@tomcat.apache.org
> > Betreff: Re: AW: MaxRequestWorkers error
> >
> >
> >
> > On 9/27/22 14:37, Thomas Hoffmann (Speed4Trade GmbH) wrote:
> > >
> > > How much memory did you configure for your java environment? -->
> Xmx
> > > Parameter If the java process eats too much memory, you can write a
> > memory dump when an OOM exception occurs.
> > > E.g. with the parameters: -XX:+HeapDumpOnOutOfMemoryError -
> > XX:HeapDumpPath=/var/logs/javadump.dmp"
> > > You can also open a JMX port and inspect the memory using during
> > > runtime, e.g. with VirtualVM
> > >
> https://clicktime.symantec.com/15tStaehQas9svtdpJ83n?h=sL3qdTIGckj1F
> > > A6lY59OUlcDtGbnfGtyeXufk7TPq70=&u=https://visualvm.github.io/
> > >
> > Pretty sure Thomas mean "VisualVM"
> 
> Of course :)
> Link was right, name was wrong.
> 
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> > For additional commands, e-mail: users-h...@tomcat.apache.org
> 
> B
> KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
> KKKKKKKKKKCB  [  X  ܚX KK[XZ[  \ \  ][  X  ܚX P X ]  \X K ܙ B
> ܈Y][ۘ[  [X[  K[XZ[  \ \  Z[ X ]  \X K ܙ B
> 
> 
> DXC Technology Company -- This message is transmitted to you by or on
> behalf of DXC Technology Company or one of its affiliates. It is intended
> exclusively for the addressee. The substance of this message, along with any
> attachments, may contain proprietary, confidential or privileged information
> or information that is otherwise legally exempt from disclosure. Any
> unauthorized review, use, disclosure or distribution is prohibited. If you are
> not the intended recipient of this message, you are not authorized to read,
> print, retain, copy or disseminate any part of this message. If you have
> received this message in error, please destroy and delete all copies and
> notify the sender by return e-mail. Regardless of content, this e-mail shall
> not operate to bind DXC Technology Company or any of its affiliates to any
> order or other contract unless pursuant to explicit written agreement or
> government initiative expressly permitting the use of e-mail for such
> purpose.
> B
> KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
> KKKKKKKKKKCB  [  X  ܚX KK[XZ[
> 
>  \ \  ][  X  ܚX P X ]
>  \X K ܙ B  ܈Y][ۘ[  [X[  K[XZ[
> 
>  \ \  Z[ X ]
>  \X K ܙ B

Reply via email to