100 likes | 211 Vues
This document details the integration of SNMP (Simple Network Management Protocol) for optimizing load balancing in LVS (Linux Virtual Server). It outlines the purpose of SNMP, its implementation through agents and MIBs, and the goal of leveraging SNMP data to enhance preemptive load balancing. The use of Python scripts for monitoring and adjusting load, along with practical lessons learned about SNMP parsing efficiency and structure, provide valuable insights. Future improvements are discussed, focusing on enhancing calculations and utilizing more SNMP data for performance optimization.
E N D
SNMP auto LVS balancing Jason Liptak
Jason Liptak Overview • SNMP overview • Network Setup • Solution • Lessons Learned • Future
Jason Liptak SNMP – purpose • Monitor Network • Servers, Switches, Printers, etc. • Change network remotely • Community strings to access • Public/ Private • Plain text • Version 3 • Added security
Jason Liptak SNMP - Implementation • Agents running on devices to respond • Management information base (MIBs) • Describe structure layout of information • Tree layout via numbers specify object identifiers (OID) • Messages • Get(Request/NextRequest/BulkRequest) • SetRequest • Response
Jason Liptak Goal • Using SNMP information • Change load balance of LVS • Preemptive load balancing • Extendable design to other MIBs
Jason Liptak LVS -Access to internet -Access to local -Polls SNMP Server 1 -Access to local -Running SNMP -Running Web Service Server 2 -Access to local -Running SNMP -Running Web Service
Jason Liptak Solution - Scripts • Schedule balance script to run • “at –f script now+1min” • Python script to monitor and modify • Change ipvsadm • Poll SNMP • Parse SNMP • SNMP parsing method • Dictionary tree
Jason Liptak Solution - Calculation • Processor usage determines load • Large requests going to one server • Remotely accessing one server • Processor not running efficiently • Simple calculation • (100 – processor usage) • Sample calculation, easy to change via scripts
Jason Liptak Lessons Learned • Needed better SNMP parsing • More efficient structure and parsing • Ability to aggregate OID sections • SNMP overhead • Specific subsections have unneeded information
Jason Liptak Future • Calculations on more SNMP data • Memory • Interface speed • Processes • See SNMP overhead • Depends on targeted OIDs • Real test • Put in real world work loads and set up