Showing posts with label MQSI. Show all posts
Showing posts with label MQSI. Show all posts

Tuesday, October 25, 2016

WebSphere(IIB) MQSI Commands and Syntax


1.Mqsisetdbparams


      Mqsisetdbparms–brokername– -n –DataSourceName
-u –DataSourceUserId– -p –DataSourcePassword

To delete the set dbparams command 


Mqsisetdbparms–brokername– -n –DataSourceName


2.mqsisetcapacity 
The mqsisetcapacity command to set the number of valid product licenses on your system.
mqsisetcapacity -c n
where n is the number of valid licences
3. mqsilistaclgroup

      Use the mqsilistaclgroup command to view or list the currently defined:
  • User groups
  • Users
  • Objects
  • Access control lists
mqsilistaclgroup--+--------------------+--------------------><
                     +- -g --GroupName ---+
                     +- -u --UserName ----+
                     +- -b --Broker-------+
                     +- -e --ExeGroup-----+
                     +- -s --Subscription-+
                     +- -r root topic---------+
‘- -t —————
4.mqsidisplaycapacity
The mqsidisplaycapacity command to display the number of valid product licenses and the processor count values on the system
Mqsidisplaycapacity
5.mqsideploy

mqsideploy command to make a deploy request to the Configuration Manager
mqsideploy –b broker name – complete  delta/complete –topic topic name –topology                      topology name -cancel –r –w timeoutValue – connection  connection filename –e   execution  groupname –bar bar file name  -rmMsgFlow name
6.mqsideleteaclgroup
The mqsideleteaclgroup command to delete the Configuration Manager database table relating to the group or user access control lists that you have defined
Mqsideleteaclgroup –f filename –g groupname –u username –b broker name –e exegroup –s subscription –r –t filename: File from which to import the configuration. The output of the mqsilistaclgroupcommand is    the correct format
7.Mqsicustomize
Mqsicustomize command to customize the broker from the root directory of your broker,  for example,     /var/wmqi/MQP1BRK.This command is supported
8.Mqsicreatemsgdefs

    This command is used to create the message defination files in ma message sets
Syntax is
    Mqsicreatemsgdefs -p  -d <c:\myproject\source>   -rmp -rmd

9.mqsicreatebar
The mqsicreatebar command provides a command line compiler that creates deployable broker archive files containing message flows and dictionaries.
Syantax
Mqsicreatebar –data  workspacepath –b barfile –version vesionstring –p projectname –o file path
In the above command barflies and file path are required attributes.
10.mqsichangeflowstats
The mqsichangeflowstats command to:
  • Turn on or off accounting and statistics snapshot publication, or archive record output.
  • Specify that the command be applied to a specific flow message flow, or all flows in an execution group, or all execution groups belonging to a broker.
  • Modify the granularity of the data collected in addition to the standard message flow accounting and statistics. This extra data can include thread related data, node related data, node terminal related data, or a mixture of this data.
Sample command
Mqsichangeflowstats BrokerA -s -g -j -b none
11.mqsireportflowstats
       mqsireportflowstats command to display the current options for accounting and statistics that have been set using themqsichangeflowstats command
mqsireportflowstars –reportflowwstars –a=yes –rs –s

PUBLISH/SUBSCRIBE COMMANDS

12.Mqsiclearmqpubsub
The mqsiclearmqpubsub command to remove an MQSeries Publish/Subscribe broker as a neighbor of this WebSphere Business Integration Event Broker broker.
Syntax
Mqsiclearmqpubsub – brokername –n neighborqueuemanagename

 13.mqsijoinmqpubsub
The mqsijoinmqpubsub command to join this WebSphere Business Integration Event Broker broker to an Miseries Publish/Subscribe broker network. The command identifies a specific Miseries Publish/Subscribe broker to be the parent of the WebSphere Business Integration Event Broker broker
Syntax

Mqsijoinmqpubsub –brokername –p –parentQueueManagerName
14.Mqsilistmqpubsub
The mqsilistmqpubsub command to display the status of the Miseries Publish/Subscribe neighbor brokers to the specified WebSphere Business Integration Event Broker broker
Syntax
Mqsilistmqpubsub–brokername.

Migration commands

