2.4.2 Viewing logs in the command line

The access log, by default, is at /var/opt/dirsrv/admin-serv/log/access. To view the access log, open it with a paging utility such as more.

Access logs show connections to the Admin Server based on the IP address of the client, the username, and the method that the request was sent. Each line has the following format:

ip_address - bind_DN [timestamp -0500] "GETPOST cgi" HTTP_response bytes

Example logs are shown in Example 2-1 “Example access logs”.Example 2-1 Example access logs

127.0.0.1- cn=directory manager [23/Dec/2009:19:32:52 -0500] "GET /admin-serv/authenticate HTTP/1.0" 200 338

192.168.123.121 - cn=directory manager [23/Dec/2009:19:33:14 -0500] "POST /admin-serv/tasks/Configuration/ServerSetup HTTP/1.0" 200 244 192.168.123.121 - cn=directory manager [23/Dec/2009:19:33:16 -0500] "GET /admin-serv/tasks/Configuration/ReadLog?op=count&name=access HTTP/1.0" 200 10

The error log, by default, is at /var/opt/dirsrv/admin-serv/log/error. To view the error log, open it with a paging utility such as more.

Error logs record any problem response from the Admin Server. Like the access log, error logs also records entries based the client's IP adress, along with the type of error message, and the message text:

[timestamp] [severity] [client ip_address error_message

The severity message indicates whether the error is critical enough for administrator intervention. [warning], [error], and [critical] require immediate administrator action. Any other severity means the error is informational or for debugging.

Example logs are shown in Example 2-2 “Example error logs”.

2.4 Viewing logs

11