Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Last revision Both sides next revision
litespeed_wiki:lslb:zconf [2017/07/17 21:15]
Michael Alegre [ZCSSL Message] Changed non-formatted HTML blocks into code tags.
litespeed_wiki:lslb:zconf [2019/07/23 14:07]
Kevin Fwu
Line 3: Line 3:
 The ZeroConfig feature must be set up and enabled before use. Please refer to [[https://​www.litespeedtech.com/​docs/​litespeed-web-adc/​config/​zconf|the documentation]] for details. The ZeroConfig feature must be set up and enabled before use. Please refer to [[https://​www.litespeedtech.com/​docs/​litespeed-web-adc/​config/​zconf|the documentation]] for details.
  
-Using ZeroConfig entails sending messages to LiteSpeed Web ADC detailing configuration for backend clusters. The API provides responses indicating success ​of failure.+Using ZeroConfig entails sending messages to LiteSpeed Web ADC detailing configuration for backend clusters. The API provides responses indicating success ​or failure.
  
 A control interface will be available for maintenance operations in an upcoming release. The API for control messages is available for testing now, but does not yet affect the load balancing behavior. A control interface will be available for maintenance operations in an upcoming release. The API for control messages is available for testing now, but does not yet affect the load balancing behavior.
Line 13: Line 13:
 DATA=<​i>​my_data_file</​i>​ DATA=<​i>​my_data_file</​i>​
 curl --silent -X POST --data-binary $DATA https://<​i>​user:​password</​i>​@<​i>​my_load_balancer.com:​my_listner_port</​i>/<​i>​API_COMMAND</​i>?​name=<​i>​my_cluster</​i>​ curl --silent -X POST --data-binary $DATA https://<​i>​user:​password</​i>​@<​i>​my_load_balancer.com:​my_listner_port</​i>/<​i>​API_COMMAND</​i>?​name=<​i>​my_cluster</​i>​
-</​pre></​html>​+</pre
 +<​p><​b>​The fields <​i>​user</​i>​ and <​i>​my_cluster</​i>​ must NOT contain ':'​ (colon) characters.</​b></​html>​
 ==== Handling ZeroConfig API Responses ==== ==== Handling ZeroConfig API Responses ====
 Messages to the ZeroConfig API receive HTTP responses, with common status codes (typically 200 for success, 400 for invalid messages / failures). Response bodies may contain data from the ZeroConfig system or error messages detailing a problem encountered while trying to process a received message. Messages to the ZeroConfig API receive HTTP responses, with common status codes (typically 200 for success, 400 for invalid messages / failures). Response bodies may contain data from the ZeroConfig system or error messages detailing a problem encountered while trying to process a received message.
Line 34: Line 35:
   float: left;   float: left;
   clear: left;   clear: left;
-  margin-right: ​5px;+  margin-right: ​10px;
   font-weight:​ bold;   font-weight:​ bold;
   }   }
  
-dd { display: inline; }+dd { 
 +  ​display: inline; 
 +  ​}
 </​style>​ </​style>​
-<dl>+<div><dl>
 <​dt>​ZCUP:<​dt><​dd>​Cluster up message</​dd><​br /> <​dt>​ZCUP:<​dt><​dd>​Cluster up message</​dd><​br />
 <​dt>​ZCDOWN:<​dt><​dd>​Cluster down message</​dd><​br /> <​dt>​ZCDOWN:<​dt><​dd>​Cluster down message</​dd><​br />
-<​dt>​ZCSSL:<​dt><​dd>​SSL credentials message</​dd>​ +<​dt>​ZCSSL:<​dt><​dd>​Add SSL credentials message<br /></​dd>​ 
-</dl>+<​dt>​ZCSSLRELEASE:<​dt><​dd>​Delete SSL credentials message<​br /></​dd>​ 
 +<​dt>​ZCOWNRRELEASE:<​dt><​dd>​Relinquish ownership of config records</​dd>​</dl></​div>
 </​html>​ </​html>​
 Configuration messages are sent to LiteSpeed Web ADC using the HTTP protocol with Basic Authentication over a secure connection. Once the ZConf Listeners are configured according to the Setup section above, they will accept and process configuration messages sent to their respective IP and port. Configuration messages are sent to LiteSpeed Web ADC using the HTTP protocol with Basic Authentication over a secure connection. Once the ZConf Listeners are configured according to the Setup section above, they will accept and process configuration messages sent to their respective IP and port.
