FAQ for diagnostic commands in Open Message Queue Cannot resolve external resource into attachment.

If you are interested in contributing to this FAQ, please read the Contribution Guidelines.

Back to Open MQ


Jspwiki style: center

    • What are the commands?*
      imqbrokerd - starts the broker
         imqadmin - starts a gui based admin tool (minimal functionality)
         imqdbmgr - used to set of the database
         imqcmd - primary admin tool (cheat you can use -pw instead of a passfile)
         imqobjmgr - used to set of the connection factory
         imqusermgr - manages the file based password directory
    • What are the arguments for each of these commands?*
    • All the commands will display their arguments if you invoke them with -help. You can also read the Command Line Reference chapter of the Administration Guide. (this link is for MQ 4.1)
    • Where are the log files?*
    • That depends on how it is installed and the name of the broker (usually imqbrokerd although that may change based on user or with the application server)
      • On Solaris (and Linux in a slightly different location) with a package based install it is in
        /var/imq/instances/<brokername>/logs
      • On Windows and with file based installs, it is in the var directory where mq is installed. e.g.
        <mq install>/var/instances/imqbrokerd/logs
    • How do I get command line arguments to the broker when I'm running with the GlassFish Application Server?*
    • Run in LOCAL mode and pass the arguments and configure the arguments in GlassFish
    • Run as REMOTE and start the broker with the arguments you want (before starting GlassFish)
    • See the GlassFish MQ Configuration Options page for details about Local and Remote
    • Where do I set the configuration options in Open MQ?*
    • MQ has configuration settings for both the client and for the broker.
    • On the client you can either:
      • create and set connection factory object using imqobjmgr
      • pass arguments in on the command line
    • On the broker, we have two types of data:
      • operational objects (e.g. destinations) which are created with imqcmd
      • configuration which is set in the config.properties file (and in some cases can also be set by imqcmd).
        • you can also pass those properties in with -D e.g.
          imqbrokerd -tty -Dmyprop=myvalue
      • config.properties is located in:
        var/instances/<brokername>/config
  • How can I check to see that the broker is really running?
    • Use telnet to check the portmapper port:
      telnet localhost 7676
  • How do I get more logging on the broker?
    • You can change the log level in the config.properties file OR use the loglevel command line argument (e.g.
      imqbrokerd -loglevel DEBUG
      ). The MQ broker supports several different log levels, the most commonly used ones are:
      ERROR
             WARNING
             INFO
             DEBUG
  • How do I get information to show up in the window I start the broker?
    • You can set this up in config.properties
    • You can use the -tty option to start the broker
    • I keep seeing entries in the log like RED, ORANGE, YELLOW, GREEN in the log file, what does this mean?*
    • MQ has memory management. As the server gets low on memory producers are throttled back to attempt to keep the broker running.
    • How do I start a standard cluster of broker nodes?*
      This is described in the product manuals and also the on-line training, but the simplest way is to use the -cluster property on imqbrokerd. e.g.
      imqbrokerd -tty -cluster whippet:7676,whippet:7777
          imqbrokerd -tty -port 7777 -cluster whippet:7676,whippet:7777
    • How can I pass vm arguments (like -Xmx) into the broker?*
    • Use -vmarg, e.g.
      imqcmd -vmargs -Xmx=2G
    • I look in the code and I see "public" and "private" properties for the broker. What is this for?*
    • MQ property based configuration is broken up into three categories:
      • public (in the docs and supported)
      • private (not supported documented in an installed file called default.properties)
      • secret - hidden in various spots of the code
    • default.properties is in the lib directory in a file-based install
    • How can I see the protocol that is passing between the client/broker or brokers?*
    • On the client, you can turn on protocol level debugging with:
      -Dimq.debug -DReadOnlyPacket -DReadWritePacket
    • On the broker, you can use the private -debug command line argument (protocol is dumped to the log file). e.g.
      imqbrokerd -debug pkt
    • Options are:
pkt - all client/broker communication
   pktin - incoming client/broker communication
   pktout - outgoing client/broker communication
   cluster - all cluster communication
   lock - only cluster locking communication
   clscon - only cluster connection information
   clstxn - only cluster-wide transaction processing info
   clsmsg - protocol in the cluster
   clsha - only HA information
    • How can I read this protocol output?*
    • Send us e-mail to users@mq.java.net. We'll talk you through this. (It's a bit more complex than can be managed here in this FAQ)
    • The system is behaving weirdly, what can I do?*
    • Open MQ has a secret dump command which can be used to retrieve the state of most of the system (although its difficult to read). It is not documented, but generally looks something like:
      imqcmd dump bkr -debug -o file=/tmp/bkr.log
    • How do I read this dump file?*
    • Drop us a line users@mq.java.net. We'll talk you through this. (It's a bit more complex than can be managed here in this FAQ)
    • How can I get a stack trace with imqdbmgr command?*
    • Invoke imqdbmgr command with -debug option.
    • How do I know if brokers in Open MQ cluster are really communicating ?*
    • Open MQ has private imqcmd command line options which can be used to dynamically (only supported for Open MQ version >= 4.4u1) turn on/off the Open MQ cluster private debug property imq.cluster.debug.ping, like imqcmd update bkr -o imq.cluster.debug.ping=true -debug -nocheck, on each broker in the cluster, then you should see periodic ping packet dumps in the broker log like following. Alternatively you can also dynamically (only supported for Open MQ version >= 4.4u1) turn on/off the Open MQ cluster private debug property imq.cluster.debug.packet to see all packet dumps between brokers.

[......] SENDING PACKET : mq://...... <---> mq://......
Packet =     Packet: 33
......
or

[......] RECEIVING PACKET : mq://...... <---> mq://......
Packet =     Packet: 33
......