15.Mqsimigratemsgflows
The mqsimigratemsgflows command to create new flows in the WebSphere Business Integration Event Broker V5.0 format, based on existing exported flows from a WebSphere MQ Event Broker V2.1 Configuration Manager.
Mqsimigratemsgflows –data workspacepath –p projectname –d directoryname –rm –log logfilename
16.mqsimigratemsgsets
The mqsimigratemsgsets command imports all the files with the extension .mrp in the directory specified by the -d parameter. Files with any other extension are ignored.
Syntax
Mqsimigratemsgsets –d , -d ata workspace –rm –g –log -v
17.Mqsimigratetables
The mqsimigratetables command to migrate the database tables for brokers or the Configuration Manager.
Syntax
Mqsimigratetables –brokername  -I serviceuseid –a service password
Mqsimigratetables –Configmgr  -I serviceuseid –a service password
Properties commands

Mqsichangeproperties,Mqsireportproperties
Trace Commands
18.Mqsichangetrace
The mqsichangetrace command to set the tracing characteristics for a component
Syntax
usertrace
Mqsichangetrace – borker name u – e executiongroupname –f flow –r –l level – m mode –
Service trace
Mqsichangetrace – borker name -t – e executiongroupname –f flow –r –l level – m mode
19.mqsiformatlog
The mqsiformatlog command to process the XML log created by mqsireadlog.
Syntax
Mqsiformatlog –I inputfilename –o outfilename.
20.Mqsireadlog
The mqsireadlog command to retrieve the trace log for the specified component
mqsireadlog –componet –u –e egroup –f flowname–o outfilename
21.mqsireporttrace
The mqsireporttrace command to display the trace options currently in effect. This command is valid for:
syntax


mqsireporttrace –componet –u –e egroup –f flowname –o outfilename
22.Mqsicreateusernameserver

This command is used to create the usename server





Mqsicreateusernameserver –I service userid –a servicepassword –q queuemanagername –r intervel 
23.Mqsichangeusernameserver

Mqsichangeusernameserver command to change various properties of the User Name Server.
24.Deleteusernameserver


Deleteusernameserver is used to delete the usenameserver
ConfigManager Commands
25.MqsicreateConfigMgr

      Syntax>>-mqsicreateconfigmgr– -i –ServiceUserID –a serviecpassword –q queuemanagername –n databasename –u databaseuserid –p databasepassword –d securitydomainname –s username serverqueumanagername –w work path
26.MqsichangeconfigMgr
 syntax
MqsichangeconfigMgr – a servicepassword –I serviceuserid –p databasepassword –g usernameserver queuemgrname –d securitydomainname –j maxjvmheapsize
Broker Commands
27.Mqsicreatebroker

Syntax

Mqsicreatebroker brokername –I serviceuserid –a servicepassword –q queuemanagername –n datasourecname –u datasourecuserid –p datasourcepassword –s unsqm -w workpath –l userlilpath –g configurationtiemout –p http port
28.Mqsichangebroker
Syntax
Mqsicreatebroker brokername ––a servicepassword I serviceuserid   –p datasourcepassword –s unsqm -w workpath –l userlilpath –g configurationtiemout –p http port
29.Mqsidelteborker

Syntax
Mqsideletebroker brokername
30 .Mqsireload
the mqsireload command to request the broker to stop and restart execution groups.
Syntax
Mqsireload brokername –egroup
31.mqsicbrreport
The mqsicbrreport command to help identify applications that use a content-based routing filter. The program inspects a broker’s subscriptions table, and reports any filters it finds that might cause incompatible behavior.
Syntax
Mqsicbrreport brokername
32.Mqsideleteconfigmg
Syntax mqsideleteconfigMgr

Tuesday, October 11, 2016

Message Broker Commands



Message Broker Commands                                                    

1 . Queue Manager Commands
* * * * * * * * * * * * * * * * * * * * * *
Create a Queue Manager
crtmqm <QUEUE_MANAGER_NAME>

Start a Queue Manager
strmqm <QUEUE_MANAGER_NAME>

Stop Queue Manager
endmqm -i <QUEUE_MANAGER_NAME>

Delete Queue Manager
dltmqm <QUEUE_MANAGER_NAME>

Define and view Queue Manager Configuration using runmqsc

