COMTEK Logo   Masthead Banner Image
AS/400 System Management SNMP Agent FAQ

@1. How do I edit the NMServer configuration file?
@2. How can I verify that the IBM Master Agent is running?
@3. How do I control how often the data collectors refresh their data?
@4. How can I control how often a threshold trap is resent?
@5. How do I specify critical processes?
@6. How do I configure QSYSOPR message filtering?
@7. The COMTEK subagent does not respond to an SNMP manager. What is wrong?
@8. Some or all of the COMTEK variables are not available.
@9. SNMP manager does not receive any traps.
@10. The wrong IP address appears in traps.
@11. SNMP Sets do not work.
@12. SNMP performance is slow. Trap delivery seems backlogged.
@13. What additional debugging aides are available?
@14. CMTKSNMP is reporting errors to QSYSOPR.

Additional Troubleshooting Information is contained in Chapter 2 of the NMServer/400 User's Guide.


@1. How do I edit the NMServer configuration file?

  1. Enter the command STRPDM.
  2. Select "3. Work With members"
  3. Fill in the blanks as follows: File: COMTEK_CFG Library: COMTEK1 Member: INIT_CFG
  4. Press Enter.
  5. Make changes to the configuration file.
  6. Save the file by typing FILE on the command line.

@2. How can I verify that the IBM Master Agent is running?

To do this use the WRKACTJOB SBS(QSYSWRK) JOB(Q*) command and look for QSNMPSA, QTMSNMP, and QTMSNMPRCV. These jobs normally run under the QSYSWRK subsystem. If these processes are absent, issue the command STRTCPSVR SERVER(*SNMP).

@3. How do I control how often the data collectors refresh their data?

The data collectors determine how long to wait between refreshing their data by referencing the xxx_WAIT_TIME variables, where xxx refers to the last 2-4 letters of the affected module. For example, to control how often COMTEKDSK refreshes its data, set DISK_WAIT_TIME. These variables are available both in the initial configuration file and the configuration branch of the MIB. Refer to Chapter 3, Configuration Files in the NMServer for OS/400 User's Guide for more details on each of these variables. COMTEKQSYS and COMTEKRCONS do not support this variable.

@4. How can I control how often a threshold trap is resent?

Threshold traps are CPU and disk utilization traps. The data for both of these traps is collected by the COMTEKCPU process. The COMTEKCPU data collector determines how often to send a threshold trap (CPU or DISK utilization) based on the CPU_RESEND_TRAP_COUNT and DISK_RESEND_TRAP_COUNT variables. These variables determine the number of consecutive times a threshold must be exceeded before a trap is repeated. To calculate the number of minutes between CPU traps, multiply CPU_WAIT_TIME variable by the CPU_RESEND_TRAP_COUNT variable. To calculate the number of minutes between disk utilization traps, multiply the CPU_WAIT_TIME variable by the DISK_RESEND_TRAP_COUNT variable.

@5. How do I specify critical processes?

The critical process configuration is a two step process. First you must create a file containing the list of processes. An example is COMTEK1/COMTEKCFG(CRIT_PROC1). The name of member and the file that contains it are NOT important. You may have as many of these members and files as you wish. Select the active critical process file by setting INITIAL_REQ_PS_FILENAME in the initial configuration file or by setting the psReqProcFileName variable from the SNMP manager.

@6. How do I configure QSYSOPR message filtering?

This is done with several filters which are ANDed.  

he MIN_QSYSOPR_SEV_TO_SEND specifies the minimum severity that a message must have in order to be forwarded to the SNMP manager. OS/400 numbers priorities from 0 through 99, with 99 being the highest priority.

The messages can be filtered by blocking messages with message Ids that are in the QSYSOPR message filter file. Setting up the filter file is a 2 stage process. The first step is to create the file, as with the critical process configuration, the file name is not important. For example,  COMTEK1/COMTEKCFG(SKIP_MSGID). Select the active QSYSOPR message filter file by setting QSYSOPR_MSG_FILTER_FILE in the initial configuration file or by setting the qsysoprMsgFilterFile MIB variable.

The messages can be filtered by age. This is especially useful when starting the COMTEK subagent when the QSYSOPR message queue has many unread old messages. Set the QSYSOPR_MSG_MAX_AGE_MINUTES to specify the maximum age of a Qsysopr message to send.

@7. The COMTEK subagent does not respond to an SNMP manager. What is wrong?

Common causes:

  • The IBM Agent is down. Check this by looking at the Contact information variables from the manager. These variables are supported by the IBM agent. Otherwise, use the command WRKACTJOB SBS(QSYSWRK) and look for the QSNMPSA, QTMSNMP, and QTMSNMPRCV jobs. If these jobs are not present, restart the IBM agent with the command STRTCPSVR SERVER(*SNMP).
  • The COMTEK subagent is not started. Issue the command WRKACTJOB SBS(QSYSWRK) JOB(COM*)
    and look for the COMTEKSNMP job. If it is not started, it can be started with the STRCOMTEK command.
  • The license key is either invalid or expired. If you start the subagent, then do a WRKACTJOB and cannot find the COMTEKSNMP module, check the QSYSOPR message queue for an error message. DSPMSG(QSYSOPR). If you see UCS0070 "The license key you have entered is invalid…" or UCS0071 "The trial period for COMTEK NMServer/400 has expired…", ensure that the key was correctly entered. If the key has expired, either arrange for a new demo key or purchase the product to obtain a permanent key.
  • The community name is incorrect. Use the IBM supplied command CHGSNMPA to check the community name. Make sure you prompt (press F4) on the command instead of pressing enter.

