Confluence Cluster setup
Asked by JDave:

I am attempting to startup a new Confluence cluster - between two Linux boxes - everything was copied as directed, the first node comes up with no issues. I have tried multicast - did not work. I have changed the confluence.cfg.xml from multicast to tcp_ip based on an article that I found - now I am getting the error:

2019-01-28 08:41:02,170 INFO \[localhost-startStop-1\] \[atlassian.confluence.cluster.DefaultClusterConfigurationHelper\] lambda$populateExistingClusterSetupConfig$5 Populating setup configuration if running with Cluster mode...

2019-01-28 08:41:02,281 INFO \[localhost-startStop-1\] \[confluence.cluster.hazelcast.HazelcastClusterManager\] configure Configuring Hazelcast with instanceName \[confluence\], join configuration TCP/IP member addresses: 10.224.5.2\|10.224.4.233, network interfaces \[10.224.4.233\] and local port 5801

2019-01-28 08:41:02,282 INFO \[localhost-startStop-1\] \[confluence.cluster.hazelcast.HazelcastClusterManager\] startCluster Starting the cluster.

2019-01-28 08:41:04,185 WARN \[hz.confluence.priority-generic-operation.thread-0\] \[com.hazelcast.cluster\] log \[10.224.4.233\]:5801 \[dkdl2151\] \[3.8.6\] Node could not join cluster at node: \[10.224.5.2\]:5801 Cause: the target cluster has a different group-name

2019-01-28 08:41:04,189 WARN \[hz.confluence.generic-operation.thread-1\] \[com.hazelcast.cluster\] log \[10.224.4.233\]:5801 \[dkdl2151\] \[3.8.6\] Node could not join cluster at node: \[10.224.5.2\]:5801 Cause: the target cluster has a different group-name

2019-01-28 08:41:05,205 INFO \[localhost-startStop-1\] \[confluence.cluster.hazelcast.HazelcastClusterManager\] startCluster Confluence cluster node identifier is \[5120b2a1\]

This is from the log file on the second node - after I attempt to start it.

On the web page for access ..

\[Origin node: 5120b5a8 listening on /10.224.5.2:5801\] Clustered Confluence: Database is being updated by an instance which is not part of the current cluster. You should check network connections between cluster nodes, especially multicast traffic

This error is the same as when I had it on multicast ...

I don't know .. what .. I am missing


Answers:
author: Nic Brough -Adaptavist-
body: I think there are two errors combined here, the second caused by the first.

You're starting up a Confluence node fine, and that is running ok. Then you start the second one which throws errors "could not join cluster".

You then get the error about the database lock because node-1 has locked it, but node-2 is now trying to get a lock on the database without being part of the same cluster as node-1

Short answer is that you need to get both nodes using the same group name for their cluster. Have a look at <https://confluence.atlassian.com/doc/moving-to-confluence-data-center-203651.html> and the cluster's group settings (I think it might be in confluence/WEB-INF/classes/confluence-init.properties)


author: yang lei
body: May I ask how did you get the shared directory between two or three Linux boxes?

comments: author: JDave
body: NFS mounted directory


author: JDave
body: Thank you for the suggestion - I was able to resolve the issue - between the two servers that I was attempting to add to the cluster - I had the hostname for each of the servers in the confluence.cfg.xml file - instead of one common name - for example - I added StagingCON_Cluster on both servers - and the second node started.

\<property name="confluence.cluster.name"\>StagingCON_Cluster\</property\>

comments: author: Mark Naumowicz
body: Dave, can you post the entries you have changed/added in these two files (confluence-init.properties and confluence.cfg.xml) I struggle to find a working example of the cluster config. I have shared dir and cluster name but still getting cluster panic. Your help is appreciated.


author: JDave
body: The confluence.cfg.xml - the items in bold have been updated - just for privacy - :) One of the issues I had, could not get it to run via multicast as it should have started - the second host has the same conflunce.cfg.xml.

<br />

\<?xml version="1.0" encoding="UTF-8"?\>

