Using Wildcard Virtual Servers in NetScaler CPX Instance
When you provision a NetScaler instance, only one private IP address (single IP address) is assigned to a NetScaler CPX instance by the Docker engine. The three IP functions of a NetScaler instance are multiplexed onto one IP address. This single IP address uses different port numbers to function as the NSIP, SNIP, and VIP(s).
The single IP address that is assigned by the Docker engine is dynamic, you can add the Load Balancing (LB) or Content Switching (CS) virtual servers using the single IP address or using 127.0.0.1 IP address. The virtual servers created using 127.0.0.1 is called as Wildcard Virtual Servers. By default, when you create a wildcard virtual server, the NetScaler CPX replaces the assigned IP address of the wildcard virtual server, that is, 127.0.0.1, with the NSIP assigned to the NetScaler CPX instance by the Docker engine.
In high-availability NetScaler CPX deployments, you can add wildcard virtual servers on one of the NetScaler CPX instance and copy the ns.conf file from the instance to other NetScaler CPX instances in the deployment and make sure that the NetScaler configuration is consistent across all the NetScaler CPX instances in the deployment instead of identifying the single IP address assigned by the Docker engine to the NetScaler instance and create the LB or CS virtual servers based on the single IP address on all the NetScaler CPX instances in the deployment.
Points to Note:
- Make sure that the port number that you assign to the wildcard virtual server is not used by any other virtual server in the deployment.
- Wildcard virtual server addition fails if the port number that you assign to the wildcard virtual server is already in use by the internal services.
- * character is not supported by wildcard virtual server.
To create a wildcard load balancing virtual server, at the command prompt, enter the following command:
add lb vserver <name> <serviceType> 127.0.0.1 <port> add lb vserver testlbvserver HTTP 127.0.0.1 30000
To create a wildcard content switching virtual server, at the command prompt, enter the following command:
add cs vserver <name> <serviceType> 127.0.0.1 <port> add cs vserver testcsvserver HTTP 127.0.0.1 30000