VMware VSHIELD APP 1.0 - API Instrukcja Użytkownika Strona 51

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
  • Strona
    / 132
  • Spis treści
  • BOOKMARKI
  • Oceniono. / 5. Na podstawie oceny klientów
Przeglądanie stron 50
VMware, Inc. 51
Chapter 5 vShield Edge Management
Configure Load Balancer
ThevShieldEdgeprovidesloadbalancingforHTTPtraffic.Loadbalancing(uptoLayer7)enablesWeb
applicationautoscaling.Toimplementloadbalancing,youmapanexternal(orpublic)IPaddresstoasetof
internalservers.TheloadbalanceracceptsHTTPrequestsontheexternalIPaddressanddecides
which
internalservertouse.Port80isthedefaultlisteningportforloadbalancerservice.
AllLoadBalancersettingsconfig uredbyusingRESTrequestsappearunderthevShieldEdge>LoadBalancer
tabfortheappropriatevShieldEdgeinthevShieldManageruserinterfaceandinthevSphereClientplug
in.
Fortheloadbalancerschema,see“vShieldEdgeSchemas”onpage 116.SampleXMLrequestbody:
Example 5-20. Configure load balancer
POST https://<vsm-ip>/api/2.0/networks/<internal-portgroup-vc-moref-id>/edge
<vshieldEdgeConfig xmlns="vmware.vshield.edge.2.0">
<loadbalancerConfig>
<listener>
<externalIpAddress>10.112.2.148</externalIpAddress>
<backEndServerConfig>
<ipAddress>192.168.10.11</ipAddress>
<port>80</port>
</backEndServerConfig>
<algorithm>ip-hash</algorithm>
<enableLog>false</enableLog>
</listener>
</loadbalancerConfig>
</vshieldEdgeConfig>
Forthedatapathtowork,youneedtochangethedefaultfirewallpolicytoALLOW,orpunchFirewallrules
toallowdatatrafficonexternalandinternalinterfaces.Rules:
YoucanmapaglobalorpublicIPaddresstoasetofinternalserversforloadbalancing.Theloadbalancer
acceptsHTTPrequestsonthe<ipAddress>specified.If<port>isnotgiven,80isthedefaultport.
The<backEndServerConfig>isalistofoneormoreIPaddressesrepresentingserverstouseforload
balancing.
vShieldManagerprocessesthepostedXMLfileasacompletesetofloadbalancingserversforthenetwork
specified.Thecurrentsetofloadbalancingserversforanetworkisreplacedwiththisnewsetofservers.
Youcanaddmultipleserversaslistenersbyenteringmultiple<listener>sectionsinthebody.
Youcanconfigurethealgorithmthatisusedtodetermineloadbalancing.Theoptional<algorithm>
elementcanbesettoround-robin(thedefault)orip-hash.
Loggingisdisabledbydefault.Toenablelogging,adda<enableLog>elementsettotrue.
Manage Load Balancer Service
Example 5-21. Start load balancer
POST https://<vsm-ip>/api/2.0/networks/<internal-portgroup-vc-moref-id>/edge
<vshieldEdgeConfig xmlns="vmware.vshield.edge.2.0">
<loadbalancerService>up</loadbalancerService>
</vshieldEdgeConfig>
Example 5-22. Stop load balancer
POST https://<vsm-ip>/api/2.0/networks/<internal-portgroup-vc-moref-id>/edge
<vshieldEdgeConfig xmlns="vmware.vshield.edge.2.0">
<loadbalancerService>down</loadbalancerService>
</vshieldEdgeConfig>
Przeglądanie stron 50
1 2 ... 46 47 48 49 50 51 52 53 54 55 56 ... 131 132

Komentarze do niniejszej Instrukcji

Brak uwag