Trigger Monitor as an MQ Service object - how to get status

隐身守侯 提交于 2019-12-10 19:41:56

问题


I have created an MQ Service object to run my Trigger Monitor thus:-

DEFINE SERVICE('TriggerMonitor') +
       CONTROL(QMGR) +
       STARTCMD('C:\Program Files (x86)\IBM\WebSphere MQ\bin\runmqtm') +
       STARTARG('-m TriggerTest -q InitQueue')

Even though I set runmqtmc.exe in "Start Command" property it is showing me "Service Status" as Stopping. Is there way to make this runmqtmc running as a background service on windows without having to run it in a command prompt?


回答1:


In order to see status of a program running as an MQ Service Object, it must be of type SERVER. The default is type COMMAND which allows you to have as many of the program running, but therefore means you can't display status of it. Define the Service Object with SERVTYPE(SERVER) and then DISPLAY SVSTATUS will show status of the running program.

Read more about this in Working with Services

Also, another helpful hint looking at your STARTCMD value, did you know that you can use a replaceable insert instead of having to provide the full installation path to the program. Read more about this in Replaceable inserts on service definitions



来源:https://stackoverflow.com/questions/26918309/trigger-monitor-as-an-mq-service-object-how-to-get-status

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!