diff --git a/source/reference/program/mongostat.txt b/source/reference/program/mongostat.txt index 545707d1d9f..fa6bfa52c0a 100644 --- a/source/reference/program/mongostat.txt +++ b/source/reference/program/mongostat.txt @@ -17,6 +17,15 @@ instance. :program:`mongostat` is functionally similar to the UNIX/Linux file system utility ``vmstat``, but provides data regarding :program:`mongod` and :program:`mongos` instances. +.. important:: In order to connect to a :program:`mongod` that enforces + authorization with the :option:`--auth ` option, the + :option:`--username ` and + :option:`--password ` options must be used, and the + user specified must have the :authaction:`serverStatus` privilege. + + The most appropriate built-in role that has this privilege is + :authrole:`clusterMonitor`. + .. seealso:: For more information about monitoring MongoDB, see @@ -32,12 +41,6 @@ UNIX/Linux file system utility ``vmstat``, but provides data regarding For an additional utility that provides MongoDB metrics see :doc:`mongotop `. -:program:`mongostat` connects to the :program:`mongod` instance running -on the local host interface on TCP port ``27017``; however, -:program:`mongostat` can connect to any accessible remote :program:`mongod` -instance. - - Options ------- diff --git a/source/reference/program/mongotop.txt b/source/reference/program/mongotop.txt index d9c6b34d2ce..97895dd9758 100644 --- a/source/reference/program/mongotop.txt +++ b/source/reference/program/mongotop.txt @@ -16,6 +16,16 @@ MongoDB instance spends reading and writing data. :program:`mongotop` provides statistics on a per-collection level. By default, :program:`mongotop` returns values every second. +.. important:: In order to connect to a :program:`mongod` that enforces + authorization with the :option:`--auth ` option, the + :option:`--username ` and + :option:`--password ` options must be used, and the + user specified must have the :authaction:`serverStatus` and + :authaction:`top` privileges. + + The most appropriate built-in role that has these privileges is + :authrole:`clusterMonitor`. + .. seealso:: For more information about monitoring MongoDB, see