Confluence AWS Add/Remove Nodes

View Cluster from within Confluence

Adminstration (Cog) - General Configuration (Dropdown) - ADMINISTRATION (Left) - Clustering (Left)

Add/Remove nodes via AWS Console

Login and navigate to the CloudFormation Stacks page.

  • Select the Stack you used to deploy Confluence.
  • Click the Update button.
  • On the Select Template page, leave Use current template selected and click Next.
  • On the Specify Details page, in the Cluster Node section of Parameters update the Minimum number of cluster nodes and the Maximum number of cluster nodes. If you set Minimum to 2 and Maximum to 2 this will cause the creation of a second Jira node in the other AZ to the first node. This may take some time. Wait for the operation to complete before continuing.
  • Check the Cluster from within Confluence (see above). You should see that the nodes now form a cluster.

Add/Remove nodes via AWS CLI

aws cloudformation describe-stacks --output yaml | grep StackName
To help identify your stack name if you don't remember it
mystack=mystackname
ClusterNodeMin=2
ClusterNodeMax=2
Set variables
aws cloudformation describe-stacks --stack-name ${mystack}
Parameter list was correct on 13-Jul-2020; newer versions of the Quick Start may affect the parameter list
aws cloudformation update-stack --stack-name ${mystack} \
   --use-previous-template --capabilities CAPABILITY_NAMED_IAM --parameters \
   ParameterKey=ClusterNodeMin,ParameterValue=${ClusterNodeMin} \
   ParameterKey=ClusterNodeMax,ParameterValue=${ClusterNodeMax} \
   ParameterKey=CollaborativeEditingMode,UsePreviousValue=true \
   ParameterKey=ConfluenceVersion,UsePreviousValue=true \
   ParameterKey=CloudWatchIntegration,UsePreviousValue=true \
   ParameterKey=ClusterNodeInstanceType,UsePreviousValue=true \
   ParameterKey=ClusterNodeVolumeSize,UsePreviousValue=true \
   ParameterKey=SynchronyClusterNodeMax,UsePreviousValue=true \
   ParameterKey=SynchronyClusterNodeMin,UsePreviousValue=true \
   ParameterKey=SynchronyNodeInstanceType,UsePreviousValue=true \
   ParameterKey=DeploymentAutomationRepository,UsePreviousValue=true \
   ParameterKey=DeploymentAutomationBranch,UsePreviousValue=true \
   ParameterKey=DeploymentAutomationPlaybook,UsePreviousValue=true \
   ParameterKey=DeploymentAutomationCustomParams,UsePreviousValue=true \
   ParameterKey=DeploymentAutomationKeyName,UsePreviousValue=true \
   ParameterKey=DBEngine,UsePreviousValue=true \
   ParameterKey=DBInstanceClass,UsePreviousValue=true \
   ParameterKey=DBIops,UsePreviousValue=true \
   ParameterKey=DBMasterUserPassword,UsePreviousValue=true \
   ParameterKey=DBMultiAZ,UsePreviousValue=true \
   ParameterKey=DBPassword,UsePreviousValue=true \
   ParameterKey=DBStorage,UsePreviousValue=true \
   ParameterKey=DBStorageEncrypted,UsePreviousValue=true \
   ParameterKey=DBStorageType,UsePreviousValue=true \
   ParameterKey=BastionHostRequired,UsePreviousValue=true \
   ParameterKey=KeyPairName,UsePreviousValue=true \
   ParameterKey=CidrBlock,UsePreviousValue=true \
   ParameterKey=InternetFacingLoadBalancer,UsePreviousValue=true \
   ParameterKey=SSLCertificateARN,UsePreviousValue=true \
   ParameterKey=CustomDnsName,UsePreviousValue=true \
   ParameterKey=HostedZone,UsePreviousValue=true \
   ParameterKey=AutologinCookieAge,UsePreviousValue=true \
   ParameterKey=TomcatContextPath,UsePreviousValue=true \
   ParameterKey=CatalinaOpts,UsePreviousValue=true \
   ParameterKey=JvmHeapOverride,UsePreviousValue=true \
   ParameterKey=JvmHeapOverrideSynchrony,UsePreviousValue=true \
   ParameterKey=DBPoolMaxSize,UsePreviousValue=true \
   ParameterKey=DBPoolMinSize,UsePreviousValue=true \
   ParameterKey=DBTimeout,UsePreviousValue=true \
   ParameterKey=DBIdleTestPeriod,UsePreviousValue=true \
   ParameterKey=DBMaxStatements,UsePreviousValue=true \
   ParameterKey=DBValidate,UsePreviousValue=true \
   ParameterKey=DBPreferredTestQuery,UsePreviousValue=true \
   ParameterKey=DBAcquireIncrement,UsePreviousValue=true \
   ParameterKey=MailEnabled,UsePreviousValue=true \
   ParameterKey=TomcatAcceptCount,UsePreviousValue=true \
   ParameterKey=TomcatConnectionTimeout,UsePreviousValue=true \
   ParameterKey=TomcatDefaultConnectorPort,UsePreviousValue=true \
   ParameterKey=TomcatEnableLookups,UsePreviousValue=true \
   ParameterKey=TomcatMaxThreads,UsePreviousValue=true \
   ParameterKey=TomcatMinSpareThreads,UsePreviousValue=true \
   ParameterKey=TomcatProtocol,UsePreviousValue=true \
   ParameterKey=TomcatRedirectPort,UsePreviousValue=true \
   ParameterKey=QSS3BucketName,UsePreviousValue=true \
   ParameterKey=QSS3KeyPrefix,UsePreviousValue=true \
   ParameterKey=ExportPrefix,UsePreviousValue=true
  • Wait for new node to be provisioned.
aws cloudformation list-stacks --output yaml --stack-status-filter "UPDATE_IN_PROGRESS" "UPDATE_ROLLBACK_FAILED" "UPDATE_ROLLBACK_IN_PROGRESS" "UPDATE_COMPLETE_CLEANUP_IN_PROGRESS" | grep -E 'StackName|StackStatus'
  • The command above will show UPDATE_IN_PROGRESS whilst the change is being applied. When the command above returns no results use the command below to view the Confluence Nodes...
for iid in $(aws ec2 describe-instance-status --output yaml | grep InstanceId | tr -d ' ' | awk -F: '{ print $2 }')
do
aws ec2 describe-instances --instance-ids ${iid} --output yaml | grep "Confluence Node" >/dev/null && \
aws ec2 describe-instances --instance-ids ${iid} --output yaml | egrep "InstanceId| Code:| Name:"
done 
  • Check the Cluster nodes section of the Jira System Info page. You should see that the nodes now form a cluster.