ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » IBM MQ Java / JMS » MQ5.2 -> MQ5.3 Client Conn. Java: 2195 during connect

Post new topic  Reply to topic
 MQ5.2 -> MQ5.3 Client Conn. Java: 2195 during connect « View previous topic :: View next topic » 
Author Message
NGC2735
PostPosted: Mon Jul 19, 2004 2:32 am    Post subject: MQ5.2 -> MQ5.3 Client Conn. Java: 2195 during connect Reply with quote

Newbie

Joined: 19 Jul 2004
Posts: 3

An application wich worked for years on MQ 5.1/5.2 no longer works on MQ5.3.

Any help will be appreciated.

The application always fail to connect to a local queue manager via client connetion (in prduction environment will be remote).

I reproduced the offending code:

---------------------------------------------------------------------------------

import java.util.Hashtable;

import com.ibm.mq.*;

public class Foo {

public static void main(String[] args) {
Hashtable opt = new Hashtable();

opt.put(MQC.HOST_NAME_PROPERTY, "localhost");
opt.put(MQC.PORT_PROPERTY, new Integer(1415));
opt.put(MQC.TRANSPORT_PROPERTY, MQC.TRANSPORT_MQSERIES_CLIENT);
opt.put(MQC.CHANNEL_PROPERTY, "SYSTEM.AUTO.SVRCONN");

try {
MQQueueManager qm = new MQQueueManager("TEST53",opt);
}
catch(MQException e) {
e.printStackTrace();
System.out.println("\n\nOrigin:");
e.getCause().printStackTrace();
}
}
}

---------------------------------------------------------------------------------

When i run it i get the following stack trace (exception + cause)

MQJE001: An MQException occurred: Completion Code 2, Reason 2195
MQJE007: IO error reading message data
MQJE001: An MQException occurred: Completion Code 2, Reason 2009
MQJE003: IO error transmitting message buffer
MQJE001: An MQException occurred: Completion Code 2, Reason 2195
MQJE018: Protocol error - unexpected segment type received
MQJE001: An MQException occurred: Completion Code 2, Reason 2195
MQJE018: Protocol error - unexpected segment type received
com.ibm.mq.MQException: MQJE001: An MQException occurred: Completion Code 2, Reason 2195
MQJE018: Protocol error - unexpected segment type received
at com.ibm.mq.MQManagedConnectionJ11.<init>(MQManagedConnectionJ11.java:242)
at com.ibm.mq.MQClientManagedConnectionFactoryJ11._createManagedConnection(MQClientManagedConnectionFactoryJ11.java:276)
at com.ibm.mq.MQClientManagedConnectionFactoryJ11.createManagedConnection(MQClientManagedConnectionFactoryJ11.java:296)
at com.ibm.mq.StoredManagedConnection.<init>(StoredManagedConnection.java:80)
at com.ibm.mq.MQSimpleConnectionManager.allocateConnection(MQSimpleConnectionManager.java:171)
at com.ibm.mq.MQQueueManager.obtainBaseMQQueueManager(MQQueueManager.java:754)
at com.ibm.mq.MQQueueManager.construct(MQQueueManager.java:688)
at com.ibm.mq.MQQueueManager.<init>(MQQueueManager.java:469)
at Foo.main(Foo.java:27)


Origin:
com.ibm.mqservices.MQInternalException: MQJE001: An MQException occurred: Completion Code 2, Reason 2195
MQJE018: Protocol error - unexpected segment type received
at com.ibm.mq.MQInternalCommunications.establishChannel(MQInternalCommunications.java:1597)
at com.ibm.mq.MQInternalCommunications.<init>(MQInternalCommunications.java:523)
at com.ibm.mq.MQSESSIONClient.MQCONN(MQSESSIONClient.java:1316)
at com.ibm.mq.MQManagedConnectionJ11.<init>(MQManagedConnectionJ11.java:218)
at com.ibm.mq.MQClientManagedConnectionFactoryJ11._createManagedConnection(MQClientManagedConnectionFactoryJ11.java:276)
at com.ibm.mq.MQClientManagedConnectionFactoryJ11.createManagedConnection(MQClientManagedConnectionFactoryJ11.java:296)
at com.ibm.mq.StoredManagedConnection.<init>(StoredManagedConnection.java:80)
at com.ibm.mq.MQSimpleConnectionManager.allocateConnection(MQSimpleConnectionManager.java:171)
at com.ibm.mq.MQQueueManager.obtainBaseMQQueueManager(MQQueueManager.java:754)
at com.ibm.mq.MQQueueManager.construct(MQQueueManager.java:688)
at com.ibm.mq.MQQueueManager.<init>(MQQueueManager.java:469)
at Foo.main(Foo.java:27)
---------------------------------------------------------------------------------