Open mqsc console for Queue Manager
runmqsc <QUEUE_MANAGER_NAME> --> Press Enter

Display list of Local Queue
display QLOCAL(*)
dis QLOCAL(*)
dsp QLOCAL(*)


Display list of Remote Queue
display QREMOTE(*)

Create Local Queue Under Queue Manager
DEFINE QLOCAL(QUEUE_NAME)


Create Local Queue Under Queue Manager overriding default value e.g maxdepth
DEFINE QLOCAL(QUEUE_NAME) MAXDEPTH(100000)

Create Server Connection Channel
DEFILE CHANNEL(CHANNEL_NAME) CHLTYPE(SVRCONN) TRPTYPE(TCP)

To view the list of local queues created under a Queue Manager:
runmqsc QUEUE_MANAGER_NAME -> Press ENTER
dis qlocal(*)
end
[As an alternative to 'dis', 'display' or 'dsp' can also be used. 'end' is used to exit performing any operations on the QUEUE_MANAGER_NAME]

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
  WebSphere Message Broker Commands
* * * * * * * * * * * * * * * * * * * * * * * *
To view the Components (Broker, Configuration Manager & Queue Manager associated with the Broker) created:

mqsilist

To view the Execution Groups created under a particular Broker: (The 4-digit number displayed against each Execution Group is the Process ID of the Process DataFlowEngine.exe which corresponds to an Execution Group)

mqsilist BROKER_NAME

To view the Flows & Resources (Jars, Message Dictionaries, Message Maps etc) deployed onto a Broker's Execution Group:

mqsilist BROKER_NAME -e EXECUTION_GROUP_NAME
To view the Broker's EG Properties:

mqsireportproperties BROKER_NAME -e EXECUTION_GROUP_NAME -o ObjectName -n PropertyName

To view all the properties of a Broker's EG ('-r' indicates recursive fetch, use '-a' for non-recursive fetch):
mqsireportproperties BROKER_NAME -e EXECUTION_GROUP_NAME -o AllReportableEntityNames -r

To view all the Configurable properties of a Broker ('-r' indicates recursive fetch, use '-a' for non-recursive fetch):
mqsireportproperties BROKER_NAME -c AllTypes -o AllReportableEntityNames -r

To view the Max Heap Size set to a Broker's EG:

mqsireportproperties BROKER_NAME -e EXECUTION_GROUP_NAME -o ComIbmJVMManager -n jvmMaxHeapSize

To view the Min Heap Size set to a Broker's EG:

mqsireportproperties BROKER_NAME -e EXECUTION_GROUP_NAME -o ComIbmJVMManager -n jvmMinHeapSize

To view the Debug Port set to a Broker's EG:

mqsireportproperties BROKER_NAME -e EXECUTION_GROUP_NAME -o ComIbmJVMManager -n jvmDebugPort

To change the Broker's EG Properties:

mqsichangeproperties BROKER_NAME -e EXECUTION_GROUP_NAME -o ObjectName -n PropertyName -v ValueToBeSet

To change any of the Configurable properties of a Broker ('-r' indicates recursive fetch, use '-a' for non-recursive fetch):

mqsichangeproperties BROKER_NAME -c ConfigurablePropertyName -o ObjectName -v NewValue

To change the Max Heap Size set to a Broker's EG: [-v parameter should be a value in Bytes]

mqsichangeproperties BROKER_NAME -e EXECUTION_GROUP_NAME -o ComIbmJVMManager -n jvmMaxHeapSize -v NewValue

To change the Min Heap Size set to a Broker's EG: [-v parameter should be a value in Bytes]

mqsichangeproperties BROKER_NAME -e EXECUTION_GROUP_NAME -o ComIbmJVMManager -n jvmMinHeapSize -v NewValue

To change the Debug Port set to a Broker's EG: [-v parameter should be a 4-digit value]

mqsichangeproperties BROKER_NAME -e EXECUTION_GROUP_NAME -o ComIbmJVMManager -n jvmDebugPort -v NewValue
________________________________________________________________________

Commands for taking trace: [-u indicates 'User Trace' and -t indicates 'Service Trace']
Values of -l (Trace Level) parameter:
1. normal,
2. none,
3. debug.
Values of -m (Mode) parameter:
1. safe,
2. fast.

