Author |
Message
|
badcow |
Posted: Sun Jul 27, 2014 7:35 pm Post subject: why the queue file size cannot be reduced when clearing ? |
|
|
Newbie
Joined: 17 Jul 2014 Posts: 2
|
Dear all, I've encount a problem about queue file size as below, please give your advice, thanks !
there are 3 queues in my qmgr, which are persistent queues. Some program put msg into them, but not get msg out from them for some days, so there're hundreds of thousands of msg in the queues and the queue file size is larger than 1.5GB now. when I found it , I began to clear these queues before programer would fix it (the msg in the queues were useless as programer said).
But when I clear the queues using amqsget, the file size of those queues won't be shrunk at all. why ? and how to shrank the file size after I clear the msg from queues ? |
|
Back to top |
|
 |
w33f |
Posted: Sun Jul 27, 2014 7:49 pm Post subject: |
|
|
Novice
Joined: 07 Nov 2013 Posts: 17
|
What is the queue depth after you clear the queues? When you run the command "dis qs(queue_name)" is the value of UNCOM YES or NO? |
|
Back to top |
|
 |
badcow |
Posted: Sun Jul 27, 2014 8:27 pm Post subject: |
|
|
Newbie
Joined: 17 Jul 2014 Posts: 2
|
w33f wrote: |
What is the queue depth after you clear the queues? When you run the command "dis qs(queue_name)" is the value of UNCOM YES or NO? |
the queue depth is "0" when I clear the queues (the file size is 290M at the moment ). But soon it will grow as the program continuously put some msg in it.
UNCOM is NO |
|
Back to top |
|
 |
zpat |
Posted: Sun Jul 27, 2014 9:55 pm Post subject: |
|
|
 Jedi Council
Joined: 19 May 2001 Posts: 5866 Location: UK
|
Space will be recovered in time. If you want it immediately - restart the QM.
Use expirying messages to avoid this problem. _________________ Well, I don't think there is any question about it. It can only be attributable to human error. This sort of thing has cropped up before, and it has always been due to human error. |
|
Back to top |
|
 |
PeterPotkay |
Posted: Mon Jul 28, 2014 3:16 am Post subject: Re: why the queue file size cannot be reduced when clearing |
|
|
 Poobah
Joined: 15 May 2001 Posts: 7722
|
badcow wrote: |
But when I clear the queues using amqsget, the file size of those queues won't be shrunk at all. |
With one or more messages on the queue, clear the queue using the clear queue command, and inspect the q file size then.
http://www-01.ibm.com/support/knowledgecenter/?lang=en#!/SSFKSJ_7.5.0/com.ibm.mq.adm.doc/q020780_.htm
In the past I have found looping MQGETs do not cause the q file to shrink right away, but the clear q command does. There must be one or more messages on the queue for this trick to work when you issue the clear q command. If the queue is already empty, put a dummy message then issue the clear command - it seems to only work if there is at leat one message. _________________ Peter Potkay
Keep Calm and MQ On |
|
Back to top |
|
 |
tczielke |
Posted: Mon Jul 28, 2014 12:04 pm Post subject: |
|
|
Guardian
Joined: 08 Jul 2010 Posts: 941 Location: Illinois, USA
|
|
Back to top |
|
 |
|