Line 62: Line 66:
   * ''​ip_addr''​ is a ZConf Listener IP address, ''​port''​ is the ZConf Listener port (optional if the standard 443, although in most configurations it is typically set to a different port, leaving 443 available for load balancer traffic).   * ''​ip_addr''​ is a ZConf Listener IP address, ''​port''​ is the ZConf Listener port (optional if the standard 443, although in most configurations it is typically set to a different port, leaving 443 available for load balancer traffic).
   * ''​cluster_name''​ is a user assigned name for the cluster being configured.   * ''​cluster_name''​ is a user assigned name for the cluster being configured.
 +
 +Tip:
 +
 +A ZeroConf VHost is **NOT** the same as an ADC VHost. VHost in the context of a ZeroConf ZCUP message is defined as the list of domains that share the conf_list and template. A single VHost configuration can include thousands of domains as long as they share the conf_list. For example, if there is a backend server with 1000 domains that are listening to port 443, they can share a vhost.
  
 Data: Data:
  
-<​html><​pre class="​code">​conf={+<​html><​pre class="​code">​ 
 +conf={
     "​vhost_list":​     "​vhost_list":​
         [            [   
             {             {
 +                <​u>"​template"​ : "<​i>​VHost template name</​i>",</​u>​
                 "​domain_list"​ :                 "​domain_list"​ :
                     [ <​i>​list of domains (strings)</​i>​ ],                     [ <​i>​list of domains (strings)</​i>​ ],
Line 79: Line 89:
                             "​ip_list"​ :                             "​ip_list"​ :
                                 [                                 [
-                                    { "​ip"​ : <i>ip address for a serving backend (string)</​i>,​ +                                    {  
-                                        <​u>"​port_list"​ : [ <​i>​list of ports (integers), if needed beyond "​dport"​ above</​i>​ ]</​u> ​                            ​+                                        ​"​ip"​ : <i>ip address for a serving backend (string)</​i>,​ 
 +                                        <​u>"​port_list"​ : [ <​i>​list of ports (integers), if needed beyond "​dport"​ above</​i>​ ]</u>
                                     }                                     }
-                                ​<u>,{ "​ip"​ : <​i>​another ip address, using "​dport"</​i>​ }</u>+                                    ​<u>,{ "​ip"​ : <​i>​another ip address, using "​dport"</​i>​ }</u>
                                     <​u>​...</​u>​                                     <​u>​...</​u>​
                                 ]                                 ]
                         }                         }
-                    ​<u>,{ <​i>​another config item with load balancer ports, destination ports, etc.</​i>​ } ... </u>+                        ​<u>,{ <​i>​another config item with load balancer ports, destination ports, etc.</​i>​ } ... </u>
                     ]                     ]
             }             }
-        ​<u>,{ <​i>​another vhost_config</​i>​ } ... </u>+            ​<u>,{ <​i>​another vhost_config</​i>​ } ... </u>
         ]         ]
 } }
Line 97: Line 108:
 Data example: Data example:
  