User Trace:

To view the user trace: (Optional -f to view the trace level of a particular message flow deployed onto an EG)

mqsireporttrace BROKER_NAME -u -e EXECUTION_GROUP_NAME -f MESSAGE_FLOW_NAME

To set the user trace: (Optional -f to view the trace level of a particular message flow deployed onto an EG)

mqsichangetrace BROKER_NAME -u -e EXECUTION_GROUP_NAME -f MESSAGE_FLOW_NAME -l TRACE_LEVEL -c SIZE_OF_TRACE_IN_KB

Service Trace:

To view the service trace: (Optional -f to view the trace level of a particular message flow deployed onto an EG)
mqsireporttrace BROKER_NAME -t -e EXECUTION_GROUP_NAME -f MESSAGE_FLOW_NAME

To set the service trace: (Optional -f to view the trace level of a particular message flow deployed onto an EG)

mqsichangetrace BROKER_NAME -t -e EXECUTION_GROUP_NAME -f MESSAGE_FLOW_NAME -l TRACE_LEVEL -c SIZE_OF_TRACE

To read the trace file: (Optional -f to view the trace level of a particular message flow deployed onto an EG)
mqsireadlog BROKER_NAME -u/-t -e EXECUTION_GROUP_NAME -f MESSAGE_FLOW_NAME -o PATH_TO_FILE_WITH_NAME_AND_EXTENSION
________________________________________________________________________
To create a BAR file:

mqsicreatebar -data PATH_TO_BAR_DIRECTORY -b BAR_FILE_NAME -p PROJECT_NAME -o NAME_OF_THE_RESOURCE_TO_BE_ADDED_WITH_EXTN
['-cleanBuild' parameter can be used to refresh the workspace projects and perform a clean build before adding]
Syntax: mqsicreatebar -data workspace -b barName [-version id] [-esql21] [-p projectName [...]] -o filePath1 [filePath2 [...]]
Command Options:
'-data workspace' workspace location (Mandatory)
'-b barName' bar file name to create or replace
'-version id' appends '_' and id to compiled names in the archive (optional)
'-esql21' compile ESQL for brokers version 2.1 (optional)
'-p projectName' specify projects containing files to link (optional, multiple projects can be specified)
'-o filePath1' workspace relative path (including the project) of deployable files to add to the broker archive. Multiple deployable files can be compiled in a single mqsicreatebar command.

To cancel all outstanding deployments:

mqsideploy -n PATH_TO_CONFIGURATION_MANAGER_FILE -c
To deploy a BAR file:
mqsideploy -n PATH_TO_CONFIGURATION_MANAGER_FILE -b BROKER_NAME -e EXECUTION_GROUP_NAME -a PATH_TO_BAR_FILE_NAME

To remove a flow or resource from the Broker's EG:

mqsideploy -n PATH_TO_CONFIGURATION_MANAGER_FILE -b BROKER_NAME -e
EXECUTION_GROUP_NAME -d FLOW_OR_RESOURCE_NAME_TO_BE_UNDEPLOYED
NOTE:
1. For all the mqsideploy commands above, a combination of -i, -p & -q parameters can be used instead of -n. -i carries the machine name, -p indicates the port on which the Queue Manager is open and -q represents the name of the Queue Manager,
2. An additional '-w' parameter can be added at the end of the command to set a Timeout Value (in seconds).
________________________________________________________________________

To reload/restart a particular Execution Group:

mqsireload BROKER_NAME -e EXECUTION_GROUP_NAME
To reload/restart all the Execution Groups of the Broker: [This command does not restart the Broker]
mqsireload BROKER_NAME
________________________________________________________________________

