copyright | lastupdated | subcollection | keywords | ||
---|---|---|---|---|---|
|
2019-06-06 |
mqcloud |
MFT, message, file, transfer, topology |
{:new_window: target="_blank"} {:shortdesc: .shortdesc} {:screen: .screen} {:codeblock: .codeblock} {:pre: .pre}
{: #mqoc_mft_single_qmgr_topology}
{: #mqoc_mft_single_qmgr_topology_step11}
We expect you have read the information provided in this link. We will use a single MQ on Cloud Queue Manager and configure it to be the coordination queue manager, commands queue manager, and agents queue manager.
Configuration details:
We will be using one MQ on Cloud queue manager and will name it as QM_COORD. On all the system we are using profiles with administrative privileges.
- QM_COORD queue manager: acts as the Coordination queue manager, Command queue manager, source agent queue manager, and destination agent queue manager.
- SRC_AGENT: source agent which is connected to the QM_COORD queue manager.
- DEST_AGENT: destination agent which is connected to the QM_COORD queue manager.
Prerequisites :
You should have one MQ on Cloud Queue Manager running:
-
Create a new MQ on Cloud Queue Manager and name it QM_COORD. Then, download Connection Details (save this file as coordinationQMgrConnectionDetails.json) and store the secret API key. Follow the same steps (as suggested in PreRequisites step 2).
-
Follow the steps documented below to configure the QM_COORD as the coordination queue manager, command queue manager and agents queue manager.
-
Create File transfer
{: #mqoc_mft_setting_coordination_qmgr}
In this section, you will setup a coordination queue manager which is running in IBM Cloud. As part of the configuration for the coordination queue manager, several MQ resources like queues, channels, topics will be created in the queue manager. This queue manager broadcasts audit and file transfer information.
-
Switch to the admin terminal you setup previously.
-
Run the following command
fteSetupCoordination -coordinationQMgr <queueManagerName> -coordinationQMgrHost <queueManagerHostname> -coordinationQMgrPort <queueManagerPort> -coordinationQMgrChannel <queueManagerChannel> -credentialsFile <filePath> -default -f
<queueManagerName>
- this is 'queueManagerName' in the file coordinationQMgrConnectionDetails.json<queueManagerHostname>
- this is the 'hostname' in the file coordinationQMgrConnectionDetails.json<queueManagerPort>
- this is the 'listenerPort' in the file coordinationQMgrConnectionDetails.json<queueManagerChannel>
- this is the 'adminChannelName' in the file coordinationQMgrConnectionDetails.json<filePath>
- this is the 'filePath' where credentials file is present- e.g. -
- Windows:
C:\Users\Administrator\MQMFTCredentials.xml
- Linux:
/home/usr/MQMFTCredentials.xml
refer appendix 4 for more details
- Windows:
- e.g. -
-default
- Optional. Updates the default configuration options to those associated with the coordination queue manager specified in this command-f
- Optional. forces the command to overwrite existing configuration- e.g -
- for windows : fteSetupCoordination -coordinationQMgr QM_COORD -coordinationQMgrHost qm-coord-d8a2.qm.us-preprod.mqcloud.ibm.com -coordinationQMgrPort 32246 -coordinationQMgrChannel CLOUD.ADMIN.SVRCONN -credentialsFile "C:\Users\Administrator\MQMFTCredentials.xml" -default -f
- for linux : fteSetupCoordination -coordinationQMgr QM_COORD -coordinationQMgrHost qm-coord-d8a2.qm.us-preprod.mqcloud.ibm.com -coordinationQMgrPort 32246 -coordinationQMgrChannel CLOUD.ADMIN.SVRCONN -credentialsFile "/home/document/MQMFTCredentials.xml" -default -f
-
For a full list of command arguments of fteSetupCoordination, Refer to this link fteSetupCoordination KnowledgeCenter
-
Run
runmqsc
to connect to the remote queue managerrunmqsc -c -u <ADMIN_MQ_USER> -w60 <QUEUE_MANAGER_NAME>
<ADMIN_MQ_USER>
- this is 'mqUsername' in the file coordinationQMgrConnectionDetails.json<QUEUE_MANAGER_NAME>
- this is 'queueManagerName' in the file coordinationQMgrConnectionDetails.json-c
informs runmqsc it should connect to a remote queue manager using the MQSERVER variable
- e.g. - runmqsc -c -u mamgainp -w60 QM_COORD
-
The terminal will prompt you for a Password
- This is your <ADMIN_API_KEY> = 'apiKey' in the file platformApiKey.json
-
The terminal will now be waiting for input. Do not close this terminal as we will use this terminal to create MQ objects.
-
Create the MQ objects required by the queue manager to work as a coordination queue manager that targets your mq on cloud queue manager
- When you ran fteSetupCoordination in step 2, an mqsc file will have been created at location
MQ_DATA_PATH\mqft\config\coordination_qmgr_name\<coordination_qmgr_name>.mqsc
. Copy and paste the content of this file into your terminal.
- When you ran fteSetupCoordination in step 2, an mqsc file will have been created at location
{: #mqoc_mft_setting_command_qmgr}
In this section, you will setup a command queue manager that is targeted at the MQ on Cloud Queue Manager. As part of the configuration for the Command Queue Manager, following commands have to be executed:
- Switch to the admin terminal you setup previously.
- Run the following command
-
fteSetupCommands -connectionQMgr <queueManagerName> -connectionQMgrHost <queueManagerHostname> -connectionQMgrPort <queueManagerPort> -connectionQMgrChannel <queueManagerChannel> -credentialsFile <filePath> -p <configurationOptions> -f
<queueManagerName>
- this is 'queueManagerName' in the file coordinationQMgrConnectionDetails.json<queueManagerHostname>
- this is the 'hostname' in the file coordinationQMgrConnectionDetails.json<queueManagerPort>
- this is the 'listenerPort' in the file coordinationQMgrConnectionDetails.json<queueManagerChannel>
- this is the 'adminChannelName' in the file coordinationQMgrConnectionDetails.json<filePath>
- this is the 'filePath' where credentials file is present e.g. -C:\Users\Administrator\MQMFTCredentials.xml
refer appendix 4 for more detailsconfigurationOptions
- by convention this is the name of a coordination queue manager-f
- Optional. forces the command to overwrite existing configuration
-
e.g. - fteSetupCommands -connectionQMgr QM_COORD -connectionQMgrHost qm-coord-d8a2.qm.us-preprod.mqcloud.ibm.com -connectionQMgrPort 32246 -connectionQMgrChannel CLOUD.ADMIN.SVRCONN -p QM_COORD -f
-
- For a full list of command arguments of fteSetupCommands, Refer to this link fteSetupCommands KnowledgeCenter
{: #mqoc_mft_setting_agent_qmgr}
In this section, you will setup an agent queue manager that is targeted at the MQ on Cloud Queue Manager. As part of the configuration for the Agent Queue Manager, the following commands should be executed.
Configuration Steps :
-
Open two admin_terminals and name them as terminal 1 and terminal 2.
-
Go to terminal 1 and create a SRC_AGENT:
2.1. In terminal 1 run the following commands to create a SRC_AGENT (Source Agent):
fteCreateAgent -agentName <agentName> -agentQMgr <agentQueueManager> -agentQMgrHost <agentQueueManagerHost> -agentQMgrPort <agentQueueManagerPort> -agentQMgrChannel <agentQueueManagerChannel> -p <configurationOptions> -f -credentialsFile <filePath>
agentName
- Required. Name of the agent to create.agentQueueManager
- Required. Name of the agents's Queue Manager.This is ’queueManagerName’ in the file coordinationQMgrConnectionDetails.jsonagentQueueManagerHost
- Required. this is the ‘hostname’ in the file coordinationQMgrConnectionDetails.jsonagentQueueManagerPort
- Required. this is the ‘listenerPort’ in the file coordinationQMgrConnectionDetails.jsonagentQueueManagerChannel
- Required. this is the ‘adminChannelName’ in the file coordinationQMgrConnectionDetails.jsonconfigurationOptions
- by convention this is the name of a coordination queue manager<filePath>
- this is the 'filePath' where credentials file is present e.g. - - In windows :C:\Users\Administrator\MQMFTCredentials.xml
refer appendix 4 for more details - In linux :/home/document/MQMFTCredentials.xml
refer appendix 4 for more details-f
- Optional. Forces the command to overwrite the existing configuration.- e.g.-
- In windows - fteCreateAgent -agentName src_agent -agentQMgr QM_COORD -agentQMgrHost qm-coord-d8a2.qm.us-preprod.mqcloud.ibm.com -agentQMgrPort 32246 -agentQMgrChannel CLOUD.ADMIN.SVRCONN -p QM_COORD -credentialsFile "C:\Users\Administrator\MQMFTCredentials.xml" -f
- In linux - fteCreateAgent -agentName src_agent -agentQMgr QM_COORD -agentQMgrHost qm-coord-d8a2.qm.us-preprod.mqcloud.ibm.com -agentQMgrPort 32246 -agentQMgrChannel CLOUD.ADMIN.SVRCONN -p QM_COORD -credentialsFile "/home/document/MQMFTCredentials.xml" -f
2.2 Run
runmqsc
to connect to your remote queue managerrunmqsc -c -u <ADMIN_MQ_USER> -w60 <QUEUE_MANAGER_NAME>
<ADMIN_MQ_USER>
- this is 'mqUsername' in the file coordinationQMgrConnectionDetails.json<QUEUE_MANAGER_NAME>
- this is 'queueManagerName' in the file coordinationQMgrConnectionDetails.json-c
informs runmqsc it should connect to a remote queue manager using the MQSERVER variable
- e.g.- runmqsc -c -u mamgainp -w60 QM_COORD
2.3 The terminal will prompt you for a Password
- This is your <ADMIN_API_KEY> = 'apiKey' in the file platformApiKey.json
2.4 Terminal will now be waiting for input.
2.5 Create the MQ objects required by the queue manager to work as an agent queue manager that targets your mqoc queue manager.
- An mqsc file will be created at location
MQ_DATA_PATH\mqft\config\coordination_qmgr_name\agents\agent_name\agent_name_create.mqsc
. You should copy and paste the content of this file into your terminal 1.
2.6. Start the agent created above using the following command:
fteStartAgent -p <configurationOptions> <agentName>
whereconfigurationOptions
- by convention this is the name of a coordination queue manageragentName
- Required. name of the IBM MQ Managed File Transfer agent to start.
- e.g.- fteStartAgent -p QM_COORD SRC_AGENT
-
Go to terminal 2 to create a DEST_AGENT :
3.1. In terminal 2 run following commands to create a DEST_AGENT (Destination Agent):
-
fteCreateAgent -agentName <agentName> -agentQMgr <agentQueueManager> -agentQMgrHost <agentQueueManagerHost> -agentQMgrPort <agentQueueManagerPort> -agentQMgrChannel <agentQueueManagerChannel> -p <configurationOptions> -f -credentialsFile <filePath>
agentName
- Required. Name of the agent to create.agentQueueManager
- Required. Name of the agents's Queue Manager.This is ’queueManagerName’ in the file coordinationQMgrConnectionDetails.jsonagentQueueManagerHost
- Required. this is the ‘hostname’ in the file coordinationQMgrConnectionDetails.jsonagentQueueManagerPort
- Required. this is the ‘listenerPort’ in the file coordinationQMgrConnectionDetails.jsonagentQueueManagerChannel
- Required. this is the ‘adminChannelName’ in the file coordinationQMgrConnectionDetails.jsonconfigurationOptions
- by convention this is the name of a coordination queue manager<filePath>
- this is the 'filePath' where credentials file is present.- e.g. -
- In windows -
C:\Users\Administrator\MQMFTCredentials.xml
- In linux -
/home/document/MQMFTCredentials.xml
- In windows -
- e.g. -
refer appendix 4 for more details
-f
- Optional. Forces the command to overwrite the existing configuration.
-
e.g.-
- In windows - fteCreateAgent -agentName dest_agent -agentQMgr QM_COORD -agentQMgrHost qm-coord-d8a2.qm.us-preprod.mqcloud.ibm.com -agentQMgrPort 32246 -agentQMgrChannel CLOUD.ADMIN.SVRCONN -p QM_COORD -credentialsFile "C:\Users\Administrator\MQMFTCredentials.xml" -f
- In linux - fteCreateAgent -agentName dest_agent -agentQMgr QM_COORD -agentQMgrHost qm-coord-d8a2.qm.us-preprod.mqcloud.ibm.com -agentQMgrPort 32246 -agentQMgrChannel CLOUD.ADMIN.SVRCONN -p QM_COORD -credentialsFile "/home/document/MQMFTCredentials.xml" -f
3.2. Run
runmqsc
to connect to your remote queue managerrunmqsc -c -u <ADMIN_MQ_USER> -w60 <QUEUE_MANAGER_NAME>
<ADMIN_MQ_USER>
- this is 'mqUsername' in the file coordinationQMgrConnectionDetails.json<QUEUE_MANAGER_NAME>
- this is 'queueManagerName' in the file coordinationQMgrConnectionDetails.json-c
informs runmqsc it should connect to a remote queue manager using the MQSERVER variable
- e.g.- runmqsc -c -u mamgainp -w60 QM_COORD
3.3. The terminal will prompt you for a Password
- This is your <ADMIN_API_KEY> = 'apiKey' in the file platformApiKey.json
3.4. Terminal will now be waiting for input
3.5. Create the MQ objects required by the queue manager to work as an agent queue manager that targets your MQ on Cloud Queue Manager.
- A mqsc file will be created at location
MQ_DATA_PATH\mqft\config\coordination_qmgr_name\agents\agent_name\agent_name_create.mqsc
. You should copy and paste the content of this file into your terminal 1.
3.6. Start the agent created above using following command
fteStartAgent -p <configurationOptions> <agentName>
whereconfigurationOptions
- by convention this is the name of a coordination queue manageragentName
- Required. name of the IBM MQ Managed File Transfer agent to start.
- e.g.- fteStartAgent -p QM_COORD DEST_AGENT
-
-
Now both of your newly created agents should be in Active/Ready state. To check there status execute.
fteListAgents -p <configurationOptions>
configurationOptions
- by convention this is the name of a coordination queue manager
- e.g.- fteListAgents -p QM_COORD
You have now configured the IBM MQ Managed File transfer queue managers to transfer a file.
Go to Step 2 to Initiate a File Transfer