Installing Confluence Data Center
In this guide we'll run you through installing Confluence Data Center, which is a clustered solution, in a Windows or Linux Environment.
This guide covers installing for the first time, with no existing data. If you already have a Confluence Server instance, see Moving to Confluence Data Center.
Other ways to install Confluence Data Center:
On this page:
Clustering requirements and terminology
To run Confluence in a cluster you must:
- Have a Data Center license (you can purchase a Data Center license or create an evaluation license at my.atlassian.com)
- Use a supported external database, operating system and Java version
- Use a load balancer with session affinity and WebSockets support in front of the cluster
- Have a shared directory accessible to all cluster nodes in the same path (this will be your shared home directory)
- Use OAuth authentication if you have application links to other Atlassian products (such as JIRA)
In this guide we'll use the following terminology:
- Installation directory – The directory where you installed Confluence on a node.
- Local home directory – The home or data directory on each node (in non-clustered Confluence this is simply known as the home directory).
- Shared home directory – The directory you created that is accessible to all nodes in the cluster via the same path.
- Synchrony directory - The directory where you downloaded Synchrony (this can be on a confluence node, or on its own node)
At the end of the installation process, you'll have an installation and local home directory on each node, and a single shared home directory (a total of 5 directories in a two node cluster) for Confluence plus directories for Synchrony.
1. Install Confluence on the first node
- Install Confluence on node 1
See Installing Confluence on Windows from Zip File or Installing Confluence on Linux from Archive File for more information.
- Start Confluence on Node 1
- Complete the setup wizard by entering:
- Your cluster license
- A name for your cluster
- The path to the shared home directory you created earlier
- The network interface Confluence will use to communicate between nodes
- A multicast address (automatically generated or enter your own) or the IP addresses of each cluster node
- Stop Confluence on Node 1
2. Set up Synchrony
Collaborative editing requires Synchrony, which runs as a separate process. You can deploy Synchrony on the same nodes as Confluence, or in its own cluster with as many nodes as you need. You'll need to complete step one (including entering your Data Center license) before you start this step.
In this example, we assume you'll run Synchrony in its own cluster. When configuring your cluster nodes you can either supply the IP address of each Synchrony cluster node, or a multicast address.
- Create a Synchrony directory on your first node and copy
synchrony-standalone.jarfrom your Confluence
<home-directory> to this directory.
- Copy your database driver from your Confluence
<install-directory>/confluence/web-inf/libto an appropriate location on your Synchrony node.
Change to your Synchrony directory and start Synchrony using the following command.
You need to pass all of the system properties listed, replacing the values where indicated.Start Synchrony command...
In a terminal / command prompt, execute the following command, replacing
<values>with appropriate values for your environment. Scroll down for more information on each of the values you will need to replace.
Remember to remove all commented lines completley before you execute this command, and replace all new lines with white space. You may also need to change the name of the
synchrony-standalone.jarif the file you copied is different to our example.
Here's more information about each of the values you'll need to supply in the command above.
This is the HTTP port that Synchrony runs on. We suggest port 8091, if available.
This is Synchrony's Hazelcast port. We suggest port 5701, if available. As with Confluence's Hazelcast port (5801) you should ensure that only permitted cluster nodes are allowed to connect to this port, through the use of a firewall and or network segregation.
This is the Aleph binding port. Synchrony uses Aleph to communicate between nodes. We suggest port 25500, if available.
If you choose to discover nodes using TCP/IP, provide a comma separated list of IP addresses for each cluster node.
If you chose to discover nodes using multicast, specify an IP address for the multicast group.
This is the public IP address or hostname of this Synchrony node.
This is the URL that the browser uses to contact Synchrony. Generally this will be the URL for your load balancer plus the Synchrony context path, for example
This is the URL that the browser uses to contact Synchrony. This will be the URL URL for your load balancer, for example
These keys are generated by Confluence. Copy each key from the
<local-home>/confluence.cfg.xmlfile on your first Confluence node. The keys must be the same on all Confluence and Synchrony nodes.
This is the URL for your Confluence database. For example
jdbc:postgresql://localhost:5432/confluence. You can find this URL in
The username and password for your Confluence database user.
This is the path to the
synchrony_standalone.jarthat you copied in step 1. For example
This is the path to your database driver. For example
This is the full URL of the load balancer Synchrony will run behind, for example,
http://<lb_host>:<lb_port><lb_context_path>. For example, if your loadbalancer path is
synchrony, then it will be
. Notice that it does not end with
/v1, unlike the
synchrony.service.urlsystem property passed to Confluence. If this URL doesn't match the URL coming from a users' browser, Synchrony will fail.
Sensitive information (like database credentials) may be provided using environmental variables, rather than via the command line. Any dots (".") in variable names (identifiers) will need to be replaced with underscores ("_").
A few other properties can be modified to suit your environment. See Configuring Synchrony for Data Center for more information.
- To check that Synchrony is accessible, go to:
Repeat this process to start Synchrony on each node of your Synchrony cluster.
As each node joins you'll see something like this in your console.
- Configure your load balancer for Synchrony.
Your load balancer must support WebSockets (for example NGINX 1.3 or later, Apache httpd 2.4, IIS 8.0 or later) and session affinity. SSL connections must be terminated at your load balancer so that Synchrony can accept XHR requests from the web browser.
3. Start Confluence on Node 1
Start Confluence on node 1 and pass the following system property to tell Confluence where to find your Synchrony cluster.
You may want to add this system property to your
setenv.batso it is automatically passed every time you start Confluence. See Configuring System Properties for more information on how to do this in your environment.
- Head to > General Configuration > Collaborative editing to check that this Confluence node can connect to Synchrony.
Note: to test creating content you'll need to access Confluence via your load balancer. You can't create or edit pages when accessing a node directly.
4. Copy Confluence to second node
To copy Confluence to the second node:
- Shut down Confluence on node 1
- Shut down your application server on node 2, or stop it automatically loading web applications
- Copy the installation directory from node 1 to node 2
- Copy the local home directory from node 1 to node 2
If the file path of the local home directory is not the same on nodes 1 and 2 you'll need to update the
<installation directory>/confluence/WEB-INF/classes/confluence-init.propertiesfile on node 2 to point to the correct location.
Copying the local home directory ensures the Confluence search index, the database and cluster configuration, and any other settings are copied to node 2.
5. Configure load balancer
Configure your load balancer for Confluence. You can use the load balancer of your choice, but it needs to support session affinity and WebSockets.
SSL connections must be terminated at your load balancer so that Synchrony can accept XHR requests from the web browser.
You can verify that your load balancer is sending requests correctly to your existing Confluence server by accessing Confluence through the load balancer and creating a page, then checking that this page can be viewed/edited by another machine through the load balancer.
6. Start Confluence on the first node, wait, then start Confluence on second node
You must only start Confluence one server at a time.
- Start Confluence on node 1
- Wait for Confluence to become available on node 1
- Start Confluence on node 2
- Wait for Confluence to become available on node 2.
The Cluster monitoring console ( > General Configuration > Clustering) includes information about the active cluster.
When the cluster is running properly, this page displays the details of each node, including system usage and uptime. Use the menu to see more information about each node in the cluster.
Screenshot: Cluster monitoring console
7. Test your Confluence cluster
Remember, to test creating content you'll need to access Confluence via your load balancer. You can't create or edit pages when accessing a node directly.
A simple process to ensure your cluster is working correctly is:
- Access a node via your load balancer, and create a new document on this node
- Ensure the new document is visible by accessing it directly on a different node
- Search for the new document on the original node, and ensure it appears
- Search for the new document on another node, and ensure it appears
Ensure that only permitted cluster nodes are allowed to connect to a Confluence Data Center instance's Hazelcast port (which defaults to 5801) or Synchrony's Hazelcast port (which defaults to 5701) through the use of a firewall and or network segregation.
If you have problems with the above procedure, please see our Cluster Troubleshooting guide.
If you're testing Confluence Data Center by running the cluster on a single machine, please refer to our developer instructions on Starting a Confluence cluster on a single machine.
Upgrading a cluster
It's important that upgrades follow the procedure for Upgrading Confluence Data Center.
Was this helpful?
Thanks for your feedback!