To stop a Broker: [Optional '-i' parameter before BROKER_NAME immediately stops the Broker, else, the Broker is stopped in Control Mode. Optional '-q' parameter after BROKER_NAME stops the Broker's Queue Manager along with the Broker]

[CONFIGURATION_MANAGER_NAME, USER_NAME_SERVER or DATABASE_INSTANCE_MANAGER can be used in place of BROKER_NAME to stop the respective Component]

mqsistop BROKER_NAME
To stop a Broker's EG:
mqsistop BROKER_NAME -e EXECUTION_GROUP_NAME
To stop a Message Flow running on a Broker's EG:
mqsistopmsgflow BROKER_NAME -e EXECUTION_GROUP_NAME -m MESSAGE_FLOW_NAME
________________________________________________________________________

To start a Broker:

[CONFIGURATION_MANAGER_NAME, USER_NAME_SERVER or DATABASE_INSTANCE_MANAGER can be used in place of BROKER_NAME to stop the respective Component]
mqsistart BROKER_NAME

To start a Broker's EG:

mqsistart BROKER_NAME -e EXECUTION_GROUP_NAME
To start a Message Flow running on a Broker's EG:
mqsistartmsgflow BROKER_NAME -e EXECUTION_GROUP_NAME -m MESSAGE_FLOW_NAME
________________________________________________________________________

To set the DSN Name to a Broker which will be used by the flows deployed onto its' EGs:

mqsisetdbparms BROKER_NAME -n DSN_NAME -u USER_ID -p PASSWORD

To reset the DSN Name to a Broker which will be used by the flows deployed onto its' EGs:

mqsisetdbparms BROKER_NAME -n DSN_NAME - -u USER_ID -p PASSWORD

To remove the DSN Name to a Broker which was used by the flows deployed onto its' EGs:

mqsisetdbparms BROKER_NAME -n DSN_NAME -d
________________________________________________________________________
To list/display/export an ACL Entry:

mqsilistaclentry CONFIGURATION_MANAGER_NAME -n .configmgr_FILE_NAME -f FILE_TO_WHICH_THE_ACL_ENTRIES_ARE_EXPORTED
To create an ACL Entry:
mqsilistaclentry CONFIGURATION_MANAGER_NAME -n .configmgr_FILE_NAME -f FILE_FROM_WHICH_THE_ACL_ENTRIES_ARE_IMPORTED
To delete an ACL Entry:
mqsideleteaclentry CONFIGURATION_MANAGER_NAME -n .configmgr_FILE_NAME -f FILE_FROM_WHICH_THE_ACL_ENTRIES_ARE_IMPORTED
________________________________________________________________________
To create a Broker:

mqsicreatebroker BROKER_NAME -i USER_ID -a PASSWORD -q BROKER_QUEUE_MANAGER_NAME

To create a Configuration Manager:

mqsicreateconfigmgr CONFIGURATION_MANAGER_NAME -i USER_ID -a PASSWORD -q BROKER_QUEUE_MANAGER_NAME

To create a User Name Server: [Optional '-r' parameter can be added to set the Refresh Interval at the end of the command with a value in seconds. Default value is 60 seconds]

mqsicreateusernameserver -i USER_ID -a PASSWORD -q BROKER_QUEUE_MANAGER_NAME
________________________________________________________________________

To delete a Broker: [Optional '-q' parameter can be added to delete the associated Queue Manager along with the Broker]
[Optional '-w' parameter can be added to delete all the files related to the Broker under the work path mentioned by '-w's value]

mqsideletebroker BROKER_NAME
To delete a Configuration Manager: [Optional '-q' parameter can be added to delete the associated Queue Manager along with the Configuration Manager]
mqsideleteconfigmgr CONFIGURATION_MANAGER_NAME

To delete a User Name Server: [Optional '-q' parameter can be added to delete the associated Queue Manager along with the User Name Server]
[Optional '-w' parameter can be added to delete all the files related to the User Name Server under the work path mentioned by '-w's value]
mqsideleteusernameserver
________________________________________________________________________

To create a Configurable Service:

mqsicreateconfigurableservice BROKER_NAME -c CONFIGURABLE_SERVICE_NAME -o ObjectName -n PropertyName -v PropertyValue

To delete a Configurable Service:

mqsideleteconfigurableservice BROKER_NAME -c CONFIGURABLE_SERVICE_NAME -o ObjectName
________________________________________________________________________

To perform the Component Verification:

mqsicvp COMPONENT_NAME
[COMPONENT_NAME can be BROKER_NAME or CONFIGURATION_MANAGER_NAME]
__________________________________________________________________________________

Distributed Computing: A Guide to Comparing Data Between Hive Tables Using Spark

In big data, efficient data comparison is essential for ensuring data integrity and validating data migrations. Apache Spark, with its in-me...