Esri / arcgis-cookbook

Chef cookbooks for ArcGIS
Apache License 2.0
290 stars 115 forks source link

Setting admin url of federated servers to webcontext url when in HA #289

Closed anandak closed 3 years ago

anandak commented 3 years ago

Hi @cameronkroeker, we have successfully done a multi machine base enterprise deployment of 10.8.1 in Amazon cloud. All machines are in HA, i.e., web adaptor, portal, server and data store. This is fronted by the Amazon's load balancer which we are using as the web_context_url. However we see that during federation, the web_context_url is used only for the services URL while the administration URL is set to the private_url (6443). According to ArcGIS help docs, it seems that when in HA, you should use the load balancer URL for the administration URL too. Here is a snip from help docs below: image

In the role JSON we have to specify the private_url which uses the 6443 port and web_context_url, which is the load balancer URL. How can we accomplish the above configuration using the role JSON file? Is this the recommended way to federate when using HA?

cameronkroeker commented 3 years ago

Hello @anandak,

In HA deployments it is recommended to use a load balanced url for both the web_context_url (services URL) and a load balanced URL for private_url. The private_url can be the same as your web_context_url or it can be over port 6443. It all depends on how you configure your load balancer/web adaptors. Here are two different examples:

Example 1: Using an External Load Balancer (443) & Internal Load Balancer (6443).

External Load Balancer (443) -> Web Adaptors (443) = services URL (web_context_url) https://external-loadbalancer.domain.com/server -> https://server-webadaptor-1.domain.com/server & https://server-webadaptor-2.domain.com/server

Private Load Balancer (6443) -> Internal Server URLs = Administration URL (private_url) https://internal-loadbalancer.domain.com:6443/arcgis -> https://server-1.domain.com:6443/arcgis & https://server-2.domain.com:6443/arcgis

"server": {
    "web_context_url":"https://external-loadbalancer.domain.com/server",
    "system_properties":{
        "WebContextURL":"https://external-loadbalancer.domain.com/server"
    },
    "private_url":"https://internal-loadbalancer.domain.com:6443/arcgis",
    "wa_name": "server"
}

Example 2: Using an External Load Balancer for both web_context_url and private_url.

Note: Administrative access must be enabled on ArcGIS Web Adaptors

External Load Balancer (443) -> Web Adaptor (443) = services URL (web_context_url) & administration url https://external-loadbalancer.domain.com/server -> https://server-webadaptor-1.domain.com/server & https://server-webadaptor-2.domain.com/server

"server": {
   "web_context_url":"https://external-loadbalancer.domain.com/server",
   "system_properties":{
       "WebContextURL":"https://external-loadbalancer.domain.com/server"
    },
   "private_url":"https://external-loadbalancer.domain.com/server",
   "wa_name": "server"
},
"web_adaptor": {
   "admin_access": true
}
anandak commented 3 years ago

Apologies for delay in getting back, but thank you! this really helps.