Cloudformation ZEND_CLUSTER_NAME

General discussion forum for the Zend Server

Cloudformation ZEND_CLUSTER_NAME

Postby terr3089 on Tue Jan 24, 2017 4:30 pm

Hi I have successfully deployed Zend server using the standard AWS cloudformation template. In there there is a variable passed to Zend "ZEND_CLUSTER_NAME"

"ZEND_CLUSTER_NAME": {"Ref": "AWS::StackName"}

This is fine as both the Cluster manager and the Launchconfig of the Autoscaling group are build from the same Stack.

However I am in the situation where the Cluster manager and the Autoscaling group are produced by different Stacks. (I know, it's not my call. :-)

What I need to know is what the "ZEND_CLUSTER_NAME" should be set to in each of the templates.

I'm guessing in the Cluster Manager template that "ZEND_CLUSTER_NAME" will be the name of the Cluster Manager Template itself.

But in the Launchconfig section of the AutoscalingGroup template should "ZEND_CLUSTER_NAME": be set to the name of the AutoscalingGroup stack or the name of the Cluster Manager stack. I'm guessing it is the latter but not sure how to prove it.

"ZEND_CLUSTER_NAME" is used in the ec-bootstrap script:
/usr/bin/cfn-init -v \
--stack ${stackName} \
--resource ${CMInstance} \
--configsets InstallAndRun \
--region ${region}
/usr/bin/cfn-signal -e $? \
--stack ${stackName} \
--resource ${CMInstance} \
--region ${region}

(I have had to specify the ${CMInstance} separately but that is looking ok for now)

terry
terr3089
 
Posts: 13
Joined: Tue Sep 22, 2015 10:05 am

Re: Cloudformation ZEND_CLUSTER_NAME

Postby terr3089 on Tue Jan 24, 2017 4:35 pm

Duh! Just re-read this. It's pretty obvious. It's looking for the CMInstance as a resource in the Cluster Manager Stack.

Sorry if I woke anyone up unnecessarily

Terry
terr3089
 
Posts: 13
Joined: Tue Sep 22, 2015 10:05 am

Re: Cloudformation ZEND_CLUSTER_NAME

Postby dima_z_zend on Wed Jan 25, 2017 8:57 am

Hi Terry,

Could you tell me which Zend Server version we talk about here and which CloudFormation template? There are 2 sources for CloudFormation template:
1. There is a CloudFormation template generator on our website - http://www.zend.com/en/products/server/cloudformation
2. AWS Marketplace has CloudFormation template for each of our products
It would also be easier if you could post CloudFormation template here or send it by email to dima.z@zend.com

P.S. If you use latest version of Zend Server 8.5 or 9.0, ZEND_CLUSTER_NAME is probably unused and can be safely ignored, it will be removed when next minor version of Zend Server is released.
Dmitry Zbarski
Cloud Integration Engineer
Zend Technologies, Ltd.
dima_z_zend
 
Posts: 14
Joined: Sun Jul 17, 2011 3:17 pm
Location: Ramat Gan, Israel

Re: Cloudformation ZEND_CLUSTER_NAME

Postby terr3089 on Thu Jan 26, 2017 11:04 am

Thanks for the reply

It is Zend Server 8.5 running on RHEL 7.2.

The template I normally use is the one on AWS marketplace that is specified for that AMI. From there we have customised it to our needs and it works fine.

The ConfigSets are associated with the Cluster Master instance and we use ZEND_SCRIPT_URL and ZEND_SCRIPT_PATH to specify a script to execute our customised ConfigSet.

The issue I now have is that we are trying to outsource our installation and the company process is to have a separate template for each entity. So there is an Autoscaling group template and a Cluster Master template. Our script running on the Autoscaling group instances does not have access to the resources in the Cluster Master template since they are not a member of template.

I have a workaround which is to duplicate the Metadata from the Cluster Master definition into the Launchconfig of the Autoscalingroup template. Not ideal but as long as we are careful with changes it should be fine.

terry
terr3089
 
Posts: 13
Joined: Tue Sep 22, 2015 10:05 am


Return to Zend Server

Who is online

Users browsing this forum: No registered users and 2 guests