How to get Confluence to run on the right port?
Asked by Jessica Torres:

Hi there, I installed Jira Software on my server and got it all configured nicely. Now, I want to install Confluence but it won't use the default ports (HTTP: 8090) because it says that port is in use. After doing some digging, I find that java.exe is using port 8090. I don't know if that was the case before I ever installed Jira but I don't know whether to get java to run on a different port so that Confluence can run on 8090 or whether to just pick a different custom port for Confluence to run on and what that port number should be. Any help would be appreciated.

Thanks in advance.


Answers:
author: Jessica Torres
body: I'm still waiting on an answer to this question. I'm stuck on this issue and can't install.

comments: author: Alexis Robert
body: Hi [@Jessica Torres](/t5/user/viewprofilepage/user-id/1767544),

where exactly are you stuck on, what steps have you taken on the original issue ?


author: Jessica Torres
body: Hi [@Alexis Robert](/t5/user/viewprofilepage/user-id/1213386) Please see my latest reply to Nic above.


author: Alexis Robert
body: OK, so basically you can tell Confluence to run on any port you'd like, by default it is using port 8090 but you can choose 9090 for example.

Changing the default port must be done in the Confluence configuration file as instructed [here](https://confluence.atlassian.com/doc/change-listen-port-for-confluence-165823.html), once you have changed this setting you can restart the installation process and it should not get stuck anymore.

Let me know if it works,

--Alexis


author: Jessica Torres
body: [@Alexis Robert](/t5/user/viewprofilepage/user-id/1213386) Thank you, that's what I needed.


author: Alexis Robert
body: Hi [@Jessica Torres](/t5/user/viewprofilepage/user-id/1767544),

you can easily check on what port your Jira or Confluence is running: simply check you \<installation directory\>/conf/server.xml and look at the top of the file for this:

    <Connector port="XXXX"

This should give you the information you're looking for.

The default port for Jira should be 8080, and 8090 for Confluence.

Let me know if this helps,

--Alexis

comments: author: Jessica Torres
body: No, it does not help, sadly. I have not yet installed Confluence. I'm running the installer and it won't install with the default 8090 port.


author: Alexis Robert
body: Can you check with the process manager that you might not have another instance of the Confluence running ? You might want to maybe restart your server to make sure there is nothing else running too.


author: Jessica Torres
body: How would I have another instance of Confluence running if I've never installed it. I just explained that java is running on port 8090. I'm not sure I understand your question.


author: Nic Brough -Adaptavist-
body: It doesn't have to be Confluence, it's not the only thing that runs on 8090 by default (and the list grows massively when you remember almost anything can be relocated on another port)

Run a command line as the administrator, and then run

netstat -ab

From memory, that will list the open ports and processes. Try the switch -aon instead if my memory is wrong.


author: Jessica Torres
body: Thanks, [@Nic Brough -Adaptavist-](/t5/user/viewprofilepage/user-id/781454) that did list the open ports. So does that mean I can choose whichever one is open when installing Confluence so that it doesn't interfere with java running on port 8090? I apologize if this is a basic question. I really don't know anything about ports.


author: Jessica Torres
body: [@Nic Brough -Adaptavist-](/t5/user/viewprofilepage/user-id/781454) Can you take a minute to reply please?


author: Nic Brough -Adaptavist-
body: Only one process can listen on a port at any time, that's why you're being blocked.

You either need to stop the java process that is currently on port 8090 (the netstat -ab should have told you what that process was and where it's running from) or give Confluence a different port to run on by changing the server.xml


author: Jessica Torres
body: [@Nic Brough -Adaptavist-](/t5/user/viewprofilepage/user-id/781454)Thanks. I don't think I can stop the java process. My question was more geared around how do I know what port to choose? Do I just choose any unused port?


author: Nic Brough -Adaptavist-
body: Yes, any port will do. Just change it to a free one.


author: Jessica Torres
body: [@Nic Brough -Adaptavist-](/t5/user/viewprofilepage/user-id/781454) Thank you, that's what I needed.


Tags: confluence-server

server