CommuniGate Pro
Version 5.2
システム
 
 
 
サーバーログ

Server Logs

CommuniGate Pro サーバーのコンポーネントは複数ありますが、コンポーネントから出力されたメッ セージはすべて単一のログファイルに格納されます。ログレコードはいずれも、タイムスタンプ、ロ グレベル、出力元のコンポーネントを示すタグ、ログデータ自体で構成されます。

CommuniGate Pro のログはプレーンテキストファイルで、したがって任意のテキスト処理ユーティリ ティで処理できます。

問題が生じ、Stalker 社のテクニカルサポートにサポートを依頼されるときは必ず、問題に関連するロ グデータを提出してください。

ログファイルの作成と削除

U保存されているログは、任意のWeb ブラウザでチェックできます。チェックしたい場合、[Monitor] セクションの[Logs] ボタンをクリックします。クリック後、ログリストが表示されます。リストで は、カレントのログにはアステリスク(*) が付けられています。

ログを見る場合、"Can Monitor"サーバーアクセス権が必要です。

ログのページの上部にはオプションが表示されます。各オプションを使って、ログファイルの作成や 削除、管理が可能です。以下、パラメータについて説明します。

Log Manager Settings
Start New File Every: or if Larger than:
Delete Old Files In:   
External Logger Records to Send: Server Address:
 
Start New File
新規のログファイルが作成される頻度を指定します。値としては、毎日(夜中の12 時に作成) などが指定できます。
if Larger than
カレントのログファイルの最大サイズを指定でき、このサイズを超えると新規のログファイル が作成されます。

ログファイルは、CommuniGate Pro サーバーのベースディレクトリの中のSystemLogs サブディレクト リに作成されます。

Delete Old Files
作成されたログファイルが自動的に削除されるまでの日数を指定できます。新規のログファイ ルが作成されるたびに、SystemLogs サブディレクトリの中のログファイルがチェックされ、こ こで指定した日数を経過したログファイルがあった場合、そのログファイルが削除されます。
External Logger
Please see the Sending to Remote Servers section.

ログの設定を変更する場合、"CanTuneLoggerSettings"モニタアクセス権が必要です。

ログリストのログを削除したい場合、ログを選択した後、[Delete Marked Logs] ボタンをクリックし ます。ログは複数選択して、削除することもできます。なお、アクティブ(カレント) のログファイ ルは削除できません。

ログを削除する場合、"CanTuneLoggerSettings"モニタアクセス権が必要です。

表示されるログファイルの数が多すぎる場合、[Filter] フィールドに文字列を入力し、[Display] ボタ ンをクリックします。これで、ログの中で、入力した文字列が、その名前に含まれるログだけが表示 されます。

Filter: 11 of 11 selected
 NameSize
voicemail_prompt355K
*2006-12-07_14-395974K
2006-12-0731M
2006-12-06_23-205707K
2006-12-06_13-1931M
2006-12-06_02-0531M
2006-12-06_00-5431M
2006-12-06_00-5231M
2006-12-06_00-4931M
2006-12-06_00-4831M
2006-12-06_00-4631M

ログファイルの名前をクリックすると、その内容が表示されます。


時間の範囲の指定

ログファイルの名前をクリックすると、Web ブラウザ上には、デフォルトでは、そのログファイルの すべてのレコードが表示されます。レコードの数は時には数千に及ぶこともあり、その全部を見る必 要がない場合もあります。そういったときには、ダウンロードを中止します。その後、下記のオプショ ンを使ってログレベルや時間の範囲を指定し、表示されるレコードを絞り込むことができます。

Log Level: Full Screen
  Filter: KeyedRegEx
Server Time: 4:41:53PM  Interval: -

例えば、[Interval] フィールドに時間の範囲を指定すると、タイムスタンプがその範囲のレコードだ けが表示されます。

注意: 表示するログがカレントのログの場合、[Interval] の2 番目のフィールドにアステリスク(*) に入力しておくと、レコードのうち、現在までのレコードが表示されます。