- <html><​pre class="​code">conf= +<​code>​ 
-        +conf= 
-            "​vhost_list"​ : +
-                +    "​vhost_list"​ : 
-                    +        
-                        "​domain_list"​ : +            
-                            [ "​dom1",​ "​dom2",​ "​dom3"​ ], +                "​domain_list"​ : 
-                        "​conf_list"​ :  +                    [ "​dom1",​ "​dom2",​ "​dom3"​ ], 
-                            +                "​conf_list"​ :  
-                                +                    
-                                    "​lb_port_list"​ : [ 80 ], +                        
-                                    "​dport"​ : 80, +                            "​lb_port_list"​ : [ 80 ], 
-                                    "​be_ssl"​ : false, +                            "​dport"​ : 80, 
-                                    "​ip_list"​ : +                            "​be_ssl"​ : false, 
-                                        +                            "​ip_list"​ : 
-                                            { "​ip"​ : "​192.168.1.101",​ "​port_list"​ : [ 8080 ] }, +                                
-                                            { "​ip"​ : "​192.168.1.102"​ } +                                    { "​ip"​ : "​192.168.1.101",​ "​port_list"​ : [ 8080 ] }, 
-                                        +                                    { "​ip"​ : "​192.168.1.102"​ } 
-                                +                                
-                            +                        
-                    }, +                    
-                    +            }, 
-                        "​domain_list"​ : +            
-                            [ "​dom4",​ "​dom5",​ "​dom6"​ ], +                "​domain_list"​ : 
-                        "​conf_list"​ : +                    [ "​dom4",​ "​dom5",​ "​dom6"​ ], 
-                            [ +                "​conf_list"​ : 
-                                { +                    [ 
-                                    "​lb_port_list"​ : [ 443 ], +                        { 
-                                    "​dport"​ : 443, +                            ​"​lb_port_list"​ : 443 ], 
-                                    "​be_ssl"​ : true, +                            "​dport"​ : 443, 
-                                    "​ip_list"​ : +                            "​be_ssl"​ : true, 
-                                        +                            "​ip_list"​ : 
-                                            { "​ip"​ : "​192.168.1.103"​ }, +                                ​
-                                            { "​ip"​ : "​192.168.1.104"​ } +                                    ​"​ip"​ : "​192.168.1.103"​ }, 
-                                        +                                    ​{ "​ip"​ : "​192.168.1.104"​ } 
-                                +                                ] 
-                            +                        } 
-                    +                    ] 
-                +            }, 
-        +            { 
- </pre></​html>+                "​template"​ : "​noCacheTemplate"​ 
 +                "​domain_list"​ : 
 +                    [ "​dom7",​ "​dom8",​ "​dom9"​ ], 
 +                "​conf_list"​ : 
 +                    [ 
 +                        { 
 +                            ​"​lb_port_list"​ : [ 443 ], 
 +                            "​dport"​ : 443, 
 +                            "​be_ssl"​ : true, 
 +                            "​ip_list"​ : 
 +                                
 +                                    { "​ip"​ : "​192.168.1.103"​ }, 
 +                                    { "​ip"​ : "​192.168.1.104"​ } 
 +                                
 +                        
 +                    
 +            
 +        
 +
 + </code> 
 + 
 +Note: 
 +  * Templates introduced in ADC version 2.4 build 11.
  
  
Line 149: Line 182:
  
 Data: Data:
-<html><​pre class="​code">​conf={}</​pre></​html>+<​code>​conf={}</​code>
 ==== ZCSSL Message ==== ==== ZCSSL Message ====
 Provide SSL data (key, cert and CA bundle) to LiteSpeed Web ADC Provide SSL data (key, cert and CA bundle) to LiteSpeed Web ADC
Line 163: Line 196:
         [         [
             {             {
-                "domain" : <i>a domain name (string)</​i>,​+                "domain_list" : <i>a domain name (string)</​i> ​<u>, more quoted domain names separated by commas </u> ],
                 "​key"​ : <​i>​the <​b>​contents</​b>​ (<​b>​not</​b>​ the file name) of the private key file (string)</​i>​ ,                 "​key"​ : <​i>​the <​b>​contents</​b>​ (<​b>​not</​b>​ the file name) of the private key file (string)</​i>​ ,
                 "​cert"​ : <​i>​the <​b>​contents</​b>​ (<​b>​not</​b>​ the file name) of the certificate file (string)</​i>​ ,                 "​cert"​ : <​i>​the <​b>​contents</​b>​ (<​b>​not</​b>​ the file name) of the certificate file (string)</​i>​ ,
Line 182: Line 215:
         [         [
             {             {
-                "domain" : "​litespeedtech.com",​+                "domain_list" : "​litespeedtech.com"​, "​blog.litespeedtech.com"​ ],
                 "​key"​ : "​-----BEGIN RSA PRIVATE KEY----- ... " ,                 "​key"​ : "​-----BEGIN RSA PRIVATE KEY----- ... " ,
                 "​cert"​ : "​-----BEGIN CERTIFICATE----- ... " ,                 "​cert"​ : "​-----BEGIN CERTIFICATE----- ... " ,
Line 188: Line 221:
             }             }
         ]         ]
 +}
 +</​code>​
 +==== ZCSSLRELEASE Message ====
 +Delete SSL data (key, cert and CA bundle) for specified domains from LiteSpeed Web ADC
 +
 +URL: ''<​nowiki>​https://​[user:​password@]ip_addr[:​port]/​ZCSSLRELEASE?​name=cluster_name</​nowiki>''​
 +
 +
 +Data:
 +<​html><​pre class="​code">​
 +conf=
 +{
 +    "​ssl_list"​ :
 +        [
 +            {
 +                "​domain_list"​ : [ <i>a domain name (string)</​i>​ <u>, more quoted domain names separated by commas </u> ]            }
 +            <u>, { <​i>​more ssl configs</​i>​ } ... </u>
 +        ]
 +}
 +</​pre></​html>​
 +
 +
 +Data example:
 +
 +<​code>​
 +conf=
 +{
 +    "​ssl_list"​ :
 +        [
 +            {
 +                "​domain_list"​ : [ "​litespeedtech.com",​ "​blog.litespeedtech.com"​ ]
 +            }
 +        ]
 +}
 +</​code>​
 +==== ZCOWNRRELEASE Message ====
 +Relinquish ownership of any configuration records for specified domains from LiteSpeed Web ADC (allows
 +specified domains to be owned by a different authorized user, such as when transferring to another
 +provider).
 +
 +URL: ''<​nowiki>​https://​[user:​password@]ip_addr[:​port]/​ZCOWNRRELEASE?​name=cluster_name</​nowiki>''​
 +
 +
 +Data:
 +<​html><​pre class="​code">​
 +conf=
 +{
 +    "​domain_list"​ : [ <i>a domain name (string)</​i>​ <u>, more quoted domain names separated by commas </u> ]
 +}
 +</​pre></​html>​
 +
 +
 +Data example:
 +
 +<​code>​
 +conf=
 +{
 +     "​domain_list"​ : [ "​litespeedtech.com",​ "​blog.litespeedtech.com"​ ]
 } }
 </​code>​ </​code>​
Line 206: Line 297:
 Data: Data:
 <​html><​pre class="​code">​ <​html><​pre class="​code">​
-be_list={+be_list= 
 +{
     "​be_list"​ :     "​be_list"​ :
         [          [ 
Line 218: Line 310:
  
 <​code>​ <​code>​
-be_list={+be_list= 
 +{
     "​be_list"​ :     "​be_list"​ :
         [          [ 
Line 234: Line 327:
  
 <​html><​pre class="​code">​ <​html><​pre class="​code">​
-be_list={+be_list= 
 +{
     "​be_list"​ :     "​be_list"​ :
         [         [
Line 246: Line 340:
  
 <​code>​ <​code>​
-be_list={+be_list= 
 +{
     "​be_list"​ :     "​be_list"​ :
         [          [ 
Line 275: Line 370:
 Sample Response: Sample Response:
 <​code>​_10.10.4.70:​80;​_10.10.4.71:​80;​_10.10.4.72:​80;​_10.10.4.73:​80;​_10.10.4.74:​80;​_10.10.4.75:​80</​code>​ <​code>​_10.10.4.70:​80;​_10.10.4.71:​80;​_10.10.4.72:​80;​_10.10.4.73:​80;​_10.10.4.74:​80;​_10.10.4.75:​80</​code>​
-Note: the 'u' (underscore) prefix indicates non-ssl backend destinations. Secure (ssl) destinations are shown with an '​s'​ prefix.+Note: the '_' (underscore) prefix indicates non-ssl backend destinations. Secure (ssl) destinations are shown with an '​s'​ prefix.
 ==== ZCISUSPEND Message ==== ==== ZCISUSPEND Message ====
 Check whether specific backend server:port destinations are currently suspended Check whether specific backend server:port destinations are currently suspended
  • Admin
  • Last modified: 2020/11/18 15:36
  • by Lisa Clarke