JavaScript is required to for searching.
Skip Navigation Links
Exit Print View
Oracle Directory Server Enterprise Edition Administration Guide 11g Release 1 (11.1.1.5.0)
search filter icon
search icon

Document Information

Preface

Part I Directory Server Administration

1.  Directory Server Tools

2.  Directory Server Instances and Suffixes

3.  Directory Server Configuration

4.  Directory Server Entries

5.  Directory Server Security

6.  Directory Server Access Control

7.  Directory Server Password Policy

8.  Directory Server Backup and Restore

9.  Directory Server Groups, Roles, and CoS

10.  Directory Server Replication

11.  Directory Server Schema

12.  Directory Server Indexing

13.  Directory Server Attribute Value Uniqueness

14.  Directory Server Logging

15.  Directory Server Monitoring

Part II Directory Proxy Server Administration

16.  Directory Proxy Server Tools

17.  Directory Proxy Server Instances

18.  LDAP Data Views

19.  Directory Proxy Server Certificates

20.  Directory Proxy Server Load Balancing and Client Affinity

21.  Directory Proxy Server Distribution

22.  Directory Proxy Server Virtualization

23.  Virtual Data Transformations

24.  Connections Between Directory Proxy Server and Back-End LDAP Servers

25.  Connections Between Clients and Directory Proxy Server

26.  Directory Proxy Server Client Authentication

27.  Directory Proxy Server Logging

Viewing Directory Proxy Server Logs

Configuring Directory Proxy Server Logs

To Configure Directory Proxy Server Logs

To Configure Directory Proxy Server Access Log etimes Units

Configuring Directory Proxy Server Log Rotation

To Configure Periodic Log Rotation

To Rotate Log Files

To Disable Log Rotation

Example Configurations for Log Rotation

Rotating the Log Based on Log Size

Rotating the Log Based on Time

Rotating the Log Based on Time and Log Size

Compressing Log Files After Rotation

Deleting Directory Proxy Server Logs

To Configure Log Deletion Based on Time

To Configure Log Deletion Based on File Size

To Configure Log Deletion Based on Free Disk Space

Logging Alerts to the syslogd Daemon

To Configure Directory Proxy Server to Log Alerts to the syslogd Daemon

Configuring the Operating System to Accept syslog Alerts

To Configure the Solaris OS to Accept syslog alerts

To Configure Linux to Accept syslog Alerts

To Configure HP-UX to Accept syslog alerts

Tracking Client Requests Through Directory Proxy Server and Directory Server Access Logs

To Track Operations From Directory Server Through Directory Proxy Server to the Client Application

28.  Directory Proxy Server Monitoring and Alerts

Part III Directory Service Control Center Administration

29.  Directory Service Control Center Configuration

Index

Configuring Directory Proxy Server Log Rotation

By default, log files are rotated when the log file size reaches 100 Mbytes. Ten log files are retained by default, after which the rotation procedure begins to overwrite the oldest log file. This section describes how to configure Directory Proxy Server logs for scheduled rotation, how to rotate logs manually, and how to disable log rotation. For example configurations, see Example Configurations for Log Rotation.

To Configure Periodic Log Rotation

The example in this procedure configures the Directory Proxy Server access log. You can use the same procedure to rotate the Directory Proxy Server bind, connection, or error log. Be sure to replace access with bind, connection, or error depending upon the log you are configuring

