Enabling a Load Balancer Log

Enable an access or error log for a load balancer.

For prerequisite information, see Logging for Load Balancers.

Note

You can only enable an access or error log when there no existing logs of that type present. A load balancer can only have one access and one error log each.

Using the Console

  1. Open the navigation menu, click Networking, and then click Load balancers. Click Load balancer. The Load balancers page appears.
  2. Select the Compartment from the list. All load balancers in that compartment are listed in tabular form.
  3. Select a State from the list to limit the load balancers displayed to that state.
  4. Select the load balancer for which you want to create a log. The load balancer's Details page appears.
  5. Click Logs under Resources. The Logs list appears. Entries for access and error logs are listed in tabular form.
  6. Click the Actions menu (Actions Menu) associated with the access or error category and click Enable. The Enable log dialog box appears.
  7. Complete the following:
    • Compartment: Select the compartment within which the log file resides from the list.

    • Log group: Select an existing log group from the list or click Create new group where you can enter the name and description of a new logging group within which your log resides.

    • Log name: Enter the name of the log.

    See Logs and Log Groups for more information on log and log groups, including naming syntax guidelines.

  8. (Optional) Click Show advanced options to use these features. The Log retention panel appears.
  9. Select the time period in months each error logging entry is to be retained from the Log retention list.
  10. (Optional) Apply any tags to the log. See Overview of Tagging for more information.
  11. Click Enable log.
  12. To enable the request ID option to help track requests and troubleshoot logs, click Edit next to Request ID

    Use the toggle button to enable the request ID. The Request ID can help you with tracking and managing a request by providing a unique request identifier exposed in HTTP request and response headers.

    When the request ID is enabled, the default header name X-Request-Id is included in the HTTP request header from the load balancer to the backend and HTTP header responses. If not enabled, the load balancer won't add this unique request ID header to the request passed through to the load balancer backend or to the response returned.

    You can use the Request ID header name option to enter a different header name instead of using the default. Any custom header name must start with "X-".