Bootstrap FreeKB - IBM MQ - High CPU on Linux
IBM MQ - High CPU on Linux

Updated:   |  IBM MQ articles

When an IBM MQ system is experiencing high CPU on a Linux system, I typically start with the top command.

By default, top is real time, meaning that the top output will refresh every few seconds. The -n 1 option can be used to display a snap shot of top.

top -n 1

 

Let's say something like this is being returned. Notice in this example that the mdatp_audisp_pl process is using 94% of the CPU. mdatp_audisp_pl is not an IBM MQ process. Instead, mdatp_audisp_pl is a Microsoft Defender process. In this scenario, IBM MQ processes are not causing the high CPU.

top - 01:17:17 up 24 days, 21:45,  3 users,  load average: 44.42, 46.62, 51.39
Tasks: 327 total,   4 running, 323 sleeping,   0 stopped,   0 zombie
%Cpu(s): 47.1 us, 32.4 sy,  0.0 ni,  2.9 id, 17.6 wa,  0.0 hi,  0.0 si,  0.0 st
KiB Mem : 24504092 total,   211588 free, 16739796 used,  7552708 buff/cache
KiB Swap:  2097148 total,  2012668 free,    84480 used.  5820504 avail Mem 

   PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND                                                                                                                                                            
 30485 root      20   0 1273792  26652   1904 R  94.1  0.1   2718:53 mdatp_audisp_pl

 

On the other hand, let's say something like this is being returned. Notice in this example that the top processes using CPU are amqrmppa. These are IBM MQ processes. 

top - 02:06:40 up 1 day, 23:48,  1 user,  load average: 0.26, 0.84, 8.42
Tasks: 315 total,   2 running, 313 sleeping,   0 stopped,   0 zombie
%Cpu(s):  6.1 us,  6.1 sy,  0.0 ni, 84.8 id,  0.0 wa,  0.0 hi,  3.0 si,  0.0 st
KiB Mem : 24504092 total,   263380 free,  4669380 used, 19571332 buff/cache
KiB Swap:  2097148 total,  2097148 free,        0 used. 19070284 avail Mem 

   PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND                                                                                                                                                            
  8693 mqm       20   0 1467864 443812 225160 S   6.2  1.8  69:49.76 amqrmppa                                                                                                                                                           
 45387 mqm       20   0 1463676 355576 182884 S   6.2  1.5  32:08.07 amqrmppa

 

amqrmppa is IBM MQ channel pooling process. For example, let's say a connection is made to IBM MQ on a channel named foo.channel1.svr. This connection would be with the amqrmppa process. While the connection is active, the display chstatus command should show that the channel is running.

AMQ8417: Display Channel Status details.
  CHANNEL(foo.channel1.svr)           CHLTYPE(SVRCONN)
  CONNAME(10.1.2.3)                   CURRENT
  STATUS(RUNNING)                     SUBSTATE(RECEIVE)

 

Once the connection has closed, the IBM MQ error log should contain something like this.

----- cmqxrfpt.c : 692 --------------------------------------------------------
07/15/2021 04:10:08 PM - Process(4391.5658756) User(mqm) Program(amqrmppa)
                    Host(server1.example.com) Installation(Installation1)
                    VRMF(9.1.0.5) QMgr(MANAGER001)
                    Time(2021-07-15T21:10:08.620Z)
                    CommentInsert1(foo.channel1.svr)
                    CommentInsert2(4391)
                    CommentInsert3(10.17.1.55)

AMQ9001I: Channel 'foo.channel1.svr' ended normally.

EXPLANATION:
Channel 'foo.channel1.svr' to host '10.17.1.55' ended normally.
ACTION:
None.

 

Likewise, the display conn command can be used to show the active connections. Something like this should be returned for each active connection.

AMQ8276I: Display Connection details.
  CONN(0938739232847)
  EXTCONN(418D84A8B837E3938A983ABC9)
  TYPE(CONN)

 

And the display chstatus (channel status) command can be used to show the channels with an active connection. Something like this should be returned for each connection.

AMQ8417: Display Channel Status details.
  CHANNEL(MANAGER01.CHANNEL01.SVR)    CHLTYPE(SVRCONN)
  CONNAME(10.1.2.3)                   CURRENT
  STATUS(RUNNING)                     SUBSTATE(RECEIVE)

 




Did you find this article helpful?

If so, consider buying me a coffee over at Buy Me A Coffee



Comments


Add a Comment


Please enter 84b2c8 in the box below so that we can be sure you are a human.