注意: 表示するログがカレントのログの場合、[Interval] の2 番目のフィールドに現在以降の時刻(例 えば1 時間後の時刻) を指定することもできます。この場合、ブラウザのチャンネルがオープンのま まになり、その時点以降のログレコードをリアルタイムで見ることができます。その後、指定した時 刻が到来した時点、または、新規のレコードの作成が開始された時点でチャンネルが閉じられます。


ログレコードのフィルタリング

サーバーのロードが大きい場合、または、コンポーネントのログレベルをローレベル(Low-Level) に 設定しているときには、ログファイルが非常に大きくなることもあります(データは数メガになるこ ともあります)、その場合、レコードのチェックが難しくなります。こうしたケースでは、レコードの フィルタリング機能を使うと有効です。

Level
Use this setting to suppress displaying records that are more detailed than the specified value (have a higher level marker).
Filter
Use this option to specify the Filter string. Only the records containing this string will be displayed.
The first part of log records (including a time stamp and a level marker) is not used for filtering operations.
RegEx
If this option is selected, the Filter string is interpreted as a regular expression.

Click the Display button to display only the records that contain the specified substring.

Example:

Some of your users complain that sometimes their mailer application cannot retrieve messages from your server properly and that they see error messages informing them about some protocol errors.

Since it does not occur often, you should run the IMAP module with its Log Level set to All-Info, though this will make your Logs very big. Finally, a user contacts you and says that the mailer has just displayed the same error.

You open the Log and set the Level to 3 (Problems). Now you may see all the problems with the IMAP module that occurred today. When you find the record that indicates the problem your user is talking about, you see that that record has the IMAP-437425 tag. So, you type IMAP-437425 into the Filter field, and change the Log Level to 5 (All Info). As a result, you see a clean log of that particular IMAP session.

Log Level: Full Screen
  Filter: KeyedRegEx
