AWS Ubuntu port 8090 refused to connect
Asked by James Johnston:

Hi guys

I have just installed Confluence on an AWS Instance:

Ubuntu

Gone through the steps and Confluence is running, however I can't access:

on http://...amazonaws.com:8090

Get the message refused to connect.

Can open up tomcat on 8080

Have tried:

- Ensuring port 8090 is open on AWS settings and on Ubuntu firewall.

- turning off Ubuntu firewall

- uninstalling / reinstalling confluence

- configuring Confluence to use another port: 8099

- uninstalling / reinstalling tomcat

- through putty, opening up firefox on the AWS instance and going to http://localhost:8090 and http://localhost:8099

No luck.

Any pointers?

================

ubuntu@:\~$ sudo /etc/init.d/confluence restartexecuting using dedicated userIf you encounter issues starting up Confluence, please see the Installation guide at [http://confluence.atlassian.com/display/DOC/Confluence+Installation+Guide Server](http://confluence.atlassian.com/display/DOC/Confluence+Installation+Guide?Server) startup logs are located in /opt/atlassian/confluence/logs/catalina.out---------------------------------------------------------------------------Using Java: /opt/atlassian/confluence/jre//bin/java2017-07-08 16:07:21,966 INFO \[main\] \[atlassian.confluence.bootstrap.SynchronyProxyWatchdog\] A Context element for ${confluence.context.path}/synchrony-proxy is found in /opt/atlassian/confluence/conf/server.xml. No further action is required---------------------------------------------------------------------------Using CATALINA_BASE: /opt/atlassian/confluenceUsing CATALINA_HOME: /opt/atlassian/confluenceUsing CATALINA_TMPDIR: /opt/atlassian/confluence/tempUsing JRE_HOME: /opt/atlassian/confluence/jre/Using CLASSPATH: /opt/atlassian/confluence/bin/bootstrap.jar:/opt/atlassian/confluence/bin/tomcat-juli.jarUsing CATALINA_PID: /opt/atlassian/confluence/work/catalina.pidPID file found but no matching process was found. Stop aborted. To run Confluence in the foreground, start the server with start-confluence.sh -fgexecuting using dedicated user: confluenceIf you encounter issues starting up Confluence, please see the Installation guide at [http://confluence.atlassian.com/display/DOC/Confluence+Installation+Guide Server](http://confluence.atlassian.com/display/DOC/Confluence+Installation+Guide?Server) startup logs are located in /opt/atlassian/confluence/logs/catalina.out---------------------------------------------------------------------------Using Java: /opt/atlassian/confluence/jre//bin/java2017-07-08 16:07:22,354 INFO \[main\] \[atlassian.confluence.bootstrap.SynchronyProxyWatchdog\] A Context element for ${confluence.context.path}/synchrony-proxy is found in /opt/atlassian/confluence/conf/server.xml. No further action is required---------------------------------------------------------------------------Using CATALINA_BASE: /opt/atlassian/confluenceUsing CATALINA_HOME: /opt/atlassian/confluenceUsing CATALINA_TMPDIR: /opt/atlassian/confluence/tempUsing JRE_HOME: /opt/atlassian/confluence/jre/Using CLASSPATH: /opt/atlassian/confluence/bin/bootstrap.jar:/opt/atlassian/confluence/bin/tomcat-juli.jarUsing CATALINA_PID: /opt/atlassian/confluence/work/catalina.pidExisting PID file found during start.Removing/clearing stale PID file.Tomcat started.


Answers:
author: Justin W_
body: Hi James,

First, ensure that it's not a DNS problem by trying http://ipaddress:port instead. You should also curl the same from the instance itself as well as from a remote computer such as your laptop. If it doesn't work locally, then the process may not be running - execute the process using start-confluence.sh instead of the service you have setup. If the process responds locally, move on to troubleshoot with the items below.

For example:

# locally  
curl -vvv http://localhost:8090

# remotely  
curl -vvv http://ipaddress:8090

If the EC2 instance itself is not configured to block traffic, but traffic is still blocked, then you need to look at your [security group(s)](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-network-security.html#updating-security-group-rules) attached to the instance, as well as the [Network ACL's](https://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_ACLs.html).

Best Regards,

Justin

comments: author: Veera Marni
body: Not helpful, everything looks fine according to the documentation but still not working. If possible try to install on your end on an aws machine which runs on ubuntu 16.04 and please look into the issue


author: FreeSoftwareServers
body: What type of instance are you using?, I haven't had a chance to test but I think my issue was that I was using to small a server.

Confluence wasn't throwing any errors but I think it needs more RAM then t2.micro (1GB). I noticed deploy4me used t2.medium and that was the next thing for me to try.


author: AnnWorley
body: That makes sense - Confluence needs 1GB Java heap memory for Synchrony and another gig of heap for Confluence itself. Please see [Minimum hardware requirements](https://confluence.atlassian.com/doc/server-hardware-requirements-guide-30736403.html#ServerHardwareRequirementsGuide-Minimumhardwarerequirements):
> On small instances, server load is primarily driven by peak visitors, so minimum system requirements are difficult to judge. We provide these figures as a guide to the absolute minimum required to run Confluence, and your configuration will likely require better hardware.
>
> Here is our minimum hardware recommendation:
>
> CPU: Quad core 2GHz+ CPU  
> RAM: 6GB  
> Minimum database space: 10GB


author: Nic Brough -Adaptavist-
body: [@Veera Marni](/t5/user/viewprofilepage/user-id/1346255)- we're a community of end users, we're not going to spend ages trying to replicate your system just because you have an issue with it that you are not prepared to look into for yourself. Even if we were support, the correct response was "you need to do the debugging on your system, or if you really can't, provide us with an identical copy".

However, I can tell you that I have access to many systems running Confluence on an AWS instance, and the third one I checked is running Ubuntu 16.04, and Confluence is fine. So the problem is not just AWS/Ubuntu 16.04, the problem is how you are running it.

It's also no good to just say "not helpful". What errors did you get? What do your logs say? What does your firewall log say?

I would absolutely check what [@FreeSoftwareServers](/t5/user/viewprofilepage/user-id/557523) said too - for a basic small Confluence system, you should be allowing at least 512Mb for Confluence and another 512Mb for Synchrony, and the same again for the OS.. You can get it to run in less, but it will be unusable, with timeouts, non-responses and refused connections.


author: James Johnston
body: Have also tried:

Creating a new instance on AWS using AWS Linux. Same issue.

As well as:

- followed these steps: <http://bytesoap.com/2014/confluence-jira-nginx-ubuntu>

Also from <https://confluence.atlassian.com/confkb/running-confluence-with-firewall-on-linux-693896826.html>

iptables -I INPUT -p tcp --dport 8090 -j ACCEPT  
iptables -I FORWARD -p tcp --dport 8090 -j ACCEPT  
iptables -P OUTPUT ACCEPT

With a reboot.

No luck opening with port 8090 or 8099

comments: author: FreeSoftwareServers
body: Please don't add an "Answer" which is really just an update, it makes the question look answered. Which it is not. I also have the same problem... did you ever resolve? Too bad atlassian didn't look into this, seems like a big issue.


author: Nic Brough -Adaptavist-
body: To be fair, there's no other way to add more information, unless it's an edit to the main question, which tends to make it more and more unreadable. This is a reason I was disappointed with the move from Confluence questions (where you could comment or answer) to the more primitive Lithium platform.