scp ~/Downloads/GoogleChrome/mongosh-1.6.2-linux-x64.tgz remote_host:/home/sysadmin/;
ssh remote_host;
(sysadmin ~)$ tar -zxvf mongosh-1.6.2-linux-x64.tgz;
(sysadmin ~/mongosh1.6/bin)$ cd mongosh*/bin/;¡
(sysadmin ~/mongosh1.6/bin)$ chmod +x ./*;
(sysadmin ~/mongosh1.6/bin)$ sudo cp mongosh* /usr/local/bin/;
(sysadmin ~)$ mongosh;
sudo mongosh --port 27017 -u "db_user" --authenticationDatabase "db_name" -p ;
> show dbs;
> use db_name;
> show collections;
> db.collection_name.find();
Using 'mongo'
mongo --username admin --password --authenticationDatabase userdb;