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 IndexGeneral IBM MQ SupportSupportPac MO74 Powershell Error Handling

Post new topicReply to topic
SupportPac MO74 Powershell Error Handling View previous topic :: View next topic
Author Message
Zodiac42
PostPosted: Fri Oct 21, 2016 6:35 am Post subject: SupportPac MO74 Powershell Error Handling Reply with quote

Newbie

Joined: 31 Aug 2016
Posts: 6
Location: Linz, AT

Hi all,

I've been working on some PowerShell-Scripts to "lighten the burden" of administering my MQ-Servers.
Now I got to the point, where I thought all was good and done, but then I tested the following:

When you stop a Qmgr and try to access it with - say - Get-WMQQueue, it immediately returns MQRC_Q_MGR_NOT_AVAILABLE on screen, but there is no error object at all, no return code, nothing. Even $? returns True for the last operation.

So, my question for today: Is there a way to evaluate error codes on these MO74 cmdlets?

Thanks in advance!

Cheers, Pat

By the way: I try to do this

Code:
Get-WMQQueue -QmgrName $QmgrName | Where {($_.QueueType -eq "Local") -and ($_.Name -notmatch "SYSTEM.+") -and ($_.CurrentDepth -ge 1)} | select Name,CurrentDepth,QueueType
Back to top
View user's profile Send private message
Display posts from previous:
Post new topicReply to topic Page 1 of 1

MQSeries.net Forum IndexGeneral IBM MQ SupportSupportPac MO74 Powershell Error Handling
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.