dbHash
On this page
Definition
-
dbHash
-
Returns the hash values of the collections in a database and an MD5 value for the list of collections.
dbHash
is useful to compare databases acrossmongod
instances, such as mirrored config servers for sharded clusters or members of replica sets.dbHash
has the following syntax:Field Type Description dbHash
Any type The command to run. Specify any value. collections
array Optional. An array of collection names.
Either specify the collections for which to return the hash values, or omit or specify an empty array to return the hash values for all collections in the database.
Behavior
If a collection in the collections
array is non-existent, dbHash
does not return a hash value for that collection.