PingDirectory

Creating log publishers

Create a new log publisher with dsconfig, either from the command line or in interactive mode.

About this task

Retention and rotation policies must be configured for the log publisher. Perform the following steps to create a log publisher.

Compression cannot be disabled or turned off once configured for the logger. Determine logging requirements, prior to creating and configuring them.

Steps

  1. Run the following command to create a log publisher with the dsconfig command that logs disconnect operations.

    $ bin/dsconfig create-log-publisher \
      --type file-based-access --publisher-name "Disconnect Logger" \
      --set enabled:true \
      --set "rotation-policy:24 Hours Time Limit Rotation Policy" \
      --set "rotation-policy:Size Limit Rotation Policy" \
      --set "retention-policy:File Count Retention Policy" \
      --set log-connects:false \
      --set log-requests:false --set log-results:false \
      --set log-file:logs/disconnect.log
    1. To configure compression on the logger, add this option to the previous command:

      --set compression-mechanism: gzip
  2. To view log publishers, run the command:

    $ bin/dsconfig list-log-publishers