edit-icon download-icon

Audit logs

Last Updated: Feb 24, 2018

Background

The audit log function records operations performed on the databases in the instance. You can use the audit logs for fault analysis, behavior analysis, and security audit. Audit logs are generally becoming an essential regulatory requirement of Finance Cloud and other mission-critical services.

Note:MongoDB audit logs currently record only the following operations:

  • auth, admin, slow, insert, update, delete, command
  • slow queries that last over 100 msCommon queries are not recorded.

Procedure

  1. Log on to the MongoDB console.

  2. Locate the target instance and click its ID or Manage in the operation column to display the Basic Information page.

  3. In the left-side navigation pane, click Data Security.

  1. Click the Audit log tab. The following figure shows the audit log page of a replica set instance.

    Audit log

  2. You can perform the following operations:

    • Set the time range, database name, database user name, or other keywords, and click Query.
    • Click File List to display exported audit log files.
    • Click Export File to export audit logs.
Thank you! We've received your feedback.