You can use DSCC to perform this task. For information, see Directory Service Control Center Interface and the DSCC online help.

  1. (Optional) View the properties of the access log.
    $ dpconf get-access-log-prop -h host -p port
  2. (Optional) View valid values for the properties of the access log.
    $ dpconf help-properties access-log
  3. To rotate logs when they reach a certain size, set the following properties:
    $ dpconf set-access-log-prop -h host -p port \
     log-rotation-policy:size log-rotation-size:maximum file size

    Caution

    Caution - In case of high activity levels, because of the asynchronous nature of Directory Proxy Server, the log file might not be rotated at the exact configured size but at a size close to the configured size. This means that the rotated file might end up being slightly smaller or slightly larger than the configured size.


    If the unit of the maximum file size is not specified, the default unit of bytes is used. When the log file reaches the defined size, the log is rotated. The file size must be at least 1 Mbyte and no more than 2 Gbytes.

    For an example of how to rotate logs by size, see Rotating the Log Based on Log Size.

  4. To rotate logs periodically, irrespective of the log size, set the following properties:
    $ dpconf set-access-log-prop -h host -p port \
     log-rotation-frequency:interval in months, weeks, hours, or minutes \
     log-rotation-policy:periodic \
     log-rotation-start-day:day in week (1-7) or day in the month (1-31) \
     log-rotation-start-time:time of day (hhmm)

    If the log is configured for rotation on the 31st of the month but the month has fewer than 31 days, the log is rotated on the first day of the following month.

    By default, the log-rotation-start-day and log-rotation-start-time properties have no default value. If you configure to rotate logs without setting these properties, the log will be rotated as per the specified frequency but the time of the day or day of the week might be changed.

    For examples of how to rotate logs periodically, see Rotating the Log Based on Time.

  5. To rotate logs periodically if the log file is big enough, set the log-rotation-frequency and log-min-size properties.
    $ dpconf set-access-log-prop -h host -p port \
     log-rotation-frequency:interval in months, weeks, hours, or minutes \
     log-rotation-policy:periodic log-min-size:minimum file size
     log-rotation-start-day:day in week (1-7) or day in the month (1-31) \
     log-rotation-start-time:time of day (hhmm)

    The log-min-size property represents the minimum size of the log. The rotation takes place at the scheduled time only if the log file is bigger than the specified size.

    If the log is configured for rotation on the 31st of the month but the month has fewer than 31 days, the log is rotated on the first day of the following month.

    By default, the log-rotation-start-day and log-rotation-start-time properties have no default value. If you configure to rotate logs without setting these properties, the log will be rotated as per the specified frequency but the time of the day or day of the week might be changed.

    For an example of how to rotate logs periodically if the file size is big enough, see Rotating the Log Based on Time and Log Size.

  6. To compress log files after a rotation, set the log-file-compression property. Example:
    $ dpconf set-access-log-prop -h host -p port log-file-compression:best-speed

    When the log-file-compression option is active, the Directory Proxy Server compresses the log files with every rotation. Compressed files will include the .zip extension. The current file is never compressed.

    For best results, set the log-file-compression property to either no-compression or best-speed. Although other values may work, they might take too much time to complete in the current hardware. This could slow down the Directory Proxy Server performance with an insufficient gain in the compression rate. The default value is no-compression, which is compatible with previous versions of the Directory Proxy Server.

    Also, note that DSCC will not be able to show compressed log files.

To Rotate Log Files

The example in this procedure rotates the Directory Proxy Server access log. You can use the same procedure to rotate the Directory Proxy Server bind, connection, or error log. Be sure to replace access with bind, connection, or error depending upon the log you are configuring.

You can use DSCC to perform this task. For information, see Directory Service Control Center Interface and the DSCC online help.

To Disable Log Rotation

The example in this procedure disables rotation of the Directory Proxy Server access log.You can use the same procedure to disable rotation of the Directory Proxy Server bind, connection, or error log. Be sure to replace access with bind, connection, or error depending upon the log your are configuring.

Example Configurations for Log Rotation

Examples of how to configure log rotation by log size, time, or both follow.

Rotating the Log Based on Log Size

This section example shows how to configure a log rotation according to log size only. This configuration rotates the log when it reaches 10 Mbytes, irrespective of the time since the log was last rotated.

$ dpconf set-access-log-prop -h host1 -p 1389 log-rotation-policy:size \
  log-rotation-size:10M

Rotating the Log Based on Time

The examples in this section show how to configure log rotation according to the time since the last rotation, irrespective of log size.

If the log-rotation-start-day is set to 31 and the month has only 30 days, the log is rotated on the first day of the following month. If the log-rotation-start-day is set to 31 and the month has only 28 days (February), the log is rotated on the 3rd.

Rotating the Log Based on Time and Log Size

This example shows how to configure a log rotation for a specified interval if the file size is big enough.

This configuration rotates the log at 3:00, 11:00, and 19:00 every day, if the size of the log file exceeds 1 Mbyte. If the size of the log file does not exceed 1 Mbyte, the log file is not rotated.

$ dpconf set-access-log-prop -h host1 -p 1389 log-rotation-frequency:8h \
 log-rotation-policy:periodic log-min-size:1M log-rotation-start-time:0300

Compressing Log Files After Rotation

Whichever the rotation policy chosen, the log files can be compressed once they are rotated. This example activates this feature.

$ dpconf set-access-log-prop -h host1 -p 1389 log-file-compression:best-speed