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 » mq client connect to qmgr by using clntconn

Post new topic  Reply to topic
 mq client connect to qmgr by using clntconn « View previous topic :: View next topic » 
Author Message
louiezhang
PostPosted: Tue Apr 22, 2008 3:05 pm    Post subject: mq client connect to qmgr by using clntconn Reply with quote

Novice

Joined: 25 Oct 2007
Posts: 10

hi everyone,

question to use client conn table connect to qmgr.

I have a qmgr called 'hub', it has clntconn chl defined,
DEF CHL(HUB.CLNT.CONN) CHLTYPE(CLNTCONN) TRPTYPE(TCP) CONNAME('192.168.1.4(1415)') QMNAME(HUB).

I saw C:\IBM\MQv6\Qmgrs\HUB\@ipcc\AMQCLCHL.TAB has a new timestamp, then copy it over to client machine.

On mq client machine, first of all, i set mqserver variable, then use amqsputc and amqsgetc to put/get msg on a ql in HUB, that works.

Then i defined MQCHLLIB and MQCHLTAB to locate client connt table file. The location is set correctly. Then I try to use amqsputc, it returns 2059.

I am thinking, is that amqsputc itself cause issue? coz how can amqsputc know which clntconn chl to use to access qmgr on server side?

Pls share some tips here about how to use clntconn table to make mq client connect to qmgr on mq server. Thanks!
Back to top
View user's profile Send private message MSN Messenger
fjb_saper
PostPosted: Tue Apr 22, 2008 3:16 pm    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

Read the client manual and specifically the section for channel tables in a client connection.

IIRC it will also prompt you to read a section of the programer's manual (or reference).

This should answer your question.
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
louiezhang
PostPosted: Tue Apr 22, 2008 3:35 pm    Post subject: Reply with quote

Novice

Joined: 25 Oct 2007
Posts: 10

Well. I did read the client manual, csqzaf09. That is why I believe I already did the right thing.

Programmer manual I read as well, looks like amqsput(amqsputc) will look for chl definition file to find the target qmgr. In this case, I don't understand why it doesn't locate the qmgr, which I already have a clntconn chl in clnt chl def file.


If a queue manager is not specified, amqsget connects to the default queue manager, and amqsgetc connects to the queue manager identified by an environment variable or the client channel definition file.
Back to top
View user's profile Send private message MSN Messenger
fjb_saper
PostPosted: Tue Apr 22, 2008 3:41 pm    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

In the manuals there are some exemples on how to use a client channel table.

You need to read them and understand the importance of the qmgr name in the connection process especially *qmgrname and qmgr* as well as blank....

Enjoy
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
louiezhang
PostPosted: Tue Apr 22, 2008 3:54 pm    Post subject: Reply with quote

Novice

Joined: 25 Oct 2007
Posts: 10

yes, I read it. mq put call will search clnt connection table and try to find one its qmname matches qmgr name. So I still don't understand why it can not find qmgr even I set the clnt connection table file, and that file has a clnt chl its qmname is 'HUB'.
Back to top
View user's profile Send private message MSN Messenger
mvic
PostPosted: Tue Apr 22, 2008 5:08 pm    Post subject: Re: mq client connect to qmgr by using clntconn Reply with quote

Jedi

Joined: 09 Mar 2004
Posts: 2080

louiezhang wrote:
Then i defined MQCHLLIB and MQCHLTAB to locate client connt table file. The location is set correctly. Then I try to use amqsputc, it returns 2059.

Please tell us what you have MQCHLLIB and MQCHLTAB set to.

Please also look into the entries in AMQERR01.LOG on client and server sides.

Finally if none of the above helps, if you collect an MQ trace of the occurrence (strmqtrc/endmqtrc), and read the trace file for the amqsputc program instance you ran, you should see indications of what the MQ libraries did to try to make your connection.
Back to top
View user's profile Send private message
louiezhang
PostPosted: Tue Apr 22, 2008 5:26 pm    Post subject: Reply with quote

Novice

Joined: 25 Oct 2007
Posts: 10

I just about to post what I found in error log. It says HUB.CLNT.CONN not defined in remote, AMQ9520. That is ridiculous, coz the clnt conn table comes from that server indicate it's defined. Is it possible id issue?
Back to top
View user's profile Send private message MSN Messenger
louiezhang
PostPosted: Tue Apr 22, 2008 5:33 pm    Post subject: Reply with quote

Novice

Joined: 25 Oct 2007
Posts: 10

Issue solved by create a same name svrconn chl (HUB.CLNT.CONN). What a tricky part. I need to doulbe chk if IBM red book really saying same thing.
Back to top
View user's profile Send private message MSN Messenger
Vitor
PostPosted: Wed Apr 23, 2008 12:24 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

louiezhang wrote:
Issue solved by create a same name svrconn chl (HUB.CLNT.CONN).


clntconn & svrconn act as a pair like all other channels (sdr/rcvr et al). The wrinkle here is you can do without a clntconn if you use MQSERVER.

louiezhang wrote:
I need to doulbe chk if IBM red book really saying same thing.


It should, the Clients manual does. If it doesn't, raise a PMR against the doc.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Wed Apr 23, 2008 3:16 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

Vitor wrote:
It should, the Clients manual does. If it doesn't, raise a PMR against the doc.

Once more reread the doc when prompted... you might just have missed something obvious. The only way we can guess is if you specify your environment with enough detail...
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
louiezhang
PostPosted: Wed Apr 23, 2008 5:56 am    Post subject: Reply with quote

Novice

Joined: 25 Oct 2007
Posts: 10

yes, I think clntconn/svrconn should be a pair just sdr/rcvr. Amazing is svrconn can work alone, if you connect to server qmgr by set MQSERVER.
Back to top
View user's profile Send private message MSN Messenger
Vitor
PostPosted: Wed Apr 23, 2008 6:04 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

louiezhang wrote:
yes, I think clntconn/svrconn should be a pair just sdr/rcvr. Amazing is svrconn can work alone, if you connect to server qmgr by set MQSERVER.


It's just another, simpler way of connecting a client by "infering" a clntconn. It has it's place, though it does have it's limitations (as enumerated in the Clients manual).

It's all about empowerment and choice
_________________
Honesty is the best policy.
Insanity is the best defence.
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 » General IBM MQ Support » mq client connect to qmgr by using clntconn
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.