Errors and Logging
servedat produces a log of individual transactions, errors, and state changes. This information is vital to diagnosing problems, and can also be used to generate usage statistics.
Log Filtering
By default, servedat does NOT log successful initiation or completion of bulk data transfers. This is done to improve performance for high-rate activities such as SyncDat synchronizations or hierarchial transfers. The level of filtering can be set using the LogFilter configuration variable or the -F command line option. The default filtering level is 2.
| 0 | No filtering: at least one line of output will be logged for every transaction. |
| 1 | Initiation of bulk transactions will not be logged. |
| 2 | Success reports for bulk transactions will also be suppressed. Bulk errors will still be reported. |
| 3 | All initiation lines and bulk successes will be suprressed. |
| 4 | Only errors will be logged. |
| 5 | Only server and non-bulk errors will be logged. |
| 6 | Only server errors will be logged |
Line Format
Each line of diagnostic output takes the following form:
[Type] [Date] [Time] [Message]
| Type | A single character denoting the type of message: |
| C | Comment or Configuration note |
| D | Debugging output |
| E | General server error |
| F | The final disposition of an action. There will be exactly one of these per action. |
| I | Initiation of an action which has not yet completed. There will be at most one of these per action. |
| M | Message from one of the MTP libraries |
| W | Warning or detailed error regarding an action in progress. |
| Date | Eight characters giving the year, month, and day as YYYYMMDD |
| Time | Eight characters giving the hour, minute, and second in localtime as HH:MM:SS |
| Message | The message format will vary for C, M, E, and W. I and F type messages will adhere to the following format:
DocID SEND|GET Client User Encrypt "Path" "Pack" Resp "Comment" |
Following is a sample of servedat log output illustrating the format:
C 20071117 16:24:23 servedat - 1.10.3 Nov 2007 - DEI, DOC-1.8.10 MTP-darwin-3.12.12 US Pat. 7158479 C 20071117 16:24:23 00000000: ExpeDat-1.9-4 Data Expedition Inc. - DataExpedition.com, Internal C 20071117 16:24:23 Default Home: ./ I 20071117 17:08:05 E0F03BDA GET 65.69.251.121:49897 - - "./" "" F 20071117 17:08:05 E0F03BDA GET 65.69.251.121:49897 - - "./" "" 584 "0.05 seconds (88.2 kilobits/sec)" I 20071117 17:10:25 E0E717FC GET 65.69.251.121:49910 deiuser AES "tst/test.1mb" "" F 20071117 17:10:25 E0E717FC GET 65.69.251.121:49910 deiuser AES "tst/test.1mb" "" 1048576 "0.20 seconds (43.0 megabits/sec)"
Log Location
When servedat is run from the command line, this text is sent to stderr if that is a terminal. You may redirect this to a file using the command shell. You can also tell servedat to append to a file specified by the "-l" option or the the LogFile configuration variable. servedat will not launch if it is unable to append to the given log file.
If servedat is run as a root daemon in unix it will default to writing diagnostic output to the file /var/log/servedat.log or /var/adm/servedat.log, depending on the platform.
If servedat is run as a Windows Service, it will default to writing diagnostics to the common Application Data folder, usually C:\Documents and Settings\All Users\Application Data\DEI\servedat.log. You can use the enclosed "Shortcut to servedat.log" link to open the log file, if it exists.
Log Rotation
On unix systems, sending the HUP signal to a running servedat process will cause it to restart and reload all of its configuration settings. This includes closing the existing log file and opening a new one, which can be useful for log rotation. Note that any active transactions will be immediately terminated by such a restart.
Diagnostics
If you experience difficulties configuring or communicating with the server, the servedat logs will provide important information about what happened. Please include a copy of the relevant log lines with any Technical Support Request.