Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

I want to connect openshift mongodb database from my local client tools

  • I have my premium openshift account
  • I have all types of access in openshift
  • I have ssh key & user's credentials
  • I have MongoVUE & Robomongo & others client tools to open mongodb database.
  • when I try to open any local mongodb database then its working fine
  • but I want to directly connect my mongodb database of openshift server to mongoVUE or any else so I can see which data is in my server database.
  • I have tried so many times to connect locally but it can connect to openshift but can not connect with mongodb database so please provide some good & exact steps so I can connect it.
like image 812
Dr. Piyush Dholariya Avatar asked Nov 20 '14 06:11

Dr. Piyush Dholariya


2 Answers

I use mongovue also. Just do a 'rhc port-forward '

Then run mongovue using the Mongodb credentials that OPENSHIFT gave you.

Steps.

 rhc port-forward <app-name>

Wait a couple of seconds. You then should see something like this.

port forward image

Then run Mongovue. Add a connection and enter in your Openshift Mongodb credentials like this:

Mongovue

Save, Select your connection, and press connect. It should work.

You should have been given you mongodb credentials when you added the mongodb cartridge. You can also ssh into your app and do a "env" and see your mongodb password and username.

like image 169
fat fantasma Avatar answered Sep 30 '22 16:09

fat fantasma


Finally I got perfect tool for it to connect with mongodb with server database in which we can perform all kind of CRUD operations. we can use Robomongo tool for it which doesn't require paid version to perform CRUD operation. Robomongo is available here http://robomongo.org/download.html mongoVUE requires paid version.

I use Robomongo. Just do a 'rhc port-forward '

Then run Robomongo using the Mongodb credentials that OPENSHIFT gave you.

Steps.

rhc port-forward Wait a couple of seconds. You then should see something like this.

port forward image

Then run Robomongo. Add a connection and enter in your Openshift Mongodb credentials:

like image 26
Dr. Piyush Dholariya Avatar answered Sep 30 '22 16:09

Dr. Piyush Dholariya