File tree Expand file tree Collapse file tree 1 file changed +19
-1
lines changed
Expand file tree Collapse file tree 1 file changed +19
-1
lines changed Original file line number Diff line number Diff line change @@ -61,7 +61,7 @@ podman run -d -p 9216:9216 percona/mongodb_exporter:0.40 --mongodb.uri=mongodb:/
6161docker run -d -p 9216:9216 percona/mongodb_exporter:0.40 --mongodb.uri=mongodb://127.0.0.1:17001
6262```
6363
64- #### Permissions
64+ ### Permissions
6565Connecting user should have sufficient rights to query needed stats:
6666
6767```
@@ -74,6 +74,24 @@ Connecting user should have sufficient rights to query needed stats:
7474 "db":"local"
7575 }
7676```
77+ When using the PBM collector to get metrics from Percona Backup for MongoDB, the user should also have sufficient privileges
78+ to query the PBM internal collections (in the ` admin ` database). One option is to grant ` find ` privileges on the ` admin ` collection:
79+ ```
80+ privileges: [
81+ { resource: { db: "admin", collection: "" }, actions: [ "find" ] },
82+ ],
83+ ```
84+
85+ Alternatively, you can grant the ` find ` privilege for each PBM internal collection (see: https://docs.percona.com/percona-backup-mongodb/details/control-collections.html ):
86+ ```
87+ privileges: [
88+ { resource: { db: "admin", collection: "pbmBackups" }, actions: [ "find" ] },
89+ { resource: { db: "admin", collection: "pbmAgents" }, actions: [ "find" ] },
90+ { resource: { db: "admin", collection: "pbmConfig" }, actions: [ "find" ] },
91+ ...
92+ ],
93+ ```
94+ However, this is not recommended as the list of internal collections may change in future releases.
7795
7896More info about roles in MongoDB [ documentation] ( https://docs.mongodb.com/manual/reference/built-in-roles/#mongodb-authrole-clusterMonitor ) .
7997
You can’t perform that action at this time.
0 commit comments