Server Time: 4:41:53PM  Interval: -
00:06:23.261 4 IMAP-437425([64.173.55.175]) got connection on [64.173.55.169:143](mail.communigate.com) fr
00:06:23.261 5 IMAP-437425([64.173.55.175]) out: * OK CommuniGate Pro IMAP Server 5.1.8 at mail.commun
00:06:23.261 5 IMAP-437425([64.173.55.175]) inp: 1 CAPABILITY
00:06:23.261 5 IMAP-437425([64.173.55.175]) out: * CAPABILITY IMAP4 IMAP4REV1 ACL NAMESPACE UIDPLUS ID
00:06:23.266 5 IMAP-437425([64.173.55.175]) inp: 2 AUTHENTICATE METHOD AAAAAAAAAAAAAAAAAAAAAA=
00:06:23.268 2 IMAP-437425([64.173.55.175]) 'user@domain.com' connected from [64.173.55.175:31358]
00:06:23.268 5 IMAP-437425([64.173.55.175]) out: 2 OK completed\r\n
00:06:23.269 5 IMAP-437425([64.173.55.175]) inp: 3 LIST "" "*"
00:06:23.269 5 IMAP-437425([64.173.55.175]) out: * LIST (\UnMarked) "/" Calendar\r\n* LIST (\Marked) "
00:06:23.279 5 IMAP-437425([64.173.55.175]) inp: 4 SELECT "Tasks"
00:06:23.270 5 IMAP-437425([64.173.55.175]) out: * FLAGS (\Answered \Flagged \Deleted \Seen \Draft $MD
00:06:23.272 5 IMAP-437425([64.173.55.175]) inp: 5 UID SEARCH NOT DELETED
00:06:23.272 5 IMAP-437425([64.173.55.175]) out: * SEARCH 32 49 76 84 94 96 98 100 101 102 113 116 117
00:06:23.275 5 IMAP-437425([64.173.55.175]) inp: 6 UID FETCH 193 (BODYSTRUCTURE FLAGS)
00:06:23.275 5 IMAP-437425([64.173.55.175]) out: * 35 FETCH (BODYSTRUCTURE (("text" "calendar" ("chars
00:06:23.278 5 IMAP-437425([64.173.55.175]) inp: 7 UID FETCH 193 (BODY.PEEK[HEADER])
00:06:23.278 5 IMAP-437425([64.173.55.175]) out: * 35 FETCH (BODY[HEADER] {722}\r\ncontent-class: urn:
00:06:23.280 5 IMAP-437425([64.173.55.175]) inp: 8 UID FETCH 193 (BODY.PEEK[1])
00:06:23.280 5 IMAP-437425([64.173.55.175]) out: * 35 FETCH (BODY[1] {539}\r\nBEGIN:VCALENDAR\r\nMETHO
00:06:23.281 5 IMAP-437425([64.173.55.175]) inp: 9 UID FETCH 191 (BODYSTRUCTURE FLAGS)
00:06:23.281 5 IMAP-437425([64.173.55.175]) out: * 34 FETCH (BODYSTRUCTURE (("text" "calendar" ("chars

Filtering by Prefix Key

The Keyed option instructs the Server to scan the Log twice. First, it scans the Log (within the specified Time Interval) and finds all records matching the filter string. These strings are not displayed, but their Prefix Keys are remembered. The Prefix Key is the first part of the record (not including the time stamp and the level marker) till the first space symbol. Up to 100 different Prefix Keys are remembered.

Then the Log is scanned again (within the specified Time Interval), and the Server displays all records that have Prefix Keys matching one of the remembered Prefix Keys.

Some protocols (such as SIP) do not use connections. A SIP session ("dialog") consists of several packets (each packet is recorded with its own SIPDATA-NNNNNN Prefix Key), but all packets contain the same Call-ID line. Use the

: Call-ID:caller-id

filter string with the Keyed option to display all SIP session packets:

Log Level: Full Screen
  Filter: KeyedRegEx
Server Time: 4:41:53PM  Interval: -
00:54:10.312 2 SIPDATA-000502 out: req udp [10.0.0.1]:5060 REGISTER(680 bytes) sip:node6.communigate.com
00:54:10.312 5 SIPDATA-000502 out: REGISTER sip:node6.communigate.com SIP/2.0
00:54:10.312 5 SIPDATA-000502 out: Via: SIP/2.0/UDP 64.173.55.170:5060;branch=z9hG4bK234
00:54:10.312 5 SIPDATA-000502 out: Max-Forwards: 69
00:54:10.312 5 SIPDATA-000502 out: From: <sip:usrname@node6.communigate.com>
00:54:10.312 5 SIPDATA-000502 out: Call-ID: 72D532E1CEB813B537E4E44058354C68-2494453@node9.communigate.com
00:54:10.312 5 SIPDATA-000502 out: Contact: <sip:299@node9.communigate.com;services=no>;expires=90
00:54:10.312 5 SIPDATA-000502 out: CSeq: 114249520 REGISTER
00:54:10.312 5 SIPDATA-000502 out: User-Agent: CommuniGatePro-gateway/5.1.4
00:54:10.312 5 SIPDATA-000502 out: Authorization: Digest realm="ns.communigate.com",username="usrname",non
00:54:10.312 5 SIPDATA-000502 out: Expires: 90
00:54:10.312 5 SIPDATA-000502 out: Content-Length: 0
00:54:10.312 5 SIPDATA-000502 out: 
00:54:10.328 2 SIPDATA-000503 inp: rsp udp [64.173.55.167]:5060 200-REGISTER(566 bytes)
00:54:10.328 5 SIPDATA-000503 inp: SIP/2.0 200 OK
00:54:10.328 5 SIPDATA-000503 inp: Via: SIP/2.0/UDP 64.173.55.170:5060;branch=z9hG4bK234
00:54:10.328 5 SIPDATA-000503 inp: From: <sip:usrname@node6.communigate.com>;tag=9B5A8DB531C3FD7A
00:54:10.328 5 SIPDATA-000503 inp: To: <sip:usrname@node6.communigate.com>;tag=7FBB267A3903E5B0
00:54:10.328 5 SIPDATA-000503 inp: Call-ID: 72D532E1CEB813B537E4E44058354C68-2494453@node9.communigate.com
00:54:10.328 5 SIPDATA-000503 inp: CSeq: 114249520 REGISTER
00:54:10.328 5 SIPDATA-000503 inp: Expires: 90
00:54:10.328 5 SIPDATA-000503 inp: Contact: <sip:299@node9.communigate.com;services=no>;expires=90
00:54:10.328 5 SIPDATA-000503 inp: Event: registration
00:54:10.328 5 SIPDATA-000503 inp: Date: Thu, 16 Mar 2006 08:53:04 GMT
00:54:10.328 5 SIPDATA-000503 inp: Allow: PUBLISH,SUBSCRIBE
00:54:10.328 5 SIPDATA-000503 inp: Allow-Events: presence,message-summary,reg,keep-alive
00:54:10.328 5 SIPDATA-000503 inp: Supported: path
00:54:10.328 5 SIPDATA-000503 inp: Server: CommuniGatePro/5.1.4
00:54:10.328 5 SIPDATA-000503 inp: Content-Length: 0
00:54:10.328 5 SIPDATA-000503 inp: 
00:54:10.328 2 SIPDATA-000503 sent to SIPC-000234
00:55:25.328 2 SIPDATA-000507 out: req udp [10.0.0.1]:5060 REGISTER(680 bytes) sip:node6.communigate.com
00:55:25.328 5 SIPDATA-000507 out: REGISTER sip:node6.communigate.com SIP/2.0
00:55:25.328 5 SIPDATA-000507 out: Via: SIP/2.0/UDP 64.173.55.170:5060;branch=z9hG4bK236
00:55:25.328 5 SIPDATA-000507 out: Max-Forwards: 69
00:55:25.328 5 SIPDATA-000507 out: From: <sip:usrname@node6.communigate.com>;tag=35270A39FB68F573
00:55:25.328 5 SIPDATA-000507 out: To: <sip:usrname@node6.communigate.com>
00:55:25.328 5 SIPDATA-000507 out: Call-ID: 72D532E1CEB813B537E4E44058354C68-2494453@node9.communigate.com
00:55:25.328 5 SIPDATA-000507 out: Contact: <sip:299@node9.communigate.com;services=no>;expires=90
00:55:25.328 5 SIPDATA-000507 out: CSeq: 114249521 REGISTER
00:55:25.328 5 SIPDATA-000507 out: User-Agent: CommuniGatePro-gateway/5.1.4
00:55:25.328 5 SIPDATA-000507 out: Authorization: Digest realm="ns.communigate.com",username="usrname",non
00:55:25.328 5 SIPDATA-000507 out: Expires: 90
00:55:25.328 5 SIPDATA-000507 out: Content-Length: 0
00:55:25.328 5 SIPDATA-000507 out: 
00:55:25.343 2 SIPDATA-000508 inp: rsp udp [64.173.55.167]:5060 200-REGISTER(566 bytes)
00:55:25.343 5 SIPDATA-000508 inp: SIP/2.0 200 OK
00:55:25.343 5 SIPDATA-000508 inp: Via: SIP/2.0/UDP 64.173.55.170:5060;branch=z9hG4bK236
00:55:25.343 5 SIPDATA-000508 inp: From: <sip:usrname@node6.communigate.com>;tag=35270A39FB68F573
00:55:25.343 5 SIPDATA-000508 inp: To: <sip:usrname@node6.communigate.com>;tag=7EF99B799DFD7632
00:55:25.343 5 SIPDATA-000508 inp: Call-ID: 72D532E1CEB813B537E4E44058354C68-2494453@node9.communigate.com
00:55:25.343 5 SIPDATA-000508 inp: CSeq: 114249521 REGISTER
00:55:25.343 5 SIPDATA-000508 inp: Expires: 90
00:55:25.343 5 SIPDATA-000508 inp: Contact: <sip:299@node9.communigate.com;services=no>;expires=90
00:55:25.343 5 SIPDATA-000508 inp: Event: registration
00:55:25.343 5 SIPDATA-000508 inp: Date: Thu, 16 Mar 2006 08:54:19 GMT
00:55:25.343 5 SIPDATA-000508 inp: Allow: PUBLISH,SUBSCRIBE
00:55:25.343 5 SIPDATA-000508 inp: Allow-Events: presence,message-summary,reg,keep-alive
00:55:25.343 5 SIPDATA-000508 inp: Supported: path
00:55:25.343 5 SIPDATA-000508 inp: Server: CommuniGatePro/5.1.4
00:55:25.343 5 SIPDATA-000508 inp: Content-Length: 0
00:55:25.343 5 SIPDATA-000508 inp: 
00:55:25.343 2 SIPDATA-000508 sent to SIPC-000236

Searching

Use your browser Find command to search for a string in the filtered portion of the CommuniGate Pro Log.

Use the Print command of your Web browser to print the filtered Log.


Time Stamps and Time Zones

Each Log record has a time stamp indicating when the record was created. The time is displayed using the local time ("GMT shift") of the CommuniGate Pro Server used when the Log file was created.

If the Server OS uses the time zone with daylight saving time, the time stamps used in the Log will not change when the local time ("GMT shift") changes. The new local time will be used when the new Log file is created.


Overflow Markers

The CommuniGate Pro Log Manager is designed as high-speed engine capable of processing thousands records per second, without delaying the execution of the Server component that generated the Log records. When some component generates a huge amount of records, (most likely, due to the Log Level set for that component), even the Log Manager may be unable to store all those records in the Log file.

If a new record cannot be placed into the Log due to a Log Manager performance problem, the Log Manager stores a short Overflow Marker instead. The Overflow Marker is a line with three asterisk (***) symbols.

If you filter the Log, the displayed part of the Log will always contain the OverFlow Markers if they exist in the selected part of the Log. If several sequential Overflow Markers have to be displayed, only the first one is displayed.


Preferences

Administrators can specify their individual Log Viewer Preferences.

Use the Preferences link to open the Monitor Preferences.

Log Manager
Log Panel Height: Open showing last: Display Limit:
Open showing last
When you open the currently active Log file, this setting specifies the inital starting time of the Time Interval (see below), so you see only the recent Log records.
When you open an inactive Log file, the Time Interval is not initialized, and the Log is displayed from the beginning.

Sending to Remote syslog Servers

You may want to send CommuniGate Pro Log records to an external syslog server.
Usually these servers are not providing the CommuniGate Pro Log Manager performance, so you should send only a small part of the Log records to those servers.

Use the following settings to configure remote logging:

Records to send
Specify the level of Log Records to be sent to a remote syslog server. Records that are more detailed than the specified value (have a higher level marker) are not sent.
Server address
Specify the IP address of the remote syslog server. If you do not specify the port number, the standard port number 514 is used.

If the Log Manager fails to open a UDP socket or fails to send a datagram to the selected remote syslog server, the Log Manager switches the Records to Send option to Nothing and it stops sending Log records to the remote syslog server.


Using a Trigger

You may want to use a Trigger Handler to send notifications when a Crash-level record is added to the CommuniGate Pro Log.

Open the Trigger Elements page in the WebAdmin Interface, and specify a Trigger Handler for the logLastCrashRecord element. When a Crash-Level (0-Level) record is added to the Log, the selected Trigger Handler is invoked.

Note: the Trigger Handler is started once in 5-10 seconds. If more than one Crash-Level records were written to the CommuniGate Pro Log during this time period, the notification message contains only the last Crash-Level record.


CommuniGate® Pro Guide. Copyright © 1998-2007, Stalker Software, Inc.