I like to find out on which port MMS agent is running for Mongo. Please let me know how to find out. It is not defined on config file. It may be running on default port.
Thanks for your update. It is MongoDB Cloud Manager. I like to know if they use any port for connections like MongoDB database does. It looks it does not as per your answer.
Related
I have MongoDB installed on my desktop, using which I have developed a web application. I want to now deploy this webapp on an EC2 linux instance and test it. I don't want to setup another mongoDB on the EC2 separately, rather use the one on my desktop. I understand that it is not that simple to put my ip and mongo port and just connect.
I have added port-forwarding settings on my router like this -
Also I have opened my firewall for this port by adding an inbound rule.
Yet I'm not able to connect. What am I missing here?
Thanks in advance
I am trying to assist a customer in getting RESTHeart up and connected to MongoDB that is hosted on AmazonAWS. The startup from the yml file looks like it is connecting to our MongoDB (yellow highlight in attachment) but then it fails with a bind error. Have tried setting the mongo-uri with and without port, IP and hostname all with the same result. I checked the softinstigate site for help or a forum and they suggest here. Any suggestions or guidance would be greatly appreciated.
Statup log with DEBUG on
The http and https are bound to the same address. This is not possible.
In the log I also spot
Mongodb version: ?
This is usually due to restheart not communicating with mongodb. You have to check your network settings...
Are you able to telnet to mongodb from the host running restheart?
I'm trying "Your-first-Kaa-application", but i have a stuck at "Set up log appender" step.
http://kaaproject.github.io/kaa/docs/v0.10.0/Programming-guide/Key-platform-features/Data-collection/MongoDB-log-appender/
Flow the example at the link above, they set mongoServers with "host" and "port" like below text:
"mongoServers":[
{
"host":"127.0.0.1",
"port":27017
}
But I don't understand host and port mean, and in my situation (My own network, my own computer, my own kaa sandbox server ...)
How to find my system's hostand port.
Please help me!
Thanks!!
The MongoDB log appender is responsible for transferring logs from the
Operations service to the MongoDB database.
So that means you should install MongoDB and run it.And then add your MongoDB server host and port to the configuration.
I am trying an example at Spring 3 with MongoDB. I can reach MongoDB's interface on port 28017. However examples use 27017 in configuration files. Which one to use?
28017 is admin interface and admin operations can be checked from there via web. However when using MongoDb at applications 27017 should be defined as port. When trying to reach that port given information is that:
You are trying to access MongoDB on the native driver port. For http diagnostic access, add 1000 to the port number
I find it very interesting by doing a very stupid thing. Added 1000 to 27017 and it become 28017, I access localhost:28017 and the admin panel appeared.
best of luck
I suggest you do not use default port in your application.
that is the first hackers are looking for.
Im reading the mongodb guide, but I dont get this:
mongodb://fred:foobar#localhost
It says I can connect to the mongodb through web browser.
I have tried this, but it doesn't work. Safari/Firefox can't recognize the mongodb protocol.
And why should I do it?
Isn't the mongodb server just for connecting through the command line?
And what is the difference between port 27017 and 28017?
Should I connect through http or mongodb protocol?
When you start mongod (the MongoDB daemon), it starts listening on two ports by default.
27017: the default port accessed by the various MongoDB drivers.
28017: a port that handles HTTP requests and provides some general monitoring.
What you've listed mongodb://fred:foobar#localhost actually represents this: mongodb://fred:foobar#localhost:27017 and this is the access protocol for MongoDB drivers.
The other "thing" you're seeing is port 28017. This is (by default) simply an overview of what's happening with the mongod instance on that server. Requests made from a web browser to this port will show an HTML output of the server overview.
If you start mongod with a different port number (i.e.: 7777), the "monitor" port will always be 1000 higher (i.e.: 8777).
If you want some advanced features like the ability to query via the web browser, you can start mongod with the --rest switch. You will then be able to run certain queries with a simple http get requestlink text (http://localhost:8777/mydb/mycollection/?filter_a=1).
If you're using language-specific MongoDB drivers (like most people will). Then you'll find that you'll have "connection strings" of the form mongodb://user:pwd#host:port/. These are similar in purpose to the usual connection strings you're used to for other Database products.
Increment by one thousand (28017), and use HTTP, not mongodb.
Note that this will "connect" you to the mongodb process, but it's not like phpMyAdmin or anything.