CS433/533 Computer NetworksOutlineAdminRecap: High-Performance Network ServersRecap: Operational LawsRecap: Why Multiple Network Servers?Recap: Load Direction: Basic ArchitectureRecap: Load DirectionNetwork Path PropertiesNetwork Path Properties: Improve ScalabilityServer SelectionSlide 12Basic Direction MechanismsDirection Mechanisms are Often CombinedExample: NetflixExample: Netflix Manifest FileSlide 17Example: Wikipedia ArchitectureSlide 19DNS Indirection and RotationExample: Amazon Elastic Cloud 2 (EC2) Elastic Load BalancingDetails: Step 1Details: Step 2Details: Step 3DiscussionSlide 26Clustering with VIP: Basic IdeaBig PictureVIP ClusteringLoad Balancer (LB): Basic StructureProblemSolution 1: Network Address Translation (NAT)Example Virtual Server via NATLB/NAT FlowSlide 35SLB/NAT Flow: DetailsLB/NAT Advantages and DisadvantagesLB with Direct ReplyLB/DR ArchitectureWhy IP Address Matters?ARP ProtocolARP in ActionLB/DR ProblemLB via Direct RoutingLB/DR Advantages and DisadvantagesExample Implementation of LBSlide 47Discussion: Problem of the Load Balancer ArchitectureSolutionsMicrosoft NLBSlide 51CS433/533Computer NetworksLecture 12Load Balancing Networks2/16/20121OutlineAdmin and recapLoad balance (direction)oLoad direction mechanismsoDNSoLoad balancer (smart switch)2AdminProgramming assignment 1 status3Recap: High-Performance Network ServersAvoid blocking (so that we can reach bottleneck throughput)threadsLimit unlimited thread overheadthread pool, async ioCoordinating data accesssynchronization (lock, synchronized)Coordinating behavior: avoid busy-waitwait/notify; FSMExtensibility/robustnesslanguage support/design for interfaces4Recap: Operational LawsUtilization law: U = XSForced flow law: Xi = Vi XBottleneck device: largest Di = Vi SiLittle’s Law: Qi = Xi RiBottleneck analysis:5},min{)(max1ZDNDNX},max{)(maxZNDDNR Recap: Why Multiple Network Servers?Scalabilitybeyond single server capability and geolocation of a single serverRedundancy and fault toleranceadministration/maintenance (e.g., incremental upgrade)redundancy (e.g., to handle failures)System/software architectureresources may be naturally distributed at different machines (e.g., run a single copy of a database server due to single license; access to resource from third party) security (e.g., front end, business logic, and database)6Recap: Load Direction: Basic ArchitectureMajor componentsServer state monitoringNetwork path properties between clients and serversServer selection alg.Server routing/adaptation Client direction mechanism7InternetInternetClientSite ASite B?Recap: Load Direction8server statenet path propertybetween servers/clientsserverselectionalgorithmspecificrequest ofa clientnotify clientabout selection(direction mech)server routingNetwork Path PropertiesWhy is the problem difficult?oScalability: if do measurements, complete measurements grow with N * M, where•N is # of sources (e.g., clients)•M is # of destinations (e.g., servers)oComplexity/feasibility in computing path metrics9MNNetwork Path Properties: Improve ScalabilityAggregation:omerge a set of IP addresses (reduce N and M)•E.g., when computing path properties, Akamai aggregates all clients sharing the same local DNS serverSampling and predictionoInstead of measuring N*M entries, we measure a subset and predict the unmeasured pathsoWe will cover it later in the course10M serversN’~100K local DNS serversN~all Internet clientsServer SelectionWhy is the problem difficult?What are potential problems of just sending each new client to the lightest load server?11OutlineAdmin and recapLoad balance (direction)oOverviewoBasic load direction mechanisms12Basic Direction MechanismsApplication layerApp/user is given a list of candidate server names HTTP redirectorDNS: name resolution gives a list of server addressesIP layer: Same IP address represents multiple physical serversIP anycast: Same IP address shared by multiple servers and announced at different parts of the Internet. Network directs different clients to different servers (e.g., Limelight)Load balancer (smart switch) indirectionReverse proxy13Direction Mechanisms are Often Combined14DNS name1IP1IP2 IPnCluster1in US EastCluster2in US WestLoad balancerLoad balancerproxyCluster2in EuropeLoad balancerLoad balancerserversDNS name2Example: Netflix15Example: Netflix Manifest File16Client player authenticate and then downloads manifest file from servers at Amazon CloudExample: Netflix Manifest File17Example: Wikipedia Architecture18http://wikitech.wikimedia.org/images/8/81/Bergsma_-_Wikimedia_architecture_-_2007.pdfOutlineAdmin and recapLoad balance (direction)oBasic load direction mechanismsoDNS19DNS Indirection and Rotation20157.166.226.25routerDNS serverfor cnn.comIP addressof cnn.com157.166.226.25157.166.226.26IP addressof cnn.com157.166.226.26157.166.226.25157.166.226.26157.166.255.18Example: Amazon Elastic Cloud 2 (EC2) Elastic Load BalancingUse the elb-create-lb command to create an Elastic Load Balancer. Use the elb-register-instances-with-lb command to register the Amazon EC2 instances that you want to load balance with the Elastic Load Balancer. Elastic Load Balancing automatically checks the health of your load balancing Amazon EC2 instances. You can optionally customize the health checks by using the elb-configure-healthcheck command.Traffic to the DNS name provided by the Elastic Load Balancer is automatically distributed across your load balanced, healthy Amazon EC2 instances.21http://aws.amazon.com/documentation/elasticloadbalancing/Details: Step 11. Call CreateLoadBalancer with the following parameters:AvailabilityZones = us-east-1aListeners•Protocol = HTTP•InstancePort = 8080•LoadBalancerPort = 80•LoadBalancerName = MyLoadBalancerThe operation returns the DNS name of your LoadBalancer. You can then map that to any other domain name (such as www.mywebsite.com) (how?)PROMPT> elb-create-lb MyLoadBalancer --headers --listener "lb-port=80,instance-port=8080,protocol=HTTP" --availability-zones us-east-1aResult:DNS-NAME DNS-NAME DNS-NAME MyLoadBalancer-2111276808.us-east-1.elb.amazonaws.com 22http://docs.amazonwebservices.com/ElasticLoadBalancing/latest/DeveloperGuide/Details: Step 22. Call ConfigureHealthCheck with the following parameters:LoadBalancerName = MyLoadBalancerTarget =
View Full Document