The test program was running on Windows XP SP1, with MQSeries 5.3 + fixpack CSD07 and J2RE 1.3.1 IBM Windows 32.

Any idea?


TIA
Anthony
Back to top
View user's profile Send private message
NGC2735
PostPosted: Mon Jul 19, 2004 3:41 am    Post subject: more info Reply with quote

Newbie

Joined: 19 Jul 2004
Posts: 3

MQseries logs (AMQERR01.LOG) report the following error:

-----------------------------------------------------------------------------------
19/07/2004 12:28:24
AMQ9213: Si è verificato un errore nelle comunicazioni per TCP/IP.

SPIEGAZIONE:
Si è verificato un errore inatteso nelle comunicazioni.
AZIONE:
Il codice di ritorno della chiamata da TCP/IP (ioctlsocket) era 10038
(X'2736'). Registrare questi valori e notificarli al responsabile di sistema.

-----------------------------------------------------------------------------------

where the error code "10038" is:

"10038: An operation was attempted on something that is not a socket."

bye
Anthony
Back to top
View user's profile Send private message
gunter
PostPosted: Mon Jul 19, 2004 3:57 am    Post subject: Reply with quote

Partisan

Joined: 21 Jan 2004
Posts: 307
Location: Germany, Frankfurt

Search 10038 or/and MQNOREMPOOL on this site, maybe you'll find the solution here.
_________________
Gunter Jeschawitz
IBM Certified System Administrator - Websphere MQ, 5.3
Back to top
View user's profile Send private message
leongor
PostPosted: Tue Jul 20, 2004 12:17 am    Post subject: Reply with quote

Master

Joined: 13 May 2002
Posts: 264
Location: Israel

This is a conversion problem.
Set MQC.CCSID_PROPERTY = 1208 or your queue manager's CCSID.
_________________
Regards.
Leonid.

IBM Certified MQSeries Specialist.
Back to top
View user's profile Send private message
JasonE
PostPosted: Tue Jul 20, 2004 3:04 am    Post subject: Reply with quote

Grand Master

Joined: 03 Nov 2003
Posts: 1220
Location: Hursley

gunter is correct - the 10038 is a 'feature' of MQ5.3 with certain vendor VPN software, as far as I can tell. In one of the 10038 hints, I've asked anyone who hits this problem to PM me with the output of process explorer (from www.sysinternals.com) showing runmqlsr highlighted in the top pane, and configured so the lower pane view shows DLLs and full paths - You can export this list to a file, and paste it into a PM to me, so I can track this problem.
Back to top
View user's profile Send private message
NGC2735
PostPosted: Wed Jul 21, 2004 11:22 pm    Post subject: Reply with quote

Newbie

Joined: 19 Jul 2004
Posts: 3

First of all, tel mi thanks all of you for the help.

The problem has been solved following gunter suggestion (i.e. setting MQNOREMPOOL environment variable to 1).

The problem comes a little API difference between WinXP and NT, as described in MS KB319952, related with socket descriptor ineritance between parent and child processes (the vanilla fork/exec listener architecture) and the way you manage it.


Thanks you all
Anthony

PS:
For JasonE, are you still interested in process explorer dump? The problems seems to imply a little change within MQSeries server code by replacing DuplicateHandle() with WSADuplicateSocket().
Back to top
View user's profile Send private message
JasonE
PostPosted: Thu Jul 22, 2004 2:13 am    Post subject: Reply with quote

Grand Master

Joined: 03 Nov 2003
Posts: 1220
Location: Hursley

Yes please, I would still be interested in the complete dll listing from the runmqlsr process (including full paths)

The "little change" is a seriously massive change as it would require complete rework of all the tcp code to use the wsa socket interface rather than the normal socket interface - whereas currently we have (mostly) common code across all platforms for tcp. Additionally, we have seen the problem appears to be triggered by vendor VPN software in most cases, and the actual O/S handles it fine...
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ Java / JMS » MQ5.2 -> MQ5.3 Client Conn. Java: 2195 during connect
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.