When performing maintenance you may want to check which indexes exist
on a collection. Every index on a collection has a corresponding
document in the system.indexes collection, and you can use standard
queries (i.e. find()) to list the indexes, or
in the mongo shell, the
getIndexes() method to return a list of the
indexes on a collection, as in the following examples.