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 » General IBM MQ Support » MQCONNX ended with reason code 2538

Post new topic  Reply to topic Goto page 1, 2  Next
 MQCONNX ended with reason code 2538 « View previous topic :: View next topic » 
Author Message
krish_blore
PostPosted: Mon Dec 20, 2010 9:40 am    Post subject: MQCONNX ended with reason code 2538 Reply with quote

Novice

Joined: 29 Nov 2010
Posts: 19

Hi,

I have tried to execute amqsnxc on sample program and got below error,
any help should be appreciated to reolve this.

e3002761@/usr/mqm/samp/bin$ echo $MQSERVER
CHANNEL2/TCP/10.135.128.184(9003)

e3002761@/usr/mqm/samp/bin$ ./amqscnxc -x 10.135.128.184 -c CHANNEL2
Sample AMQSCNXC start
Connecting to the default queue manager
using the server connection channel CHANNEL2
on connection name 10.135.128.184.

MQCONNX ended with reason code 2538

e3002761@/usr/mqm/samp/bin$ ping atllpf03
PING atllpf03: (10.135.128.184): 56 data bytes
64 bytes from 10.135.128.184: icmp_seq=0 ttl=64 time=0 ms
64 bytes from 10.135.128.184: icmp_seq=1 ttl=64 time=0 ms
64 bytes from 10.135.128.184: icmp_seq=2 ttl=64 time=0 ms
64 bytes from 10.135.128.184: icmp_seq=3 ttl=64 time=0 ms
^C
----atllpf03 PING Statistics----
4 packets transmitted, 4 packets received, 0% packet loss

Thanks for your time,
Krish
Back to top
View user's profile Send private message
mqjeff
PostPosted: Mon Dec 20, 2010 9:57 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

MQCONNX does not use MQSERVER.



you didn't specify the port when you called amqscnxc.

Back to top
View user's profile Send private message
bruce2359
PostPosted: Mon Dec 20, 2010 9:58 am    Post subject: Reply with quote

Poobah

Joined: 05 Jan 2008
Posts: 9469
Location: US: west coast, almost. Otherwise, enroute.

Quote:
CHANNEL2/TCP/10.135.128.184(9003)

Is there a CHANNEL2 defined to mq? Post the definition here.

Is there a default qmgr defined on 10.135.128.184?

Is there a listener listening on port 9003?

Read this: http://publib.boulder.ibm.com/infocenter/wmqv7/v7r0/index.jsp?topic=/com.ibm.mq.csqzal.doc/fg17940_.htm
_________________
I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live.
Back to top
View user's profile Send private message
bruce2359
PostPosted: Mon Dec 20, 2010 10:18 am    Post subject: Reply with quote

Poobah

Joined: 05 Jan 2008
Posts: 9469
Location: US: west coast, almost. Otherwise, enroute.

Quote:
MQCONNX does not use MQSERVER.

It does. Look for "If you run the sample with no command-line options..." in http://publib.boulder.ibm.com/infocenter/wmqv7/v7r0/index.jsp?topic=/com.ibm.mq.csqzal.doc/fg17940_.htm
_________________
I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live.
Back to top
View user's profile Send private message
mqjeff
PostPosted: Mon Dec 20, 2010 10:41 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

bruce2359 wrote:
Quote:
MQCONNX does not use MQSERVER.

It does. Look for "If you run the sample with no command-line options..." in http://publib.boulder.ibm.com/infocenter/wmqv7/v7r0/index.jsp?topic=/com.ibm.mq.csqzal.doc/fg17940_.htm


Yes, okay, so technically if you supply a NULL pointer to MQCONNX for the ConnectOpts it will in fact act like a normal MQCONN, and look up MQSERVER from the environment. So in that sense, what I said about MQCONNX is false.

The fact that amqscnxc will interpret a lack of parameters to pass a null pointer to MQCONNX for ConnectOpts has nothing to do with what I said, nor with what krish_blore did.

