240 likes | 352 Views
Technion- Israel Institute of Technology. Lecturer: Dr. Reuven Cohen Lab Engineer: Eng. Itai Dabran Project Supervisor: Daniel Segal Authors: Rony Fuks Yossi Peery Gil Sasson Fall 2000/1. Computer Science Department. The Laboratory of Computer Communications and Networking.
E N D
Technion- Israel Institute of Technology Lecturer: Dr. Reuven CohenLab Engineer: Eng. Itai DabranProject Supervisor: Daniel Segal Authors: Rony Fuks Yossi Peery Gil Sasson Fall 2000/1 Computer Science Department The Laboratory of Computer Communications and Networking Web Server Distributor Project Web Server Distributor
Motivations High Performances E-Commerce, B2B, B2C, DotCom Hardware Technology Vs. Internet Growth How to Distribute ? Answer …… Web Server Distributor Web Server Distributor
Theory Web Server Distributor
Types of Load Balancers • Hardware • Network • Software Web Server Distributor
Server Monitoring • Internal Monitoring • External Monitoring • ICMP • TCP • HTTP Web Server Distributor
Server Selection • Round Robin • Response Time Based Decision • Sophisticated Algorithms Web Server Distributor
Our Project Web Server Distributor
URI => GUI Redirector Sampler Worker Thread WS 1 Worker Thread GET => Worker Thread HTTP <= Completion REPLY Client Port Loop . Load Balancer new HTTP OP connects . ACCEPT File Table . OP HTTP Updates WS Table RECV redirect WS n GET => HTTP <= Decision REPLY Client Algorithms Our Project <=Server IP Web Server Distributor
Our ProjectRedirector • Simple HTTP server • Using IO completion ports • Multi Threaded Web Server Distributor
Our ProjectGUI Web Server Distributor
Our ProjectGUI MFC GUI • Communication with the load balancer and the redirector through message tunneling Web Server Distributor
Our ProjectSampler Algorithm • Sampling algorithm • Completed transaction • Incomplete transaction • No Response Web Server Distributor
Our ProjectSampler Code Structure • Thread Creation/Destruction • HTTP “GET” request • Time measurement • Sampling Ratio • Updating Interface Web Server Distributor
Our ProjectLoad Balancer • File Table • Sampling List • Web Server Table • Decision Algorithm Web Server Distributor
Our ProjectLoad BalancerFile Table Input ini file • URI • File Size • Server Location Output Hash Table Web Server Distributor
Our ProjectLoad BalancerSampling List How to check WS ? • Same File on Each WS • Go over hash table • Find all files that exist on all WS Web Server Distributor
Our ProjectLoad BalancerWeb Server Table Web Server Distributor
Our ProjectLoad BalancerWeb Server Table Ranking Process • Results from Sampler (wait till time out) What if we didn’t receive all the file ? • Find lowest response time • Find range (lowestXfactor) • Find next range (etc`) Web Server Distributor
Our ProjectLoad BalancerWeb Server Table Time Outs • No. of time outs • Cont. Time outs Web Server Distributor
Our ProjectLoad BalancerWeb Server Table Bytes Sent Calculation • Dividing the bytes sent by periods Web Server Distributor
-150 -100 -50 0 Time Line Our ProjectLoad BalancerWeb Server Table Dividing the bytes sent by periods • What is the logic behind • Calculations of Clients Distributions Times Web Server Distributor
Our ProjectLoad BalancerWeb Server Table Weighted Rank Calculations Weighted Rank = (F1 X Rank + F2 X Average Rank + F3 X No. Time Out + F4 X Cont. Time Out ) + (B1 X B.Sent[1]/Max Capacity + B2 X B.Sent[2]/Max Capacity + B3 X B.Sent[3]/Max Capacity + B4 X B.Sent[4]/Max Capacity ) Web Server Distributor
Our ProjectLoad BalancerDecision Algorithm Best Server Function Find lowest weighted rank Update weighted rank/Bytes sent If lowest weighted rank = If Continuous Time Out MaxContTimeOut Return Null If Continuous Time Out < MaxContTimeOut Return Redirector IP Web Server Distributor
Our Project FIN Web Server Distributor