AI 에이전트의 경우: 문서 인덱스는 https://www.mongodb.com/ko-kr/docs/llms.txt에서 사용할 수 있으며, 모든 페이지의 마크다운 버전은 어떤 URL 경로에 .md를 추가하여 사용할 수 있습니다.
Docs Menu

감사 로그 구성

참고

  • 이 기능 M0 클러스터 및 Flex 클러스터에서는 사용할 수 없습니다.

You can use Atlas Kubernetes Operator to configure audit logs. To learn more, see Set Up Database Auditing.

관리자는 데이터베이스 감사를 통해 다중 사용자가 있는 배포 시스템의 활동을 추적할 수 있습니다. Atlas 관리자는 감사할 조치, 데이터베이스 사용자, Atlas 역할, LDAP 그룹을 선택할 수 있습니다. Atlas는 문서화된 시스템 이벤트 작업의 대다수에 대한 감사를 지원합니다. 단, 다음과 같은 제한이 적용됩니다.

  • When an Atlas user performs an action in the Atlas UI on a cluster, both the audit logs and mongodb.log file log the mms-automation database user as the user performing the auditable action. However, the Project Activity Feed logs the actual username of the Atlas user responsible for the action.

  • 이 작업은 Atlas의 admin 데이터베이스에서 직접 수행됩니다. 따라서 Atlas 감사 로그는 사용자 생성 또는 수정 이벤트를 추적하지 않습니다.

중요

전체 데이터베이스 감사 수행하기

이러한 제한 사항으로 인해 전체 감사를 수행하려면 감사 로그, mongodb.log 및 프로젝트 활동 피드 조합을 사용해야 합니다.

authCheck 이벤트 조치는 프로젝트의 cluster 내 데이터베이스에서 읽거나 데이터베이스에 하는 작성하려는 사용자의 권한 부여를 기록합니다. Atlas는 다음과 같은 특정 명령어를 감사합니다.

[1](1, 2, 3) MongoDB versions 4.2 and later don't support these commands.

Atlas는 authCheck 이벤트 작업을 다음의 네 가지 개별 작업으로 구현합니다.

이벤트 조치
설명

authChecksReadFailures

authCheck auditAuthorizationSuccess 매개변수가 false로 설정된 실패한 읽기 작업 모두에 대한 이벤트 조치입니다. 이 이벤트 조치는 읽기 관련 이벤트 조치의 기본값입니다.

authChecksReadAll

authCheck 이벤트 조치는 성공과 실패 모두에 대한 모든 읽기에 대한 이벤트 작업입니다. 이러한 이벤트 조치는 authChecksReadFailures와 동일하지만 auditAuthorizationSuccess 매개 변수가 true로 설정되어 있습니다.

경고: auditAuthorizationSuccess 를 활성화 하면 클러스터 성능에 심각한 영향 을 미칠 수 있습니다. 이 옵션은 주의해서 활성화하세요.

authChecksWriteFailures

authCheck event action for all failed writes with the auditAuthorizationSuccess parameter set to false. This event action is the default for write-related event actions.

authChecksWriteAll

authCheck 성공과 실패를 막론한 모든 쓰기에 대한 이벤트 작업입니다. 이러한 이벤트 조치는 authChecksWriteFailures와 동일하지만 auditAuthorizationSuccess 매개 변수가 true로 설정되어 있습니다.

경고: auditAuthorizationSuccess 를 활성화 하면 클러스터 성능에 심각한 영향 을 미칠 수 있습니다. 이 옵션은 주의해서 활성화하세요.

To learn about how MongoDB writes audit events to disk, see Audit Guarantee in the MongoDB Manual.

To configure audit logs, you must have Project Owner access to the project that you want to update or Organization Owner access to the organization that contains the project that you want to update.

참고

임시 데이터베이스 사용자의 작업을 감사하는 권장사항에 대해 학습하려면 임시 데이터베이스 사용자 감사를 참조하세요.

감사 로그를 활성화 하려면 true AtlasProject Custom Resource(사용자 지정리소스) 에서 spec.auditing.enabled 를(으)로 설정하십시오.

예시:

cat <<EOF | kubectl apply -f -
apiVersion: atlas.mongodb.com/v1
kind: AtlasProject
metadata:
name: my-project
spec:
name: TestAuditing
connectionSecretRef:
name: my-atlas-key
projectIpAccessList:
- cidrBlock: "0.0.0.0/1"
comment: "Everyone has access. For test purposes only."
- cidrBlock: "128.0.0.0/1"
comment: "Everyone has access. For test purposes only."
auditing:
enabled: true
EOF

To retrieve the audit logs in Atlas, see MongoDB Logs. To retrieve the audit logs using the API, see Logs.

참고

  • 이 기능 M0 클러스터 및 Flex 클러스터에서는 사용할 수 없습니다.

Atlas는 JSON 형식의 감사 필터를 지정하여 MongoDB 감사를 맞춤 설정하는 것을 지원합니다.

Custom audit filters lets users forgo the managed Atlas UI auditing filter builder in favor of hand-tailored granular control of event auditing. Atlas checks only that the custom filter uses valid JSON syntax, and doesn't validate or test the filter's functionality.

감사 필터 문서는 감사 이벤트 메시지의 필드의 하나 이상과 일치하는 쿼리로 해석되어야 합니다. 필터 문서는 쿼리 작업자 와 동일 조건의 조합을 사용하여 원하는 감사 메시지를 일치시킬 수 있습니다.

To view example auditing filters, see Example Auditing Filters. To learn more about configuring MongoDB auditing filters, see Configure Audit Filter.

중요

Atlas uses a rolling update strategy for enabling or updating audit configuration settings across all clusters in the Atlas project. Rolling updates require at least one election per replica set.

To learn more about testing application resilience to replica set elections, see /tutorial/test-resilience/test-primary-failover. To learn more about how Atlas provides high availability, see Atlas High Availability.

사용자 지정 감사 필터하다 구성하려면 AtlasProject Custom Resource(사용자 지정 리소스)에서 spec.auditing.auditFilter 설정을 지정합니다. 이 설정의 값을 지정하려면 spec.auditing.enabled 를 true(으)로 설정해야 합니다.

예시:

cat <<EOF | kubectl apply -f -
apiVersion: atlas.mongodb.com/v1
kind: AtlasProject
metadata:
name: my-project
spec:
name: TestAuditing
connectionSecretRef:
name: my-atlas-key
projectIpAccessList:
- cidrBlock: "0.0.0.0/1"
comment: "Everyone has access. For test purposes only."
- cidrBlock: "128.0.0.0/1"
comment: "Everyone has access. For test purposes only."
auditing:
enabled: true
auditFilter: "{"atype": "authenticate"}"
EOF

To learn more about the configuration parameters available from the API, see the Atlas Auditing.