Many times I use 'mqsc' for create MQ queue manager from script files but I don't know how to generate script files.
Thanks
Many times I use 'mqsc' for create MQ queue manager from script files but I don't know how to generate script files.
Thanks
There is a SupportPac that installs a program called "saveqmgr.exe".
Here's a link to the download of the Pac: http://shrinkster.com/17kc
IBM seems to frequently reorganize its website, so the above link might not work if you check back here after a long while, but the SupportPac can be found easily by doing a search for "saveqmgr" on the Websphere MQ page. Hope this helps!
IBM has this to say about the SupportPac:
Abstract This SupportPac (saveqmgr) saves all the objects, such as queues, channels, etc, defined in a either local or remote queue manager to a file.
Download Description This SupportPac interrogates the attributes of all the objects defined to a queue manager (either local or remote) and saves them to a file.
Possible Uses The format of this file is suitable for use with runmqsc. It is therefore possible to use this SupportPac to save the definitions of objects known to a queue manager and subsequently recreate that queue manager.
saveqmgr is the common way of generating scripts that represent existing queue managers. The script files are just text files containing the commands you'd use with runmqsc, so you can easily write them by hand in a text editor as well.
If you are parsing the MQSC files with script, SupportPac MO72: MQSC Client for WebSphere MQ is invaluable. It runs in client or bindings mode and acts like runmqsc but you can also specify output to be formatted on one line. That enables you to submit a command like
DIS CHL(*) ALL
...and since the output has one line per channel then you can grep for interesting attributes. Finding all channels connecting to a certain IP address becomes pretty easy. I usually drive MO72 from a program that iterates over all my QMgrs and executes MQSC code. This allows reporting or mass updates across all nodes.