Allocating more RAM to Apache Tomcat on Windows

posted by SpringSource on April 15, 2010 08:36 AM

If you've recently upgraded the RAM, or are moving your Tomcat applications to a larger box, you may want to update your allocated memory.

To find out how much RAM is allocated already to your Tomcat instance, if you have Tomcat installed as a Windows service, you can run Regedit and look at:

Apache Software Foundation
Procrun 2,0

Under that key will be all the tomcat service instances you have installed on that machine. If you expand an instance tree you will see another key named Parameters. Expand this and you will see a number of named values:

JvmMs - is the minimum memory, equivalent to -Xms
JvmMx - is the maximum memory equivalent to -Xmx
Options - any other java options you wish to set for this server.

When you run Tomcat as a service it calls the jvm.dll directly so anything you modify in one of the bat files will be disregarded. So you will need to set those options by changing those registry values. The default Tomcat configuration does not use any memory configuration. If you haven't set the -Xms or -Xmx parameters explicitly anywhere you will wind up with the JDK default which is 64M.

Be aware that even if you increase the physical memory size, if you are running 32 bit windows you won't be able to allocate over 2GB of memory per VM. On Win32 the max size for your heap is going to be 2 GB. While that is as big as it will be able to get on that platform, that does not necessarily mean that you will be able to allocate a 2GB heap. In order to achieve that, the JVM must be able to allocate that entire quantity in a set of contiguous addresses. Depending on what you have loaded, if there is anything loaded into memory that is not movable and interferes with allocating that block, it will fail to start and you'll have to reduce the size until it fits in what IS available.

There are a number of different ways to modify the memory settings for the JVM at Tomcat startup via the -Xmx and -Xms settings. 

