From owner-freebsd-net Thu Mar 18 18:22:35 1999 Delivered-To: freebsd-net@freebsd.org Received: from maxwell.syr.edu (maxwell.syr.edu [128.230.129.5]) by hub.freebsd.org (Postfix) with ESMTP id DF23B14BC9 for ; Thu, 18 Mar 1999 18:22:32 -0800 (PST) (envelope-from cmsedore@maxwell.syr.edu) Received: from exchange.maxwell.syr.edu (exchange.maxwell.syr.edu [128.230.129.241]) by maxwell.syr.edu (8.9.1a/8.9.1) with ESMTP id VAA25740 for ; Thu, 18 Mar 1999 21:10:12 GMT Received: by exchange.maxwell.syr.edu with Internet Mail Service (5.5.1960.3) id ; Thu, 18 Mar 1999 21:22:12 -0500 Message-ID: <262C3DA9BE0CD211971700A0C9B413A1CBD6@exchange.maxwell.syr.edu> From: Christopher Sedore To: "'freebsd-net@freebsd.org'" Subject: clustering/load balancing Date: Thu, 18 Mar 1999 21:22:12 -0500 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.1960.3) Content-Type: text/plain Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org OK, so I've worked some more on the IP clustering/load balancing stuff. I've hacked together a clustering daemon, and reworked the way that the kernel stuff is handled (it uses a flag and ipfw rules to do its thing). At this point, I'm looking for some people with a network and a few machines they don't care about, umm I mean would like to volunteer to test it. I'd like to avoid distributing this widely without getting at least one or two other people try it and get it to work. If you have two or three machines (or even 12 or 16 if you're really ambitious) to try it on, please drop me a note and we'll work out getting you the tarball of stuff. -Chris An excerpt of a draft readme which outlines functionality and what you need: Simple clustering for FreeBSD v0.1 ---------------------------------- This is a simple clustering system for FreeBSD. It does load balancing and has basic fault tolerance provisions. How it works: load balancing ---------------------------- The load balancing functionality is achieved by selecting hosts to service based on source IP address. This is done using some slight modifications to the FreeBSD kernel (ARP and IP code) to accomplish two things. First, the ARP code is modified in two ways. The first is that it is told to ignore IP address conflicts detected through ARP for flagged addresses. Second, ARP responses for flagged addresses are handled by looking them up in the system ARP table rather than using the ethernet address of the related card. Second, ip_input was modified to drop the multicast flag on incoming packets. To support the flagging, in.c was modified to allow you to set flags on the addresses. When the IA_SRCSELECT flag is set, it will also enable the reception of (all) multicast packets on that interface. These two modifications allow you to set up the same IP alias address (flagged for source selection) on multiple machines. Additionally, you can publish a multicast ethernet MAC address via each system's ARP table so an ARP lookup will yield a MAC address that will get the packet to each system. IP firewall rules are used to filter which packets are processed at each host. How it works: fault tolerance ----------------------------- I wrote a simple clustering daemon to create fault tolerance. The clustering system is completely distributed, provides automatic failover and rejoining capabilities, and makes a basic attempt at detecting and evicting cluster members that are dying off and then rejoining. The clustering system is quite basic and is based on simple UDP communication between hosts. Repitition is used to try to avoid reliability problems and should be adequate on a local ethernet. The clustering system has virtually no security features built in. It needs firewall protection to prevent external folks from mucking with it. Ideally it would be rewritten to have its own security, but not by me :). What is required? ----------------- The patches are from FreeBSD 3.1-RELEASE, so you'll need a box to which the patches will apply. I'd guess that they will apply to any relatively recent version of FreeBSD without much trouble if you don't have a 3.1 box handy. After applying the patches, you'll need to rebuild, and include IPFW in your kernel (I'd recommend that you use the IPFW option that allows everything by default if you don't have other plans for it--just to make things a little easier). You need interface cards with working multicast code. This eliminates the de cards. fxp (Intel) and ep (3com 3c5x9) cards are known to work. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message