How to run TeamCity on 64-bit JVM How to run TeamCity on 64-bit JVM windows windows

How to run TeamCity on 64-bit JVM


The way I made it work (TeamCity 8, Windows server 2008 r2):

  • Install the 64-bit JRE on the target machine, now there are two ways to do this

  • A -> If you are using the Teamcity bundled JRE, replace the JRE folder ([TC Server folder]\JRE) with the JRE folder in the newly installed JRE x64 - You have to shut down the TC server service (along with all java.exe*32 services that might also use this JRE)

  • B -> Change the TeamCity Internal properties, to point to newly installed JRE x64 (see documentation for TC version 8, TC version 9 can be found here):

    java.home=C\:\\<JRE x64 install folder>\\jrejava.ext.dirs=C\:\\<JRE x64 install folder>\\jre\\lib\\ext\;C\:\\Windows\\Sun\\Java\\lib\\ext java.library.path=C\:\\<JRE x64 install folder>\\jre\\bin\;C\:\\Windows\\Sun\\Java\\bin\;C\:\\Windows\\system32\;C\:\\Windows\;C\:\\local\\Oracle\\clients\\112_64\\bin\;C\:\\local\\Oracle… 
  • An alternative to point B would be to change Environment variable JAVA_HOME, it`s more simple, but it requires a Windows server restart after that

  • If you run the TC Server service now, it should run as a 64-bit Java process (chceck via PID in task manager) :

Resource  MonitorTask Manager


The snippet from the updated question had a link in the original, pointing to the instructions on Java update for TeamCity server in TeamCity online doc.

Basically, the instructions vary based on the TeamCity distribution used and way of launching the server.

If your intent is to increase the memory for the TeamCity server, please make sure to read through the corresponding section on the same doc page.

Yet one more note: recent TeamCity versions perform Git fetch in a separate process and Git-related memory issues during fetch might require fine-tuning of the corresponding options.


"So I guess I need to copy some files into the /jre folder?"

No. You install a 64 bit JRE, and update the relevant setting to point at the 64-bit install's JRE.

Don't copy stuff from one JRE installation into another. You will break things!