-1

We are migrating from websphere application server to websphere liberty.

When our application is deployed in WAS, the CPU utilisation is 8%. The same application when deployed in WLP, the CPU utilisation is more than 50% and was fluctuating.

Can anyone advise how to debug this issue and which parameters to check to minimise the CPU utilisation.

Krishna Chaitanya
  • 2,533
  • 4
  • 40
  • 74

2 Answers2

0

My advice would be to use your favorite monitoring / profiling tool:

  1. Check that your application isn't spending a lot of time garbage collecting. That could be a sign of the heap being too small, or another GC tuning problem.

  2. Check which non-GC threads are using a lot of time. Does that tell you something unexpected?

  3. Profile the code to look for performance hotspots.

Without knowing the cause, we can't suggest JVM parameter changes.

Stephen C
  • 698,415
  • 94
  • 811
  • 1,216
  • When you say profile the code, do you mean profiling through mbeans – Krishna Chaitanya Apr 21 '17 at 15:07
  • I was thinking of something like VisualVM – Stephen C Apr 21 '17 at 15:12
  • I am sorry, but i can't understand why I need to profile the code. The same code is working fine on WAS. Can you please explain? Coming to point one, we are using the same heap size for both WAS and liberty. – Krishna Chaitanya Apr 21 '17 at 15:56
  • Feel free to ignore my advice. Someone else may be know a "magic bullet" solution. However, when you migrate from container to another: 1) your application's behavior may change, and 2) the **total** heap working set may change. How are you going to find out if this has (or hasn't) happened if you don't look? – Stephen C Apr 21 '17 at 16:17
  • No offence, I was just wondering does it have anything really to do with the code. I am analysing the GC now – Krishna Chaitanya Apr 21 '17 at 16:20
  • It could be something that worked well under WAS, but not so well under WLP. But please note that I suggested three things to look at in a specific order ...... – Stephen C Apr 21 '17 at 16:23
  • 1
    You're profiling your code and the server at the same time. Getting some actual data beats scratching your head wondering where CPU is being used. – covener Apr 22 '17 at 00:41
0

I hope you have verified its the liberty process hogging on the CPU.

Can you turn on the verbose GC in liberty profile and see the logs for GC.

Hitesh Bajaj
  • 137
  • 2
  • 12