\<confluence-configuration\>  
\<setupStep\>complete\</setupStep\>  
\<setupType\>cluster\</setupType\>  
\<buildNumber\>7901\</buildNumber\>  
\<properties\>  
\<property name="access.mode"\>READ_WRITE\</property\>  
\<property name="admin.ui.allow.daily.backup.custom.location"\>false\</property\>  
\<property name="admin.ui.allow.manual.backup.download"\>false\</property\>  
\<property name="admin.ui.allow.site.support.email"\>false\</property\>  
\<property name="atlassian.license.message"\>AAABVQ0ODAoPeNp1kV9LwzAUxd/zKQI+qGBG/2zTDQq6tsxCu4qdDsGXLLudwTYtSVrctzdtHVPRt +Teyzm/e+7ZugGcUIltB9vW3Lqejy3sB2vsWPYM+ZXQlOkVLcHb0RZGeVWUVN7umNqPWFUiVol8Z CZ4C56WDaCHRrI3qiCgGrxOg1gusV0UcwZCQfhRc3n41hwT2znahAnlxd8+GcgWZBR4i9lyQ8KX+ wnZLNKMBOHYGSCMJvVBaJADSNZsFZO81rwSQ8Wom7aggv2D0eusmnILMs2fFEjlEXuoZprKTjqnh YLjMgYnjoIsXJHYdp3JdHrjIvPzflZSuaeCK9qDBJy9nyuc1ZXUXOzxsqp26gpHgo2QL6Ef+h1dD /BluT7U0F/DT5MkfPSjuxgVQ+vZ8HYWDgrgtLmJNi8aMDvjiy4iPGR0+TrHYUuLpndEp+cQ1SfyG bAgMC4CFQCXJa5gAb0/XXXXXXXXa6T+s72KokAyvLBZ9lGZ4BX02gs\</property\>  
\<property name="attachments.dir"\>${confluenceHome}/attachments\</property\>  
\<property name="confluence.cluster"\>true\</property\>  
\<property name="confluence.cluster.address"\>224.2.2.3\</property\>  
\<property name="confluence.cluster.home"\>/shared-home\</property\>  
\<property name="confluence.cluster.interface"\>eth2\</property\>  
\<property name="confluence.cluster.join.type"\>tcp_ip\</property\>  
\<property name="confluence.cluster.name"\>**NAME(just a name)** \</property\>  
\<property name="confluence.cluster.peers"\>10.224..**X.XX (host one)** ,10.224.**X.XX (second host)** \</property\>  
\<property name="confluence.cluster.ttl"\>1\</property\>  
\<property name="confluence.setup.server.id"\>**B9GW-XXX-XXXX-DE42** \</property\>  
\<property name="confluence.webapp.context.path"\>\</property\>  
\<property name="hibernate.c3p0.acquire_increment"\>1\</property\>  
\<property name="hibernate.c3p0.idle_test_period"\>100\</property\>  
\<property name="hibernate.c3p0.max_size"\>60\</property\>  
\<property name="hibernate.c3p0.max_statements"\>0\</property\>  
\<property name="hibernate.c3p0.min_size"\>20\</property\>  
\<property name="hibernate.c3p0.timeout"\>30\</property\>  
\<property name="hibernate.connection.driver_class"\>com.mysql.jdbc.Driver\</property\>  
\<property name="hibernate.connection.isolation"\>2\</property\>  
\<property name="hibernate.connection.password"\>**XXXXXXXX** \</property\>  
\<property name="hibernate.connection.url"\>jdbc:mysql://**10.X.X.X** :3308/confluence\</property\>  
\<property name="hibernate.connection.username"\>confluenceuser\</property\>  
\<property name="hibernate.database.lower_non_ascii_supported"\>true\</property\>  
\<property name="hibernate.dialect"\>com.atlassian.confluence.impl.hibernate.dialect.MySQLDialect\</property\>  
\<property name="hibernate.schema_management_tool"\>com.atlassian.confluence.impl.hibernate.ConfluenceHibernateSchemaManagementTool\</property\>  
\<property name="hibernate.setup"\>true\</property\>  
\<property name="jwt.private.key"\>MIICeAIBADANBgkqhkiG9w0BAQEFAASCAmIwggJeAgEAAoGBAKDzMzrmDO7PI0hbKLIE0b4tcHYp4BX5bWqXGE6+Z4CMny+otUYotJT0/NXHDcKTc+Ng7AHRNGBNtr9ulE5l3QhsuVFw+7gs6eqCNH9Fywit3hvoiJw1mij3ExSxjMeVvcW+ipc0biPn2yOdDl+57yil6oc1Z9xvxL87dEhCQFmrAgMBAAECgYEAmQUfm8vEV/ePb+dbVYTHdKv21CET71Bo+oIUlijodos7fTBEyCNDLKuPBiBtsKRH9dHcEA46YaUBLheP4MlvzlxYeJ3XXXXXXXXXXa62DHFrn7ybHUjunwtjpfWPphgAZXMQsFINp6HuECQQD54RnJQVoe1+urgq9hbCjC87F3+mHSdCVvrLTcbCZac7+GYhsnVxUgEfRyxfYu4r6G2akr3HQKYpwKCAkAVkXPAkEApOR1B0zWnVor5uWrxGjotAmPoMWxuTphaBoNMPoMNam/ZuR10t51m0mSX5606vpm0mBIDI7ua4AM/1aJpD8BZQJBAJVzQXXyZVE/OQ/6eKSfCP4YvJMSqMEzgFR7iiyvbnz475sTQERWPCdTNc4TgntmWCfVNO4ryyeO9N63EZMnBlcCQQCbm7lRLVMvZYQev0ls7jAEjy1K5KYGjjCURFmEicRx9AJbwGfsmuFTrYeD00saoTndeN0ldNFNA6fAY1M7e/X9AkBy6lcyM4FWam0/41DSDvPK0o80K+nS48jy7HB1RcDrpFsqfYeLmDmLPX+1nWq3jL9vIBxE6Yui1/Iqaq54s7iS\</property\>  
\<property name="jwt.public.key"\>MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCg8zM65gzuzyNIWyiyBNXXXXXXXXZoo9xMUsYzHlb3FvoqXNG4j59sjnQ5fue8opeqHNWfcb8S/O3RIQkBZqwIDAQAB\</property\>  
\<property name="lucene.index.dir"\>${localHome}/index\</property\>  
\<property name="synchrony.btf"\>true\</property\>  
\<property name="synchrony.btf.off"\>true\</property\>  
\<property name="synchrony.encryption.disabled"\>true\</property\>  
\<property name="synchrony.host"\>**Currenthost.dXXX.com** \</property\>  
\<property name="synchrony.proxy.enabled"\>true\</property\>  
\<property name="webwork.multipart.saveDir"\>${localHome}/temp\</property\>  
\</properties\>  
\</confluence-configuration\>

