Linux Virtual Server Jim Lawson VAGUE/University of Vermont /

Slides:



Advertisements
Similar presentations
Understanding Layer 3 Redundancy. © 2013 Cisco and/or its affiliates. All rights reserved. Cisco Public 2 Upon completing this lesson, you will be able.
Advertisements

Highly Available Central Services An Intelligent Router Approach Thomas Finnern Thorsten Witt DESY/IT.
Dr. Zahid Anwar. Simplified Architecture of Linux Cluster Simplified Architecture of a Single Computer Simplified architecture of an enterprise cluster.
Module 8: Concepts of a Network Load Balancing Cluster
1 Internet Networking Spring 2004 Tutorial 13 LSNAT - Load Sharing NAT (RFC 2391)
Hypertext Transfer Protocol Kyle Roth Mark Hoover.
Page: 1 Director 1.0 TECHNION Department of Computer Science The Computer Communication Lab (236340) Summer 2002 Submitted by: David Schwartz Idan Zak.
Oct 21, 2004CS573: Network Protocols and Standards1 IP: Addressing, ARP, Routing Network Protocols and Standards Autumn
Design and Implementation of a Server Director Project for the LCCN Lab at the Technion.
1 Spring Semester 2007, Dept. of Computer Science, Technion Internet Networking recitation #12 LSNAT - Load Sharing NAT (RFC 2391)
Firewall and Proxy Server Director: Dr. Mort Anvari Name: Anan Chen Date: Summer 2000.
Copyright © 2002 Wensong Zhang. Page 1 Free Software Symposium 2002 Linux Virtual Server: Linux Server Clusters for Scalable Network Services Wensong Zhang.
10/02/2004ELFms meeting1 Linux Virtual Server Miroslav Siket FIO-FS.
Module 13: Network Load Balancing Fundamentals. Server Availability and Scalability Overview Windows Network Load Balancing Configuring Windows Network.
Computer Networks. IP Addresses Before we communicate with a computer on the network we have to be able to identify it. Every computer on a network must.
© 2006 Cisco Systems, Inc. All rights reserved.1 Microsoft Network Load Balancing Support Vivek V
INSTALLING MICROSOFT EXCHANGE SERVER 2003 CLUSTERS AND FRONT-END AND BACK ‑ END SERVERS Chapter 4.
Submitted by: Shailendra Kumar Sharma 06EYTCS049.
Module 12: Routing Fundamentals. Routing Overview Configuring Routing and Remote Access as a Router Quality of Service.
1 Virtual Router Redundancy Protocol (VRRP) Speaker: Li-Wen Chen Date:
Module 10: Maintaining High-Availability. Overview Introduction to Availability Increasing Availability Using Failover Clustering Standby Servers and.
Clustering and Load Balancing. Outline Introduction Linux Virtual Server Microsoft load balancing solution.
Homework 02 NAT 、 DHCP 、 Firewall 、 Proxy. Computer Center, CS, NCTU 2 Basic Knowledge  DHCP Dynamically assigning IPs to clients  NAT Translating addresses.
DYNAMIC LOAD BALANCING ON WEB-SERVER SYSTEMS by Valeria Cardellini Michele Colajanni Philip S. Yu.
70-293: MCSE Guide to Planning a Microsoft Windows Server 2003 Network, Enhanced Chapter 12: Planning and Implementing Server Availability and Scalability.
BNL PDN Enhancements. Perimeter Load Balancers Scaleable Performance Fault Tolerance Server Maintainability User Convenience Perimeter Security.
VIRTUAL SERVERS Chapter 7. 2 OVERVIEW Exchange Server 2003 virtual servers Virtual servers in a clustering environment Creating additional virtual servers.
Andrew Lahiff HEP SYSMAN June 2016 Hiding infrastructure problems from users: load balancers at the RAL Tier-1 1.
1 Super/Ultra-Basic Load-Balancing Introduction For AFNOG 2012 Joel Jaeggli.
Central Management of 300 Firewalls and Access-Lists Fabian Mauchle TNC 2012 Reykjavík, 21-May-2012.
Single-stack IPv6-only data center deployments
Instructor Materials Chapter 4: Network Addressing
Introduction to Networks v6.0
Introduction of load balancers at the RAL Tier-1
NAT、DHCP、Firewall、FTP、Proxy
70-293: MCSE Guide to Planning a Microsoft Windows Server 2003 Network, Enhanced Chapter 12: Planning and Implementing Server Availability and Scalability.
Layer 3 Redundancy 1. Hot Standby Router Protocol (HSRP)
IP: Addressing, ARP, Routing
Understanding Solutions
Scaling Network Load Balancing Clusters
Bentley Systems, Incorporated
Apache web server Quick overview.
Networking for Home and Small Businesses – Chapter 5
Network Address Translation (NAT)
Instructor Materials Chapter 5: Ethernet
F5 BIGIP V 9 Training.
Network Address Translation
Network Load Balancing
VIRTUAL SERVERS Presented By: Ravi Joshi IV Year (IT)
Network Load Balancing Topology
Network Address Translation (NAT)
2TCloud - Veeam Cloud Connect
Chapter 6: Network Layer
Introduction to Networking
Virtual Router Redundancy Protocol (VRRP)
NET323 D: Network Protocols
Networking for Home and Small Businesses – Chapter 5
Routing.
Distributed Content in the Network: A Backbone View
New Solutions For Scaling The Internet Address Space
CIS 82 Routing Protocols and Concepts Chapter 11 NAT
Lutz Donnerhacke IKS Service GmbH
NET323 D: Network Protocols
Server Cluster and LVS based Cluster
World Wide Web Uniform Resource Locator hostname [:port]/path
Chapter 11: Network Address Translation for IPv4
Network Applications: Multi-Server Request Routing
EE 122: Lecture 22 (Overlay Networks)
Network Address Translation (NAT)
Routing.
Presentation transcript:

