Error 2042 Mq
Contents |
PREVIOUSLY FAILED WITH UNEXPECTED ERROR, HOLDING THE OBJECT HANDLE OPEN. Fixes are available WebSphere MQ V7.0 for i5/OS Fix Pack 7.0.0.1 WebSphere MQ V7.0 for i5/OS Fix Pack mq error 2085 7.0.0.2 WebSphere MQ V6.0 Fix Pack 6.0.2.4 WebSphere MQ V7.0 Fix Pack 7.0.0.1 WebSphere mq error 2009 MQ V7.0 Fix Pack 7.0.0.2 WebSphere MQ V7.0 Refresh Pack 7.0.1.0. WebSphere MQ V7.0 Fix Pack 7.0.1.1 WebSphere MQ V7.0.1 mq error code 2042 for i5/OS Fix Pack 7.0.1.1 WebSphere MQ V7.0 Fix Pack 7.0.1.2 WebSphere MQ V7.0.1 for i5/OS Fix Pack 7.0.1.2 WebSphere MQ 6.0 for HP OpenVMS Alpha and Itanium - Fix Pack 6.0.2.7 WebSphere MQ completion code 2, reason 2042 6.0 for HP OpenVMS Alpha and Itanium - Fix Pack 6.0.2.10 (FP03) Subscribe You can track all active APARs for this component. APAR status Closed as program error. Error description Suppose a MQ application gets disconnected abnormally from the queue manager, due to unexpected error from a MQ API, while having handles to queues still open. In such a scenario, if the application disconnects and reconnects to the queue
Mqrc 2042
manager (rather than terminating the process) then the connection should get re-established and the queue manager operation should continue normally. This, however, is not currently the case, when the application disconnects from the queue manager after receiving MQRC_UNEXPECTED_ERROR then the disconnect is not being fully processed, and then when the application reconnects to the queue manager then it can find that locks held by the previous instance of the application prevent it from running correctly. This might manifest itself as an MQRC_OBJECT_IN_USE (2042), or a message being locked by a browse cursor or a transaction. For example, if a MQ-XA application fails in MQBEGIN or MQCMIT with MQRC_UNEXPECTED_ERROR, and the application then disconnects from the queue manager. Suppose this application had a handle to one of the queue objects open with MQOO_INPUT_EXCLUSIVE when it received the MQRC_UNEXPECTED_ERROR. If the application then reconnects to the queue manager, a subsequent MQOPEN call on the same queue object, again with MQOO_INPUT_EXCLUSIVE, fails with MQRC_OBJECT_IN_USE. The application then has to be restarted in order to recover from the failure. Local fix NA Problem summary **************************************************************** USERS AFFECTED: Applications having handles to queue objects open with MQOO_INPUT_EXCLUSIVE when disconnected from the queue manager with MQRC_UNEXPECTED_ERROR face this pro
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about http://stackoverflow.com/questions/25630602/websphere-mq-error-with-reason-code-2042-on-a-get hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Websphere MQ - error with reason code 2042 on a get up vote 2 down vote favorite We're getting an intermittent error on a ImqQueue::get( ImqMsg &, ImqGetMessageOptions & mq error ); call with reason code 2042, which Should Not Happen™ based on the Websphere documentation; we should only get that reason code on an open. Would this error indicate that the server could not open a queue on its side, or does it indicate that there's a problem in our client? What is the best way to handle this error? Right now we just log that it occurs, but it's happening a lot. Unfortunately I'm not well-versed in error 2042 mq Websphere MQ; I'm kind of picking this up as I go, so I don't have all the terminology correct. Our client is written in C++ linking against libmq 6.0.2.4 and running on SLES-10. I don't know the particulars for the server other than it's running version 7.1. We're requesting an upgrade to bring our side up-to-date. We have multiple instances of the client running concurrently; all are using the same request queue, but each is creating its own dynamic reply queue with MQOO_INPUT_EXCLUSIVE + MQOO_INPUT_FAIL_IF_QUIESCING. c++ websphere-mq suse share|improve this question asked Sep 2 '14 at 19:10 John Bode 59.6k858107 add a comment| 1 Answer 1 active oldest votes up vote 1 down vote If the queue is not already open, the ImqQueue::get method will implicitly open the queue for you. This will end up with the MQOO_INPUT_AS_Q_DEF option being used which will therefore use the DEFSOPT(EXCL|SHARED) attribute on the queue. You should also double check that the queue is defined SHARE rather than NOSHARE, but I suspect that will already be correctly set. You mention that you have multiple instances of the application running concurrently so if one of them has the queue opened implicitly as MQOO_INPUT_AS_Q_DEF resulting in MQOO_INPUT_SHARED from DEFSOPT, then it will get 2042 (MQRC_OBJECT_IN_USE) if others have it open. If nothing else had it open at the time, then the implicit open will work, and later instances