Java Web Application Performance on Windows 2003 and Windows 2008

I have a Java Web / SIP application that runs on Tomcat. The application was designed to work in Windows 2003 for 1000 simultaneous sessions with 4 GB of RAM and 4 vCPU in a virtualized environment.

Now the application is ported to Windows 2008, Tomcat is still 32 bits, and the application is compiled with 32-bit Java, therefore a 32-bit application. With this installation, my 2008 perf. the test doesn’t work the same way it is used to work with Windows 2003. CPU utilization reaches its maximum and many calls are lost.

I have the following questions.

  • Does a 32-bit application in environment 64 run extra CPU / memory, which creates a problem here.

  • Is there a performance difference between Win 2003 and Win 2008.

  • Does Windows 2008 support more CPUs due to the 64-bit environment compared to 2003?

+4
source share
3 answers

We had a similar situation, once back, and we tried to move a 32-bit application (Tomcat-based J2EE application) to a 64-bit machine. We are witnessing the consequences that you face.

By the way, you did not mention why you switched to 64-bit OS :).

Take your questions one by one

Whether the 32-bit application in environment 64 will launch additional processor / memory, creating a problem here.

In general, yes. But it also depends on your processor architecture. To understand this, see how Windows runs a 32-bit application on a 64-bit machine. A 64-bit OS has a subsystem called WoW64 ( 32-bit version of Windows on a 64-bit version of Windows )

There are basically two ways: WoW64 does this

  • 32-bit command emulation. This computation is very expensive and is likely to cause a surge in processor usage. This usually occurs when used with Intel Itanium (IA-64) processors.

  • Switching the processor to 32-bit mode from 64-bit mode. Here, when you need to execute a 32-bit application stream, the processor switches to 32 modes (compatibility mode), and then switches back to 64 bit mode. This is relatively faster than the previous emulation engine.

Is there a performance difference between Win 2003 and Win 2008.

This is very subjective. It depends on the type of equipment you use. Even if you have a 64-bit OS and hardware, a lot depends on the type of hardware, the processor of the motherboard, etc. The 64-bit OS is designed to use superior equipment that the 32-bit OS and the machine cannot due to limitations, such as addressing space, etc.

Does Windows 2008 support a larger number of processors compared to 2003 because of the 64-bit environment?

Yes. like @EJP mentioned above, he has more things to offer . A more reliable OS will require superior hardware. Perhaps your particular application may or may not need any special Win 2008 features. This is the reason you need to call, why you need to switch to 64-bit with 32 bits. Here is a similar post on the same forum.

BTW I'm not sure if you have an option, but you can run the same code without rebuilding (if you do not use any libraries of a specific platform) on a 64-bit Cat.

+1
source
  • Not particularly.
  • Yes. This is sometimes very important. I see all kinds of delays in programs that used to run at warp speed.
  • Yes, but not because of 64 bits, simply because it has more.
0
source

I think your previous installation of the SIP and Java application has been optimized, but there has not been a new one yet. There is no difference in performance for networks and java between the last SP for Windows 2003 and the last SP for 2008 (based on Vista), however Win 2008 R2 works faster with java due to a smarter processor affinity that even runs on a virtual machine. Basically, I would look into your java, make sure that you use 64-bit java, if you can, that it works with a "server" switch and that your garbage collector has parameters, for example. -XX: + UseConcMarkSweepGC -XX: + UseParNewGC -XX: NewSize = 128m, also checks the set of java options JAVA_OPTS = -Xmx3000M -server.

Also make sure that you run the latest version of java, you have updated Windows on your system, including drivers, as well as updated your visualization software, BIOS, BMC, and firmware for storage.

And in the end, just check the task manager if it really java reaches the maximum that your connection to the local network (ping) does not drop packets and that you have power management turned off in the computer BIOS.

I would recommend you upgrade to Win 2008 R2 - win 7 based.

If you are using a public cloud, this might not be a configuration issue, but just the cloud server is using the central processor with another virtual server, so your application is stuck.

0
source

Source: https://habr.com/ru/post/1402377/


All Articles