Linux Virtual Server Administration

Linux Virtual Server Administration

Linux Virtual Server (LVS) for Red Hat Enterprise Linux 4.5

Legal Notice

Abstract

Building a Linux Virtual Server (LVS) system offers highly-available and scalable solution for production services using specialized routing and load-balancing techniques configured through the PIRANHA. This book discusses the configuration of high-performance systems and services with Red Hat Enterprise Linux 4.5 and LVS.


Table of Contents

Introduction
1. Technology Overview
2. Basic Configurations
2.1. Load-Balancing Clusters Using Linux Virtual Servers
2.2. Feedback
1. Linux Virtual Server Overview
1.1. A Basic LVS Configuration
1.1.1. Data Replication and Data Sharing Between Real Servers
1.2. A Three Tiered LVS Configuration
1.3. LVS Scheduling Overview
1.3.1. Scheduling Algorithms
1.3.2. Server Weight and Scheduling
1.4. Routing Methods
1.4.1. NAT Routing
1.4.2. Direct Routing
1.5. Persistence and Firewall Marks
1.5.1. Persistence
1.5.2. Firewall Marks
1.6. LVS Cluster — A Block Diagram
1.6.1. Components of an LVS Cluster
2. Initial LVS Configuration
2.1. Configuring Services on the LVS Routers
2.2. Setting a Password for the Piranha Configuration Tool
2.3. Starting the Piranha Configuration Tool Service
2.3.1. Configuring the Piranha Configuration Tool Web Server Port
2.4. Limiting Access To the Piranha Configuration Tool
2.5. Turning on Packet Forwarding
2.6. Configuring Services on the Real Servers
3. Setting Up a Red Hat Enterprise Linux LVS Cluster
3.1. The NAT LVS Cluster
3.1.1. Configuring Network Interfaces for a NAT LVS Cluster
3.1.2. Routing on the Real Servers
3.1.3. Enabling NAT Routing on the LVS Routers
3.2. LVS Cluster via Direct Routing
3.2.1. Direct Routing and arptables_jf
3.2.2. Direct Routing and IPTables
3.3. Putting the Cluster Together
3.3.1. General LVS Networking Tips
3.4. Multi-port Services and LVS Clustering
3.4.1. Assigning Firewall Marks
3.5. FTP In an LVS Cluster
3.5.1. How FTP Works
3.5.2. How This Affects LVS Routing
3.5.3. Creating Network Packet Filter Rules
3.6. Saving Network Packet Filter Settings
4. Configuring the LVS Routers with Piranha Configuration Tool
4.1. Necessary Software
4.2. Logging Into the Piranha Configuration Tool
4.3. CONTROL/MONITORING
4.4. GLOBAL SETTINGS
4.5. REDUNDANCY
4.6. VIRTUAL SERVERS
4.6.1. The VIRTUAL SERVER Subsection
4.6.2. REAL SERVER Subsection
4.6.3. EDIT MONITORING SCRIPTS Subsection
4.7. Synchronizing Configuration Files
4.7.1. Synchronizing lvs.cf
4.7.2. Synchronizing sysctl
4.7.3. Synchronizing Network Packet Filtering Rules
4.8. Starting the Cluster
A. Using LVS with Red Hat Cluster
Index

Note: This documentation is provided {and copyrighted} by Red Hat®, Inc. and is released via the Open Publication License. The copyright holder has added the further requirement that Distribution of substantively modified versions of this document is prohibited without the explicit permission of the copyright holder. The CentOS project redistributes these original works (in their unmodified form) as a reference for CentOS-4 because CentOS-4 is built from publicly available, open source SRPMS. The documentation is unmodified to be compliant with upstream distribution policy. Neither CentOS-4 nor the CentOS Project are in any way affiliated with or sponsored by Red Hat®, Inc.