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 API Support » Regarding dspmq

Post new topic  Reply to topic
 Regarding dspmq « View previous topic :: View next topic » 
Author Message
Mukilan
PostPosted: Mon Jan 31, 2005 10:14 pm    Post subject: Regarding dspmq Reply with quote

Newbie

Joined: 31 Jan 2005
Posts: 3

Hai Friends,

I want to know when the dspmq command will fail. Sometimes i am not getting the status of Queue Manager when i use dspmq command. But the particular Queue Manaager exists. What are the possible causes for the dspmq command failure (ie unable to get the status).

Thanks & Regards,
Mukil
Back to top
View user's profile Send private message
kirani
PostPosted: Mon Jan 31, 2005 11:36 pm    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

What is the return code you are getting? Are there any commands logged into system error log?
Per System admin guide, this command can return following return codes.
0 - Command completed normally
36 - Invalid arguments supplied
71 - Unexpected error
72 - Queue manager name error
_________________
Kiran


IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries

Back to top
View user's profile Send private message Visit poster's website
Mukilan
PostPosted: Tue Feb 01, 2005 1:09 am    Post subject: Reply with quote

Newbie

Joined: 31 Jan 2005
Posts: 3

Hai Kirani,

Actually we are not directly using the dspmq command at the command prompt. We are using in a C++ application as follows.

Code:
...
...
...

sprintf(strCmd,"cmd.exe /c DSPMQ -m %s > \"%s\" ",
QueMgrName,OutputFile);

ExecProcess(strCmd); // Using CreateProcess we execute
the command

// Parse the "STATUS" attribute in the output file OutputFile. if it is
// present, then return its value to status variable

status = Parse(OutputFile, "STATUS");

if (status != NULL)
{
// Do something
}
else
{
cout << "Invalid Object";
return -1;
}

// remaing codes.

At one point of time, i am getting "Invalid Object" message, but the Queue Manager exists. What are the possible causes for this output?. I think, it may not be Queue manager name error and Invalid arguments supplied. Then what will be reason and Why?.

After some time, if i execute the same application on same Queue Manager, it is working fine and not giving "Invalid Object" message. Awaiting for reply.

Regards,
Mukil
Back to top
View user's profile Send private message
rajesh_avrs
PostPosted: Sun Feb 20, 2005 4:01 pm    Post subject: Reply with quote

Apprentice

Joined: 18 May 2001
Posts: 31

If I understand your problem right, your code is to figure out if the given queue manager is available for connection? (am i correct?)

Why can't you issue an MQCONN in a try-catch block?? If the Queue Manager is not avilable for connection, the execution take you to the catch block where you can put your 'Do something' code?
_________________
****************
MQSeries is cool
****************
Back to top
View user's profile Send private message Send e-mail
Michael Dag
PostPosted: Mon Feb 21, 2005 12:43 am    Post subject: Reply with quote

Jedi Knight

Joined: 13 Jun 2002
Posts: 2607
Location: The Netherlands (Amsterdam)

Mukilan wrote:
At one point of time, i am getting "Invalid Object" message, but the Queue Manager exists. What are the possible causes for this output?.

Do you always make a copy of the output file for debug purposes?
it could be the file is locked or whatever and there is nothing wrong with MQ.
_________________
Michael



MQSystems Facebook page
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
bobbee
PostPosted: Wed Jan 26, 2011 12:37 pm    Post subject: Reply with quote

Knight

Joined: 20 Sep 2001
Posts: 545
Location: Tampa

someone just asked me this same question, I searched and did not find an answer.

Under what conditions (reasons) does MQ report a QMGR as Abnormal Termination or Normal Termination. I would suspect that a successful endmqm would show a normal termination. is the converse true, that if the QMGR has ended and NO endmqm was issued it considers it Abnormal?
Back to top
View user's profile Send private message Send e-mail AIM Address
fjb_saper
PostPosted: Wed Jan 26, 2011 8:23 pm    Post subject: Reply with quote

Grand High Poobah

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

bobbee wrote:
someone just asked me this same question, I searched and did not find an answer.

Under what conditions (reasons) does MQ report a QMGR as Abnormal Termination or Normal Termination. I would suspect that a successful endmqm would show a normal termination. is the converse true, that if the QMGR has ended and NO endmqm was issued it considers it Abnormal?


From my experience you get an "Abnormal Termination" status when the qmgr either died or was shutdown using the kill commands (hopefully as specified by the admin manual).

On shutdown using endmqm you get the message for a status between normal shutdown, immeditate shutdown, (and don't remember what wording goes with the "p" option...)
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
bobbee
PostPosted: Thu Jan 27, 2011 5:31 am    Post subject: Reply with quote

Knight

Joined: 20 Sep 2001
Posts: 545
Location: Tampa

Thanks, This person said the customer wanted internal information on the conditions for the status. Couldn't find more than what you just said. Mucho Gracias!!!
Back to top
View user's profile Send private message Send e-mail AIM Address
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ API Support » Regarding dspmq
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.