enable-audit-logging.asciidoc 1.2 KB

12345678910111213141516171819202122232425262728293031
  1. [role="xpack"]
  2. [[enable-audit-logging]]
  3. == Enable audit logging
  4. You can log security-related events such as authentication failures and refused connections
  5. to monitor your cluster for suspicious activity (including data access authorization and user
  6. security configuration changes).
  7. Audit logging also provides forensic evidence in the event of an attack.
  8. [IMPORTANT]
  9. ============================================================================
  10. Audit logs are **disabled** by default. You must explicitly enable audit logging.
  11. ============================================================================
  12. --
  13. TIP: Audit logs are only available on certain subscription levels.
  14. For more information, see {subscriptions}.
  15. --
  16. To enable audit logging:
  17. . Set `xpack.security.audit.enabled` to `true` in `elasticsearch.yml`.
  18. . Restart {es}.
  19. When audit logging is enabled, <<audit-event-types, security events>> are persisted to
  20. a dedicated `<clustername>_audit.json` file on the host's file system, on every cluster node.
  21. For more information, see <<audit-log-output>>.
  22. You can configure additional options to control what events are logged and
  23. what information is included in the audit log.
  24. For more information, see <<auditing-settings>>.