Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

Navigation

Configuring Binary Security Log Files

You can configure security files in binary format using the log statement at the [security] hierarchy level.

The following procedure specifies binary format for event-mode or stream-mode logging, and defines the log filename, path, and log file characteristics.

  1. Specify the format for the log file.
    • For on-box, event-mode logging:
      set security log mode eventset security log format binary
    • For off-box, stream-mode logging:
      set security log mode streamset security log stream test-stream format binary host 1.3.54.22
  2. For off-box security logging, specify the source address, which identifies the SRX Series device that generated the log messages. The source address is required.
    set security log source-address 2.3.45.66
  3. Optionally, define a log filename and a path. By default, the file bin_messages is created in the /var/log directory.
    set security log file name security-binary-log set security log file path security/log-folder
  4. Optionally, change the maximum size of the log file and the maximum number of log files that can be archived. By default, the maximum size of the log file is 3 MB, and a total of three log files can be archived.
    set security log file size 5set security log file files 5
  5. Optionally, select the hpl flag to enable diagnostic traces for binary logging. The prefix smf_hpl identifies all binary logging traces.
    set security log traceoptions flag hpl
  6. View the content of the event-mode log file stored on the device.

    Note: The show security log command displays event-mode security log messages if they are in a text-based format. The show security log file command displays event-mode security log messages if they are in binary format.

    show security log file

    Use the following command to clear the content of the binary event-mode security log file.

    clear security log file

    Note: Third-party tools decode and convert log files to binary text when they are streamed to a remote device. Refer to your third-party documentation for details about displaying streamed security log messages.

Published: 2014-05-07