In this example, we restore the purchases collection to the sweetscomplete database, adding a verbosity level of 2, while maintaining database integrity, as follows:
mongorestore --db=sweetscomplete --collection=purchases --drop --objcheck \
--verbose=2 --dir=/root/backup/sweetscomplete/purchases.bson
Here is the output from this command:
Note that if you use the --db and --collection options, you must also use --dir to indicate the associated BSON file.