Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Mongo Explorer in Web Storm

I'm trying to log into my mongolab db from webstorm plugin. My problem is that I cant connect into url like: mydb.mongolab.com:8080, my user doesn't have permissions and so I get "auth failed". I have to put my url with db on the end like: mydb.mongolab.com:8080/database1 I just don't know how to put that url into Add mongo server dialog. It always gives me: "Port in the url is incorrect, it should be a number."

Does anyone knows what to do about that?

like image 623
Jan Omacka Avatar asked Dec 09 '22 00:12

Jan Omacka


1 Answers

I literally just solved my issue and this is how I did it

The General tab

so you're basically given a url like this in your portal

mongodb://:@ds050879.mlab.com:50879/blogdb

the server url is ds050879.mlab.com:50879

it is in the format host:port where host is ds050879.mlab.com and port is 50879

next set user database to the name of your database (in this case blogdb). The Read references can stay on primary. Picture Of The General Tab Configuration

Authentication tab

  • set username to your username
  • and password to your password
  • Auth.database will be the name of your database (in this case blogdb)
  • Finally, set Auth. mechanism to SCRAM-SHA-1 Picture of the Auth Tab Configuration

and then click test connection.

you should receive a message that says connection test successful then click okay. Click okay again to save your settings.. and voila Now it should be displayed in the explorer

Now you are ready to use the shell

and sorry I don't have enough reputation to display images and links but click the links to check out the steps if you get stuck

use these images as guides

https://i.stack.imgur.com/Kb5ER.png https://i.stack.imgur.com/n3ckQ.png https://i.stack.imgur.com/bqgcr.png https://i.stack.imgur.com/6SOfc.png https://i.stack.imgur.com/8h2iS.png

like image 116
Barnabas Nomo Avatar answered Dec 21 '22 19:12

Barnabas Nomo