Error logs on UNIX, Linux, and Windows
The errors subdirectory, which is created when you install IBM MQ, can contain up to three error log files.
At installation time, an errors subdirectory is created in the /var/mqm file path under UNIX and Linux systems, and in the installation directory, for example C:\Program Files\IBM\MQ\ file path under Windows systems. The errors subdirectory can contain up to three error log files named:- AMQERR01.LOG
- AMQERR02.LOG
- AMQERR03.LOG
For more information about directories where log files are stored, see Error log directories.
After you have created a queue manager, it creates three error log files when it needs them. These files have the same names as those files in the system error log directory. That is, AMQERR01, AMQERR02, and AMQERR03, and each has a default capacity of 32 MB (33554432 bytes). The capacity can be altered in the Extended queue manager properties page from the IBM MQ Explorer, or in the QMErrorLog stanza in the qm.ini file. These files are placed in the errors subdirectory in the queue manager data directory that you selected when you installed IBM MQ or created your queue manager. The default location for the errors subdirectory is /var/mqm/qmgrs/ qmname file path under UNIX and Linux systems, and C:\Program Files\IBM\MQ\qmgrs\ qmname \errors file path under Windows systems.
As error messages are generated, they are placed in AMQERR01. When AMQERR01 gets bigger than 32 MB it is renamed to AMQERR02.
The latest error messages are thus always placed in AMQERR01, the other files being used to maintain a history of error messages.
All messages relating to channels are also placed in the appropriate error files belonging to the queue manager, unless the queue manager is unavailable, or its name is unknown. In which case, channel-related messages are placed in the system error log directory.
To examine the contents of any error log file, use your usual system editor.
An example of an error log
Figure 1 shows an extract from an IBM MQ error log:Operator messages
Operator messages identify normal errors, typically caused directly by users doing things like using parameters that are not valid on a command. Operator messages are national-language enabled, with message catalogs installed in standard locations.These messages are written to the associated window, if any. In addition, some operator messages are written to the AMQERR01.LOG file in the queue manager directory, and others to the equivalent file in the system error log directory.
Error log access restrictions
Certain error log directories and error logs have access restrictions. To gain the following access permissions, a user or application must be a member of the mqm group:- Read and write access to all queue manager error log directories.
- Read and write access to all queue manager error logs.
- Write access to the system error logs.
If an unauthorized user or application attempts to write a message to a queue manager error log directory, the message is redirected to the system error log directory.
Ignoring error codes under UNIX and Linux systems
On UNIX and Linux systems, if we do not want certain error messages to be written to a queue manager error log, we can specify the error codes that are to be ignored using the QMErrorLog stanza.For more information, see Queue manager error logs.
Ignoring error codes under Windows systems
On Windows systems, the error message is written to both the IBM MQ error log and the Windows Application Event Log. The error messages written to the Application Event Log includes messages of error severity, warning severity and information severity. If we do not want certain error messages to be written to the Windows Application Event Log, we can specify the error codes that are to be ignored in the Windows registry. Use the following registry key:HKLM\Software\IBM\WebSphere MQ\Installation\MQ_INSTALLATION_NAME\IgnoredErrorCodeswhere MQ_INSTALLATION_NAME is the installation name associated with a particular installation of IBM MQ.
The value that you set it to is an array of strings delimited by the NULL character, with each string value relating to the error code that we want ignored from the error log. The complete list is terminated with a NULL character, which is of type REG_MULTI_SZ.
For example, if we want IBM MQ to exclude error codes AMQ3045, AMQ6055, and AMQ8079 from the Windows Application Event Log, set the value to:AMQ3045\0AMQ6055\0AMQ8079\0\0The list of messages we want to exclude is defined for all queue managers on the machine. Any changes you make to the configuration will not take effect until each queue manager is restarted.
- Error log directories
IBM MQ uses a number of error logs to capture messages concerning its own operation of IBM MQ, any queue managers that you start, and error data coming from the channels that are in use. The location of the error logs depends on whether the queue manager name is known and whether the error is associated with a client.
Parent topic: Use error logs
Related concepts
Related tasks
Related reference