Log Setup

From Pbxnsip Wiki

Jump to: navigation, search

Contents

General Logging

When you install the system, you want to see how it works and how the PBX interprets the input to the system. Logging is a powerful mechanism to track the activity of the system.

For this purpose, the PBX keeps a list of log messages in memory and if you enter a filename it writes a copy of the log messages to the file system.

The Log Level determines which log messages are put into the log. The range is between 0 and 9. If you select level 0 you will see only the most important messages, if you select level 9 you will see all available log messages of the system. Please note that choosing log level 9 creates additional load for the system and may create huge log files.

The Log Length determines the length of the internal log message buffer. This buffer is used to show the log messages in the web interface (see below).

If you set a Log Filename, the system will write the log messages to the filename which you provide. If you put a dollar sign into the log filename, the system will replace the dollar sign with the current day. This will make sure that the log files don't get too big over time. Please don't forget to delete old log files from time to time, so that your file system does not get overloaded with too much logging information.

One of the first log messages that you will see is the working directory. If the Log Filename does not contain a path, the system will write the log file into that directory. You can specify the directory during the installation process.

Warning! Don't forget to lower the log level once the system is running. Especially when you write the log messages into a file, you will sooner or later get a hard disk full error, which a quite severe situation because the PBX will then not be able to save runtime data.

Image:log_general.gif

Specific Events

You can enable or disable logging on a subsystem level. The following subsystems are available:

  • Log general events: These events are of general interest, for example information about the working directory.
  • Log SIP events: Events in this module relate to the SIP traffic of the PBX.
  • Log media events: The PBX reports events about media processing, for example a one-way audio RTP timeout.
  • Log IVR events: This module logs events about processing user input, for example in the auto attendant or the mailbox.
  • Log email events: If you want to troubleshoot the email server interaction, you should turn this module on.
  • Log http events: This flag controls if events in the internal http server should be logged.
  • Log registration events: When a device registers or deregisters, it appears in this module.
  • Log SNMP events: SNMP events occur when a external SNMP agent requests information from the PBX.
  • Log trunk events: Log events that are related to the trunks, for example when a trunk registers the first time.
  • Log SOAP events: This subsystem deals with SOAP input and output.
  • Log TFTP events: In this module you will find events that have to do with the built-in tftp server and plug and play-related information.
  • Analyze audio levels: This feature measures the audio levels on a call leg. The volume is measured in dB (Decibel) relative to the maximum volume (0 dB would be maximum loudness). See Gain Adjustment for more information on this topic.

Image:log_events.gif

SIP Logging

When the PBX receives or sends a SIP packet, it determines if the packet will be logged and which log level this event will have.

  • REGISTER packets deal with the registration of extensions or trunks. If you are not interested in the registration traffic, set this setting to "off".
  • SUBSCRIBE/NOTIFY deals with message waiting indications and LED state and other used subscriptions.
  • OPTIONS are sometimes used to keep the SIP connection alive. In this case you will see a lot of those requests.
  • All other packets usually belong to an ongoing call (e.g. INVITE, CANCEL, ACK, BYE).

The watch list filters the SIP packets by it's IP address. Just list the IP addresses you are interested in the "Watch List (IP)" field (you may use subnet mask) and define the log level in the "Watch List Log Level". This feature is useful when you have a specific device that you want to watch in the PBX's log.

Image:log_sip.gif

Email

The PBX is able to send notifications for certain events. Currently, the only event is the daily report of the system performance. This email is sent daily after midnight and it contains a chart about the CPU usage of the last day. The meaning of the grapho is explained in System Status.

In order to use this feature, you need to provide the "From" address that is used for sending the email. The "Account" and "Password" is used for SMTP authentication purposes, the SMTP server will be used for sending the email. The recipients of the performance email must be separated with a semicolon.

Image:log_email.gif

Personal tools
Getting Help