MQRC 2538 is MQRC_HOST_NOT_AVAILABLE. This is because krish_blore did not provide the options to amqscnxc to cause it to tell MQCONNX either what the PORT number was or to use MQSERVER.
Back to top
View user's profile Send private message
bruce2359
PostPosted: Mon Dec 20, 2010 10:55 am    Post subject: Reply with quote

Poobah

Joined: 05 Jan 2008
Posts: 9469
Location: US: west coast, almost. Otherwise, enroute.

Sorry. I didn't mean to be needlessly argumentative.

There are far too many viewers of this site who don't read the manuals, take literally what is offered here.
_________________
I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live.
Back to top
View user's profile Send private message
krish_blore
PostPosted: Mon Dec 20, 2010 11:57 pm    Post subject: Reply with quote

Novice

Joined: 29 Nov 2010
Posts: 19

Thanks for your information..

I am using AIX as a client and LINUX is server ,

unset MQSERVER and then tried the same with port number, below is the output,

$ ./amqscnxc -x 10.135.128.184[9003] -c CHANNEL2 QM_ORANGE
Sample AMQSCNXC start
Connecting to queue manager QM_ORANGE
using the server connection channel CHANNEL2
on connection name 10.135.128.184[9003].
MQCONNX ended with reason code 2538

In the server machine..default QUEUE is QM_ORANGE

QM_ORANGE:
---------

QUEUE NAME= QUEUE2

server(LINUX) setup:
-----------------------


define qlocal (queue2)

define channel (channel2) chltype (svrconn) trptype (tcp) mcauser ('mqm')

DEFINE CHANNEL(CHANNEL2) CHLTYPE(CLNTCONN) CONNAME('10.135.128.184(9003)') TRPTYPE(TCP) QMNAME(QM_ORANGE)

define listener (listener2) trptype (tcp) control (qmgr) port (9003)

start listener(listener2)


$ ps -ef|grep 9003
mqm 5167 5004 0 01:16 ? 00:00:00 /opt/mqm/bin/runmqlsr -r -m QM_ORANGE -t TCP -p 9003
e3002761 9169 4254 0 02:52 pts/25 00:00:00 grep 9003

Is it mandatory to point MQCHLLIB and MQCHLTAB?

Please correct me if i am missing anything.
Back to top
View user's profile Send private message
exerk
PostPosted: Tue Dec 21, 2010 12:16 am    Post subject: Reply with quote

Jedi Council

Joined: 02 Nov 2006
Posts: 6339

krish_blore wrote:
...Is it mandatory to point MQCHLLIB and MQCHLTAB?...


You are missing reading the Info Centre in more detail...

Quote:
When an MQCONNX call is issued by an application on a WebSphere MQ client, the MQI client library searches for the client channel information in the following order:

1. Using the contents of the ClientConnOffset or ClientConnPtr fields of the MQCNO structure (if supplied). These identify the channel definition structure (MQCD) to be used as the definition of the client connection channel.

2. If the MQSERVER environment variable is set, the channel it defines is used.

3. If the MQCHLLIB and MQCHLTAB environment variables are set, the client channel definition table they point to is used.

4. Finally, if the environment variables are not set, the client searches for a client channel definition table whose path and name are established from the DefaultPrefix in the mqs.ini file or the Registry for Windows. If this fails, the client uses the following paths:

* UNIX systems
⁄var⁄mqm⁄AMQCLCHL.TAB

* Windows
C:\Program Files\IBM\Websphere MQ\amqclchl.tab

The first of the options described above (using the ClientConnOffset or ClientConnPtr fields of MQCNO) is supported only by the MQCONNX call.

_________________
It's puzzling, I don't think I've ever seen anything quite like this before...and it's hard to soar like an eagle when you're surrounded by turkeys.
Back to top
View user's profile Send private message
krish_blore
PostPosted: Tue Dec 21, 2010 12:16 am    Post subject: Reply with quote