@8. Some or all of the COMTEK variables are not available.

Common causes:

  • See number @7 above.
  • Ensure that the appropriate data collection modules are running. Again, use WRKACTJOB SBS(QSYSWRK) JOB(COM*) and verify that the appropriate data collection modules are running. See Chapter 2 of the User's Guide for a description of the data collection modules.

@9. SNMP manager does not receive any traps.

Common causes:

  • See number @7 and number @8 above.
  • The trap community does not contain your SNMP manager’s IP address. Use the CHGSNMPA command to modify the trap community. Remember to prompt (press F4) on the CHGSNMPA command instead of pressing enter.
  • Ensure that the trap throttle is running. Use WRKACTJOB SBS(QSYSWRK) JOB(COM*) and look for COMTEKTHRT. If the COMTEKTHRT process is missing, stop the subagent with the ENDCOMTEK command and restart it with the STRCOMTEK command.
  • The trap community is not correctly set. I.e. the SNMP manager is not in the list of addresses to receive traps. Use the CFGTCPSNMP command to correct this problem.

@10. The wrong IP address appears in traps.

Verify that the local domain and host names are properly set and that the host table contains the correct IP address and hostname for the AS/400. If there is no entry in the hosts table that matches the local host name, the loopback address will be used. To check these configuration points, use the CFGTCP command and choose option 10 "Work with TCP/IP host table entries" and option 12 "Change local domain and host names". The name in the host table entry should be of the form <host name>.<domain name> For example comtek400.comtekservices.com where comtek400 is the hostname and comtekservices.com is the domain name. Note: Some versions of the IBM Agent expect to see a domain name. If your company does not use domain names, you will need to make one up in order to get the correct address in traps.

@11. SNMP Sets do not work.

If the IBM agent and COMTEK subagent are both up, it is most likely the community name. The community name is case sensitive on the AS/400.Keep in mind that OS/400 likes to capitalize text, where most on most UNIX platforms, the text is left as lowercase.

@12. SNMP performance is slow. Trap delivery seems backlogged.

The system is missing one or more PTFs for the IBM SNMP (Master) Agent. Install the appropriate PTFs. Get the PTF information from COMTEK1/COMTEKCFG(PTF_LIST) or from IBM support.

@13. What additional debugging aides are available?

The QSYSOPR Message Queue
Most times, the COMTEK subagent will send any messages indicating problems to the QSYSOPR message queue. You can see this queue by using the command DSPMSG(QSYSOPR).

DPI Trace
You can run a DPI trace to see the data that flows between the IBM Agent and the COMTEK subagent. To run a DPI trace:

  1. Make sure NMServer/400 is not running.
  2. Prompt on the STRCOMTEK command (press F4 instead of ENTER).
  3. Set the DPI debug option to *YES. It is the last option in the list.
  4. Run the scenario that you would like to trace.
  5. End NMServer/400 with the ENDCOMTEK command. The trace is not available until NMServer/400 is stopped.
  6. The trace will appear in the spooler. To see the trace, issue the command WRKSPLF and look for a file named QPRINT (the equivalent of an unnamed file on the AS/400).
The IBM SNMP Journal
The IBM SNMP agent has the ability to log all SNMP get and set requests and all SNMP traps. The AS/400 uses a technique called journaling to keep the log entries. The agent has a default setting for logging each of these events (gets, sets, and traps) as well as the ability to override the defaults on a community basis.

To set the default logging choices for the system:

  1. Issue the command CFGTCPSNMP
  2. Select 1. Change SNMP attributes
  3. Set "Log set requests", "Log get requests", and "Log traps" to *YES or *NO, as desired
  4. Press enter
  5. Use either F3 or F12 to exit the Configure TCP/IP SNMP menu

To set the logging choices for a specific SNMP community:

  1. Issue the command CFGTCPSNMP
  2. 2. Select 2. Work with communities for SNMP
  3. Select the appropriate community and enter 2 by the community name. 
  4. Press Enter.
  5. Set "Log set requests" and "Log get requests" to *YES or *NO, as desired
  6. Press enter
  7. Use either F3 or F12 to exit the Configure TCP/IP SNMP menu

To display the journaled (logged) entries:

  1. Issue the command DSPJRN JRN(QUSRSYS/QSNMP)
  2. Each entry is a on a separate line. To view an individual entry, put 5 in the blank preceding the entry and press enter

@14. CMTKSNMP is reporting errors to QSYSOPR.

If the following errors appear in the QSYSOPR queue it indicates that the IBM Master Agent is not running.  See @2 above for more information on the IBM Master Agent.

CMTKSNMP: Exiting. See previous messages for explanation.
CMTKSNMP: Error return code -12 on disconnectSNMP.
CMTKSNMP: pDPIpacket returned NULL in procedure do_unregister at line 000083.
CMTKSNMP: Error -12 on waitDPIpacket.
CMTKSNMP: Error return code -12 on sendDPI packet.
CMTKSNMP: Error -12 on waitDPIpacket.
CMTKSNMP: Error return code -2 on sendDPI packet.