Linux Virtual Server Jim Lawson VAGUE/University of Vermont /

What is a load balancer? ● Front-end appliance for a web (or other service) farm ● Allows you to “scale out” rather than “scale up” ● Several vendors supply products in this space (Cisco, F5, Foundry, others)

What is LVS? ● Linux Virtual Server ● (“IPVS” inside the kernel) ● Kernel-space load balancer ● Fast, efficient, reliable ● Somewhat feature-limited compared to commercial options

What is keepalived? ● Provides: – Health-checking for “realservers” - takes malfunctioning servers out of the pool – Failover for director/load- balancer

LVS NAT config

LVS DR config

Why DR (direct-route?) ● Director only needs to handle request portion of traffic. ● In typical HTTP, request is small (typically <1K) – GET /index.html HTTP/1.1 – Host: ● Response is sent directly to gateway – HTTP/ OK... –... Content-size: 22947

Why DR (direct-route?) ● Francois JEANMOUGIN Francois (dot) JEANMOUGIN (at) 123multimedia (dot) com 06/06/2005: – I have 38 realservers behind my director, incoming traffic (to director) goes up to 20Mb/s, outgoing (from realservers LVS-DR setup) up to 60Mb/s. I have about 1200 sites hosted. 36 virtual_server entries in keepalived.conf, 30 VIPs. There's no noticable load on the poor PIII/700 director that's handling the traffic.

Why not DR? ● ARP problem – Realservers have to be configured to not “ARP” for the VIP – only the director should respond to ARP requests for that IP ● Linux: 2.2, 2.4 kernels need “hidden” arp patch ● 2.6 kernels only need arp_ignore and arp_announce set in /proc. ● Most other unixes (unices?): NOARP works fine ● Windows (since NT4SP2): ifconfig -arp

Why not DR? ● If you forget to set NOARP (or hidden/arp_announce) before you bring the VIP up on the realserver, the realserver will receive all traffic bound for the VIP! – To avoid this, put the VIP config in a special startup script which always sets the proper flags in /proc – In general, it is a good idea to have 1 VIP per service or pool

LVS scheduling algorithms ● rr (round-robin) ● lc (pick server with least # connections) ● wrr, wlc – weighted versions of above ● For load balanced caching proxy servers: – DH (destination hash, static, based upon destination IP) – LBLC (locality-based least connection; like DH but dynamic)

lc example graph (rrd image courtesy Salvatore D. Tepedino) LVS with 2 realservers, serving http all day

lc vs rr ● Round-robin keeps servers “more or less” evenly balanced ● Least-connections is very good at keeping them evenly balanced ● BUT... “thundering herd problem” – Newly added or recovered realservers have no active connections! Guess where everyone gets sent?

Keepalived ● Monitors services for availability – Built-in checks: http, https, smtp, ldap, “tcp” – Custom scripts are easy to plug in – Threaded Health Checks ● When services go down, servers are removed from pool and users are automatically redirected to remaining available nodes

What about the director? ● It's a single point of failure ● Solution: keepalived VRRP – Virtual Router Redundancy Protocol – RFC 2338, election protocol, multicast – Similar to Cisco's HSRP – active/passive – Can have VIPs staggered between directors for active/active config

What about the director? ● Active connection state (client IP realserver) is communicated via IPVS syncd – Active server informs passive server about new associations – Runs over crossover cable, or LAN ● During a failover, “gratuitous ARP” is sent ● Failback: set PREEMPT_DELAY

CIT LVS config