MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Unable to connect to MQCONN

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> CICS and Middleware
View previous topic :: View next topic  
Author Message
mfuser
Banned


Joined: 01 Mar 2005
Posts: 105
Topics: 58

PostPosted: Fri Apr 14, 2006 1:58 am    Post subject: Unable to connect to MQCONN Reply with quote

Hai All,


I am new to MQ Programming and i have defined a Queue succesfuly and i am trying to put a message in a queue defined by me trough an application program COBOL. While i run my JCL i am getting error as S806 load module not found.The application program is compiled and linked edited successfully and the program is executing fine but when it is encountering call to MQCONN ,it is failing:

CODE:
Code:

01  WS-QMGR-NAME               PIC X(04) VALUE 'CSQA'.
01  WS-HCONN                   PIC S9(9) BINARY VALUE 0.
01  WS-COMPCODE                PIC S9(9) BINARY.
01  WS-REASON                  PIC S9(9) BINARY.

DISPLAY 'TRYING TO CONNECT TO QUEUE MANAGER'.
CALL 'MQCONN' USING WS-QMGR-NAME
                    WS-HCONN
                    WS-COMPCODE
                    WS-REASON.

OUTPUT:
Code:

TRYING TO CONNECT TO QUEUE MANAGER         
CEE3501S The module MQCONN   was not found.

How can we know whether MQCONN is active or not , whether MQCONN is working properly or it is installed properly or does my userid has access to MQCONN , or as a programmer how can i know the status of MQCONN , or should i concatinate the load pds for MQCONN, is there any way wherein i know where in my shop i can find MQCONN.

Morever i have two questions:

1.How can we know whether we have MQ installed in any shop ? Can we know thriugh any specific job name which implies that MQ is installed ?
2.How can we know where the load modules MQCONN,MQOPEN,MQCLOSE and others reside ?
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Fri Apr 14, 2006 5:44 am    Post subject: Reply with quote

mfuser,

Quote:

1.How can we know whether we have MQ installed in any shop ? Can we know thriugh any specific job name which implies that MQ is installed ?


If MQ installed in your shop you have all these load modules in HLQ.SCSQLOAD. Most shops have HLQ as SYS1. So see if you have a dataset named like that.

Quote:

2.How can we know where the load modules MQCONN,MQOPEN,MQCLOSE and others reside ?


Same as above.

Assuming that you DID have MQ installed in your shop, did you link edit your program with CSQBSUTB?

If your intention is dynamically call MQ, then make sure that you are using the NODYNAM compiler option and link with CSQBSTUB.

Code:

INCLUDE SCSQMOD(CSQBSTUB)
MODE AMODE(31),RMODE(ANY)
NAME XXXXXXXX(R)     


Hope this helps...

Cheers

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
PaulPeplinski
Beginner


Joined: 17 Feb 2006
Posts: 11
Topics: 3

PostPosted: Fri Apr 14, 2006 9:20 am    Post subject: Reply with quote

Stub for CICS programs is CSQCSTUB.

Also, mqconn is not needed in CICS because the connection is implicit (any CICS can communicate with one and only one QM). If mqconn is used in CICS the convention is to use a qmgr name of SPACES.

MQ load libraries are needed in RPL and STEPLIB (if not linklisted). There should also be a CKQC CICS tran to check the CICS "interface" to MQ.
Back to top
View user's profile Send private message
mfuser
Banned


Joined: 01 Mar 2005
Posts: 105
Topics: 58

PostPosted: Fri Apr 14, 2006 12:39 pm    Post subject: Reply with quote

Thanks Kolusu for your help and based upon your reply i had checked for the PDS having the loadmodule MQCONN and i could able to run successfully but i am getting MAXCC=2138 CN(INTERNAL) when i run the job and here is my code.

Code:

01  WS-QMGR-NAME               PIC X(04) VALUE 'CSQA'.
01  WS-HCONN                   PIC S9(9) BINARY VALUE 0.
01  WS-COMPCODE                PIC S9(9) BINARY.
01  WS-REASON                  PIC S9(9) BINARY.

DISPLAY 'TRYING TO CONNECT TO QUEUE MANAGER'.
DISPLAY 'BEFORE'.     
CALL 'MQCONN' USING WS-QMGR-NAME
                    WS-HCONN
                    WS-COMPCODE
                    WS-REASON.
DISPLAY 'AFTER'.

OUTPUT
Code:

TRYING TO CONNECT TO QUEUE MANAGER             
BEFORE                                         
AFTER                                           
************************************************
* MQCONN                                       
* COMPLETION CODE : 000000002                   
* REASON CODE     : 000002129                   
************************************************
************************************************
* MQDISC                                       
* COMPLETION CODE : 000000002                   
* REASON CODE     : 000002138                   
************************************************


The situation i faced:
I had run the job once after finding the load module MQCONN , i got the job successful and i got connection properly but there was a error somewhere in my program for opening the queue.I had fixed the error and then run the job once again and since then i am getting MAXCC = 2138 and i have displayed the error which i have got.
Back to top
View user's profile Send private message
mfuser
Banned


Joined: 01 Mar 2005
Posts: 105
Topics: 58

PostPosted: Sat Apr 15, 2006 1:03 am    Post subject: Reply with quote

Hi All,

I solved the problem of MAXCC=2138.Actually i did not concatinate the dataset SYS1.SCSQAUTH in my Run JCL and when i did i was able to run further but i am still getting S322 as time out for the operation of getting a message from the queue defined by me.
I am getting as ouput:

Code:

************************************************
* MQGET                                         
* COMPLETION CODE : 000002039                   
* REASON CODE     : 000000000                   
************************************************

I have got some information on this and it says:
Code:

MQRC_NOT_OPEN_FOR_OUTPUT
                 (2039, X'7F7') Queue not open for output.

But when i check the display properties of my queue i have both GET and PUT enabled as 'Y'.Can anybody help me out further ahead as how to solve the problem ?


Code:

Put enabled . . . . . . . . : Y  Y=Yes,N=No     
Get enabled . . . . . . . . : Y  Y=Yes,N=No     
Usage . . . . . . . . . . . : N  N=Normal,X=XmitQ
Storage class . . . . . . . : DEFAULT           
Creation method . . . . . . : PREDEFINED         
Output use count  . . . . . : 0                 
Input use count . . . . . . : 0                 
Current queue depth . . . . : 2                 
Back to top
View user's profile Send private message
mfuser
Banned


Joined: 01 Mar 2005
Posts: 105
Topics: 58

PostPosted: Sat Apr 15, 2006 1:19 am    Post subject: Reply with quote

Hai All,

I could make out the mistake done by me .Actually in my program after putting a message (PUT) in the queue successfully again i am trying to put the message instead of getting the message (GET) which is why it is exceeding the time out operation and i get S322 code and after changing the code i was able to read the message from the queue.
Code:

MQRC_NOT_OPEN_FOR_OUTPUT
                 (2039, X'7F7') Queue not open for output.

As the queue was trying to be in 'PUT' state ,that is why it is 'Queue not open for output'.
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Sat Apr 15, 2006 6:25 am    Post subject: Reply with quote

mfuser,

Thanks for the feedback and glad you are able to fix the problem by yourself.

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> CICS and Middleware All times are GMT - 5 Hours
Page 1 of 1

 
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


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group