can we mix silent config and non ms installations?

Not applicable

I am working on yet another project that requires me to update my deployment automation logic. I now have a DC that does not have a management server in it.

I want to still utilize the silent installation files during the installation - but im not sure i can because of the requirement to use the apigee-register-non-ms-dc.sh script in my installation now.

Is there a recommended way around this problem so I can still use silent installation file?

Solved Solved
0 1 146
1 ACCEPTED SOLUTION

The out of the box apigee-register-non-ms-dc.sh script doesn't have the option to run in unattended mode. There are a easy options here:

1) Alter the script so that it defaults to using export environment variables if the user runs it non-interactively. I would recommend generating a patch file which can be applied to the script prior to executing it.

2) Perform the equivalent work via direct management API calls. This would involve creating any datastore registrations that do not yet exist for the central, analytics and gateway pods. For instance, to create a new gateway datastore registration pointing at an appropriate Cassandra host for a region:

> curl -u $creds http://<msip>:8080/v1/servers -X POST -d 'region=<region>&pod=<pod>&InternalIP=<address>&type=<roles>'

To see the roles you would need to add for a particular pod, run this command in a region that already has a management server:

> curl -u $creds http://<msip>:8080/v1/servers?pod=<pod>;

For instance, for the gateway pod you will see entries similar to this one:

"type" : [ "dc-datastore", "cache-datastore", "keyvaluemap-datastore", "kms-datastore", "counter-datastore" ],

So the curl command to add those to a new region such as dc-2 would be:

> curl -u $creds http://<msip>:8080/v1/servers -X POST -d 'region=dc-2&pod=gateway&InternalIP=<address>&type=dc-datastore&type=cache-datastore&type=keyvaluemap-datastore&type=kms-datastore&type=counter-datastore'

View solution in original post

1 REPLY 1

The out of the box apigee-register-non-ms-dc.sh script doesn't have the option to run in unattended mode. There are a easy options here:

1) Alter the script so that it defaults to using export environment variables if the user runs it non-interactively. I would recommend generating a patch file which can be applied to the script prior to executing it.

2) Perform the equivalent work via direct management API calls. This would involve creating any datastore registrations that do not yet exist for the central, analytics and gateway pods. For instance, to create a new gateway datastore registration pointing at an appropriate Cassandra host for a region:

> curl -u $creds http://<msip>:8080/v1/servers -X POST -d 'region=<region>&pod=<pod>&InternalIP=<address>&type=<roles>'

To see the roles you would need to add for a particular pod, run this command in a region that already has a management server:

> curl -u $creds http://<msip>:8080/v1/servers?pod=<pod>;

For instance, for the gateway pod you will see entries similar to this one:

"type" : [ "dc-datastore", "cache-datastore", "keyvaluemap-datastore", "kms-datastore", "counter-datastore" ],

So the curl command to add those to a new region such as dc-2 would be:

> curl -u $creds http://<msip>:8080/v1/servers -X POST -d 'region=dc-2&pod=gateway&InternalIP=<address>&type=dc-datastore&type=cache-datastore&type=keyvaluemap-datastore&type=kms-datastore&type=counter-datastore'