You can set these (and other JVM parameters) in either the JAVA_OPTS or the CATALINA_OPTS in the set_env.bat. These can also be set via the Windows System Environment dialogs. If that has been done you can type set JAVA_OPTS OR set CATALINA_OPTS at the command prompt, and if they are set you will see them. Or they can be set from the command line before starting Tomcat (although if that was being done it wouldn't help you in this case). These can also be set in any of the called startup scripts such as startup.bat, catalina.bat, or set_env.bat. Do a text search through all the bat files and check to see whether the environment variables are being explicitly set somewhere there.

Normally, the quickest way to find out what the actual startup setting is would be to edit catalina.bat. 

Find the tag: doneSetArgs. Immediately after that add the line:


When you next type startup it will print out the exact command line being used to start Tomcat. If you see an -Xmx parameter, the value immediately after that will be your maximum memory for that instance. If you don't see that setting at all, it is the JVM default, 64M.

For more than 10 years, SpringSource employees have been supporting Apache technologies, with unparalleled experience and commitment to the Apache Software Foundation. More than 400 of the Fortune 500 count on SpringSource to support their mission-critical business applications. Leaders of the Apache Software Foundation, including Board Members, work at SpringSource and dedicate a significant amount of time further developing the Apache Tomcat open source project. Over the last 2 years, 95% of the issues fixed in the Apache Tomcat project were fixed by SpringSource engineers. For more information on how SpringSource can help your enterprise, see the SpringSource website, or call 800/444-1935.


Memory Allocation

What is the most amount of memory you could allocate to tomcat in a x64 OS?

And then secondly, what is the best way to allocate or set the values xmx, xms, permsize?


kami adalah

kami adlah perusahaan besi baja yang paling oke harga besi wf harga besi h beam harga besi cnp harga besi unp harga besi beton harga plat besi harga besi siku besi pipa besi


I am very enjoyed for this blog. Its an informative topic. It help me very much to solve some problems. Its opportunity are so fantastic and working style so speedy.

Thank you so much for the

Thank you so much for the post you do. I like your post and all you share with us is up to date and quite informative, i would like to bookmark the page so i can come here again to read you, as you have done a wonderful job.
visit here


I found this is an informative and interesting post so i think so it is very useful and knowledgeable. I would like to thank you for the efforts you have made in writing this article.
melatonina preço

Positive site, where did u

Positive site, where did u come up with the information on this posting?I have read a few of the articles on your website now, and I really like your style. Thanks a million and please keep up the effective work.
womens clothing

I just want to let you know

I just want to let you know that I just check out your site and I find it very interesting and informative..
find this


Your blog provided us with valuable information to work with. Each & every tips of your post are awesome. Thanks a lot for sharing. Keep blogging..
Mobile Phone Comparison

This is such a great resource

This is such a great resource that you are providing and you give it away for free. I love seeing blog that understand the value. Im glad to have found this post as its such an interesting one! I am always on the lookout for quality posts and articles so i suppose im lucky to have found this! I hope you will be adding more in the future...

This is such a great resource

This is such a great resource that you are providing and you give it away for free. I love seeing blog that understand the value. Im glad to have found this post as its such an interesting one! I am always on the lookout for quality posts and articles so i suppose im lucky to have found this! I hope you will be adding more in the future...

These can also be set via the

These can also be set via the Windows System Environment dialogs.

how to buy soundcloud plays

I am in same problem

Thanks for your wonderful tutorial.But need more explain how to upgrade ram.Some point are not clear so if you can explain that will be easy for us.
Aero Auto
Webs: Auto transport California

here i got the way to get

here i got the way to get marvel contest of champions hack with the hack and cheat

On unionized campuses, there

On unionized campuses, there may also be contractual limits on section size that were CAS-001 vce designed with the traditional model in mind but that do not make sense for a hybrid model. It is possible that these constraints would be changed in future contract negotiations, but that too will take time.


And he just bought me lunch since I found it for him smile Thus let me rephrase that: Thanks for lunch! amazon gift card generator

free itunes codes

such a fantastic site itunes gift card and free itunes codes generator to get for i phone,ios its really good work for any placefor music and songs,ringtone,photo shop keep it up! go to website for itunes codes online generator

good post

The purpose of posting this article is to aware the people that if you want to use Apache Tomcat with window then it Allocating more RAM to Apache Tomcat on Windows. So, Be confirm before using it that either your RAM is enough or not. Later you don't have any worry to take that system. This article is good for us. any how, I'm trying to get rushessay custom writing but as student of computer user like to read that article.


castle clash hack This is exciting, nevertheless it is vital for you to visit this specific url: clash of clans triche

Psn codes generator

They would build several legitimate rules all time through opening this ps4 System collection.

free psn codes

nice post

Now with LED lighting industry becoming more prosperous, more companies have started to look on top of the current e-commerce. The rapid growth of online shopping for the LED lighting industry sales channels provide a new possibility. Therefore, exploring the road of LED lighting industry, e-commerce is very important.
stadium lights


I enjoyed over read your blog post. Your blog have nice information, I got good ideas from this amazing blog. I am always searching like this type blog post. I hope I will see again..
animal jam| cool games| cool math games| 8 ball pool| sudoku| yoob| stickman games| unblocked games | shooting games| friv4school|
happy wheels| fighting games


Thanks for the great post. Pretty good post. I just stumbled upon your blog and wanted to say that I have really enjoyed reading your blog posts.
Visit to play: Agario jeu est un jeu affronte des milliers de concurrents. agario - agar io - agar - - agario jeu - agario - agar - - agar io - agario jeu


Although I do not fully understand the significance of your article but I still like it. It gives me something new and laughter. I just need so. Great. descargar facebook , descargar facebook , baixar whatsapp , descargar whatsapp , baixar whatsapp plus , baixar mobogenie gratis , mobogenie


Thank you for sharing. Your blog posts are more interesting and impressive. I think there are many people like and visit it regularly, including me. baixar facebook , baixar facebook , descargar facebook , descargar whatsapp gratis , descargar mobogenie gratis , baixar mobogenie gratis , messenger whatsapp


I also agree with your opinion. It is very deep and meaningful, I think you have to spend time to write it. facebook movel , whatsapp gratis , jogos de futebol , baixar facebook , baixar facebook


Java Training If you are using or considering using Apache Tomcat and would like to improve your knowledge, join Apache experts and committers Mark Thomas and Filip Hanik as they outline the top Tips and Tricks to make management and administration of Apache Tomcat easier, faster Java Training Courses Online Classroom teaches and more productive. Course curriculum


Java Training in Chennai



You are right I have just upgraded the RAM but did not understand how to transfer tompcat.Now i will try again to moving it.Lets see what happen.I will update you.
Website: Blueberries for dogs

Re: 2014 Football Outsiders Awards

This is very educational content and written well for a change. It's nice to see that some people still understand how to write a quality post.

Temple Run 2

I found lots of interesting information here.Great work
Thanks for the share loved reading the article, please do share more like this wiht us .

Temple Run 2
Run 3
Click Jogos


This is quite a nice and smart move, I did wonder a lot on why the same thing did not occur to my mind. I am sure that you will easily fall in love with what this will let you achieve. dish network

Packing and Moving Services

Packers and Movers Mumbai
Packers and Movers Pune
Packers and Movers Bangalore

Best Relocation Services

Packers and Movers Delhi
Packers and Movers Gurgaon
Packers and Movers Hyderabad


tanks fors sharink harga besi baja

Tomcat 6 Maximum and Minimum Memeory


I just want to know what are the thresholds for maximum and the minimum memory allocation capacities for Tomcat6.0.45 which runs on x64 Windows server 2012 R2 Standard. Can we exceed 4GB or 8GB capacities for maximum memory?

An early reply is appreciated


Love involves a peculiar unfathomable combination of understanding and misunderstanding.
mutant fighting cup 2 | manny pacquiao | stardew valley wiki | slitherio | powerpuff yourself | zumbi tsunami | fishdom | quotes about love |love quotes | chinese food near me | snake

Pretty good post

baixar Score Hero é um dos excelentse jogos de futebol para telemóveis e dispositivos que usam Android de 2 ou superior. Photo Grid baixar é um aplicativo de edição de foto, fazer colagem com muitos quadros atraentes.

kamu tidak akan memakai laptopmu dalam jangka waktu yang cukup lama, kamu juga harus memastikan
Klik start > type power > power options > change plan settings > change advanced power settings > battery option > critical battery level > buat jadi 5 persen (artinya laptopmu akan



Nice post

Thank you for sharing valuable information. Nice post. I enjoyed reading this post.
Traffic Rider | Facebook Lite | Baixar Facebook |

Pretty good post

Run 3 unblocked is the third install of the Run Serie. Skate, float, bounce, and/or jump your way through even more space tunnels! Run 2 unblocked game is next games in run series, now you can play run game with more and more level. Try to run as far as possible, good luck. Tanks Trouble is a game designed by danish Mads Purup. It is a maze party game with 1-3 players on one computer. The objective of the game is to destroy the other tanks to get a point.
Run 2 - Run 2 unblocked - Tank Trouble - Tank Trouble 2

thank you



Thank you for sharing !

Great article

I really enjoyed reading your article. I found this as an informative and interesting post, so I think it is very useful and knowledgeable.
Ipower coupon codes

Post new comment

This question is for testing whether you are a human visitor and to prevent automated spam submissions.