Novice

Joined: 29 Nov 2010
Posts: 19

I have followed the steps in the below link also,

http://publib.boulder.ibm.com/infocenter/wmqv7/v7r0/index.jsp?topic=/com.ibm.mq.csqzal.doc/fg17940_.htm

step1 :

export MQSERVER=CHANNEL2/TCP/'10.135.128.184(9003)'

./amqscnxc

Sample AMQSCNXC start
Connecting to the default queue manager
with no client connection information specified.
Connection established to queue manager QM_ORANGE

Sample AMQSCNXC end

step 2 : UNSET the MQSERVER

$ ./amqscnxc -x 10.135.128.184[9003] -c CHANNEL2 QM_OR
ONGE
Sample AMQSCNXC start
Connecting to queue manager QM_ORONGE
using the server connection channel CHANNEL2
on connection name 10.135.128.184[9003].
MQCONNX ended with reason code 2538

I am getting the same Error

MQRC_HOST_NOT_AVAILABLE

Thanks ,
krish
Back to top
View user's profile Send private message
exerk
PostPosted: Tue Dec 21, 2010 12:20 am    Post subject: Reply with quote

Jedi Council

Joined: 02 Nov 2006
Posts: 6339

Have you tried it with () brackets?
_________________
It's puzzling, I don't think I've ever seen anything quite like this before...and it's hard to soar like an eagle when you're surrounded by turkeys.
Back to top
View user's profile Send private message
krish_blore
PostPosted: Tue Dec 21, 2010 12:32 am    Post subject: Reply with quote

Novice

Joined: 29 Nov 2010
Posts: 19

s..even i tried with () also it is giving syntax error..thats y i didnt post

$ ./amqscnxc -x 10.135.128.184(9003) -c CHANNEL2 QM_ORANGE
ksh: 0403-057 Syntax error: `(' is not expected.

Thanks,
krish
Back to top
View user's profile Send private message
exerk
PostPosted: Tue Dec 21, 2010 1:09 am    Post subject: Reply with quote

Jedi Council

Joined: 02 Nov 2006
Posts: 6339

You need to go back and read the manual in regard to the correct syntax of amqscnxc, particularly in regard to what flags you can specify together.
_________________
It's puzzling, I don't think I've ever seen anything quite like this before...and it's hard to soar like an eagle when you're surrounded by turkeys.
Back to top
View user's profile Send private message
mqjeff
PostPosted: Tue Dec 21, 2010 2:36 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

or use quotes.
Back to top
View user's profile Send private message
mvic
PostPosted: Tue Dec 21, 2010 2:53 am    Post subject: Reply with quote

Jedi

Joined: 09 Mar 2004
Posts: 2080

krish_blore wrote:
ksh: 0403-057 Syntax error: `(' is not expected.

That error message is Korn shell telling you you have a syntax error on your command. So the shell did not even start amqscnxc for you, because of this error.

Correct your shell syntax. Remember "(" and ")" have special meaning in Unix shells so you have to quote them somehow.

Please search the internet for answers to this, I don't think we can hope to teach you all about Korn shell syntax on this site.
Back to top
View user's profile Send private message
krish_blore
PostPosted: Tue Dec 21, 2010 3:03 am    Post subject: Reply with quote

Novice

Joined: 29 Nov 2010
Posts: 19

Thanks Jeff it worked....

$ ./amqscnxc -x '10.135.128.184(9003)' -c CHANNEL2 QM_
ORANGE
Sample AMQSCNXC start
Connecting to queue manager QM_ORANGE
using the server connection channel CHANNEL2
on connection name 10.135.128.184(9003).
Connection established to queue manager QM_ORANGE

Sample AMQSCNXC end
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Goto page 1, 2  Next Page 1 of 2

MQSeries.net Forum Index » General IBM MQ Support » MQCONNX ended with reason code 2538
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.