The confluence-init.properties file is below:

<br />

# This file allows you to set the directory for Confluence to store its configuration files.  
#  
###########################  
# Note for Windows Users #  
###########################  
#  
# Each backslash in your path must be written as a forward slash.  
# - For example:  
# c:\\confluence\\data  
#  
# should be written as:  
#  
# c:/confluence/data

###########################  
# Note for Unix Users #  
###########################  
# - For example:  
# confluence.home=/var/confluence  
#  
# NOTE: If the path of your confluence.home directory contains symlinks,  
# please set confluence.home to the absolute path, otherwise problems may occur.  
# - For example:  
# confluence.home=/data/confluence/ (where /data is a symlink to -\> /var/data/)  
# should be written as:  
# confluence.home=/var/data/confluence/

###########################  
# Configuration Directory #  
###########################

# specify your directory below (don't forget to remove the '#' in front)

confluence.home = /app/opt/atlassian/application-data


author: secondary world
body: could node 1 and node 2 use the same server id in conflunce.cfg.xml of two node of this line \<property name="confluence.setup.server.id"\>**B9GW-XXX-XXXX-DE42** \</property\>


author: Dave
body: Yes


author: C. Faysal
body: Hi

afaik this line is obsolete

\<property name="confluence.cluster.address"\>224.2.2.3\</property\>

since you use

\<property name="confluence.cluster.join.type"\>tcp_ip\</property\>

regards


Tags: confluence-server

server