A virtual service may expose multiple ports. This section explains the two ways to map virtual service ports to corresponding ports on pool servers.

Mapping a Set of Virtual Service Ports to the Same Port on Pool Servers

This is the simplest configuration, where the virtual service and pool server ports are the same. To achieve this:

  1. Use the Settings tab of the virtual service editor to identify multiple virtual service ports, one port at a time, or by specifying a port range.

    Figure 1. Figure 1. Adding Individual Ports
    Figure 2. Figure 2. Adding a Port Range
  2. Use the Server tab of the pool editor to deactivate port translation by selecting the Deactivate Port Translation check box.

    Figure 3.

    In this case, the “Default Server Port” property of the pool is ignored, and requests are forwarded to servers on the same port as the receiving port of the virtual service.

Mapping a Set of Virtual Service Ports to Different Ports on Pool Servers

For this case, a specific virtual service port must be mapped to a specific port on pool servers.

To achieve this:

  1. Use the Settings tab of the virtual service editor to identify multiple virtual service ports, individually or by port range.

  2. Create a pool for each pool server port and use the Settings tab of the pool editor to configure a unique “Default Server Port” for each pool.

    Figure 4. Figure 4. Assigning Port 8080 to the Pool Named PortMapVS-pool-8080
    Figure 5. Figure 5. Assigning Port 8081 to the Pool Named PortMapVS-pool-8081
    Figure 6. Figure 6. Assigning Port 8082 to the Pool Named PortMapVS-pool-8082
    Note:

    The actual back-end members of all the pools may be the same.

  3. Using the Policies tab of the virtual service editor, add an HTTP request rule that uses content switching to direct requests to pools based on the value of the port number. Figure 7 illustrates what also must be done for ports 81 and 82, and figure 8 shows rules for all three service ports.

    Figure 7. Figure 7. An HTTP request rule content switches service port requests to a different port on pool servers.
    Figure 8. Figure 8. For the virtual service, three content-switching rules are defined, one for each port mapping
  4. The resulting virtual service is displayed as follows:

Figure 9. Figure 9. Three port numbers for virtual service PortMapVS are content-switched to different corresponding back-end server port numbers