Hello, I am trying to connect Jasper running on an EC2 instance to a Mongo server running on EC2. I can connect to both servers externally with no issue. I then unblocked all incoming TCP ports on the Mongo server for the Jasper EC2 instance IP address. Jasper just tells me that connection failed.
Assaf is right SSH to the instances and see if they can see each other. In a standard AWS deployment both will be in different networks and will not be able to see each other. If both are in the same account you can try using the internal AWS IP (check the AWS Management Console).
If you want to do a quick test you can try doing an SSH Tunnel from the Jasper machine to the Mongo Machine. See an example here: https://support.cloud.engineyard.com/entries/21009887-Access-Your-Databa...