From owner-freebsd-cluster@FreeBSD.ORG Tue Aug 5 10:30:40 2008 Return-Path: Delivered-To: freebsd-cluster@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 61C191065677; Tue, 5 Aug 2008 10:30:40 +0000 (UTC) (envelope-from m.seaman@infracaninophile.co.uk) Received: from smtp.infracaninophile.co.uk (gate6.infracaninophile.co.uk [IPv6:2001:8b0:151:1::1]) by mx1.freebsd.org (Postfix) with ESMTP id 853D38FC0C; Tue, 5 Aug 2008 10:30:39 +0000 (UTC) (envelope-from m.seaman@infracaninophile.co.uk) Received: from happy-idiot-talk.infracaninophile.co.uk (localhost [IPv6:::1]) (authenticated bits=0) by smtp.infracaninophile.co.uk (8.14.2/8.14.2) with ESMTP id m75AUTVc063705; Tue, 5 Aug 2008 11:30:30 +0100 (BST) (envelope-from m.seaman@infracaninophile.co.uk) X-DKIM: Sendmail DKIM Filter v2.7.0 smtp.infracaninophile.co.uk m75AUTVc063705 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=infracaninophile.co.uk; s=200708; t=1217932232; bh=/RZcMCGvFeUyVj ckJ4nYj+SatBj1TniZmd0q8rgQ4fo=; h=Message-ID:Date:From:MIME-Version: To:CC:Subject:References:In-Reply-To:Content-Type:Cc:Content-Type: Date:From:In-Reply-To:Message-ID:Mime-Version:References:To; z=Mes sage-ID:=20<48982BBE.5060502@infracaninophile.co.uk>|Date:=20Tue,=2 005=20Aug=202008=2011:30:22=20+0100|From:=20Matthew=20Seaman=20|Organization:=20Infracaninophile|User -Agent:=20Thunderbird=202.0.0.16=20(X11/20080726)|MIME-Version:=201 .0|To:=20Rudi=20Kramer=20-=20MWEB=20|CC:=20Michae l=20Christie=20,=20=0D=0A=20freebsd-quest ions@freebsd.org,=20freebsd-cluster@freebsd.org|Subject:=20Re:=20Hi gh=20Availability=20FreeBSD=20www=20cluster|References:=20<4898065A .5080008@powerzone.net.au>=20<39DC135F7F0571489196E0B6F5D58B4A03B45 FC9@MWBEXCH.mweb.com>|In-Reply-To:=20<39DC135F7F0571489196E0B6F5D58 B4A03B45FC9@MWBEXCH.mweb.com>|X-Enigmail-Version:=200.95.6|Content- Type:=20multipart/signed=3B=20micalg=3Dpgp-sha256=3B=0D=0A=20protoc ol=3D"application/pgp-signature"=3B=0D=0A=20boundary=3D"----------- -enigB2045A7DE69EC70AE914C385"; b=Q2lGAymLeXZyTyfOOiFJ64zp8uyUBRY6V Ax4gXh3r8hXmfsdOf3g0/ha0xSNfDpebBRdU1LUsGeHk0b4F0kDtUMyiWZVmZXnfjbL ee7GBhLShOsnxZP6ZIziff8UMsUZ8DVRAwUxeC1zD7vpllkP9exfnoMnBiCWl/1LXV4 zChM= Message-ID: <48982BBE.5060502@infracaninophile.co.uk> Date: Tue, 05 Aug 2008 11:30:22 +0100 From: Matthew Seaman Organization: Infracaninophile User-Agent: Thunderbird 2.0.0.16 (X11/20080726) MIME-Version: 1.0 To: Rudi Kramer - MWEB References: <4898065A.5080008@powerzone.net.au> <39DC135F7F0571489196E0B6F5D58B4A03B45FC9@MWBEXCH.mweb.com> In-Reply-To: <39DC135F7F0571489196E0B6F5D58B4A03B45FC9@MWBEXCH.mweb.com> X-Enigmail-Version: 0.95.6 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="------------enigB2045A7DE69EC70AE914C385" X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.0 (smtp.infracaninophile.co.uk [IPv6:::1]); Tue, 05 Aug 2008 11:30:32 +0100 (BST) X-Virus-Scanned: ClamAV 0.93.3/7941/Mon Aug 4 23:44:27 2008 on happy-idiot-talk.infracaninophile.co.uk X-Virus-Status: Clean X-Spam-Status: No, score=-3.0 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VERIFIED,NO_RELAYS autolearn=ham version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on happy-idiot-talk.infracaninophile.co.uk Cc: freebsd-questions@freebsd.org, freebsd-cluster@freebsd.org Subject: Re: High Availability FreeBSD www cluster X-BeenThere: freebsd-cluster@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Clustering FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 05 Aug 2008 10:30:40 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigB2045A7DE69EC70AE914C385 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Rudi Kramer - MWEB wrote: > Michael Christie: >=20 >> I want to cluster some freeBSD servers, The purpose of this is to >> learn. I would like to run some basic services like www and mail on > a >> test network. I would like to set up the servers so if one server > falls >> over the other will take over the services automatically, load >> balanceing would be good as well. I have googled, I could be looking > in >> the wrong place , there seems not to be much in regard to seting up >> freebsd in a cluster, lots on linux. I have looked at the High >> Availability Linux project , I see on the front page that it will run > on >> freebsd. >> >> So I am a bit lost and i am wanting to learn how to cluster freebsd > web >> and mail servers, I have looked at Beowulf clusters, which seem to > give >> computers more grunt, Can some on on the list please advise me on what= >> clustering softwhere i need to get started and if the High > Availability >> Linux project softwhere will do the job. >=20 > I also did some research a while ago and found Wackamole. It looks > pretty interesting as you don't need a central "director" server but al= l > servers in the cluster check each other. It's also in the ports tree :-= ) >=20 > Site: http://www.backhand.org/wackamole/=20 > Port: /usr/ports/net/wackamole There's clustering and clustering. Neither of the two applications the OP mentioned needs anything like as tight a coupling as what many com= mercial 'cluster' solutions provide, or that compute-cluster solutions like Beowulf or Grid Engine[!] provide. WWW clustering requires two things: * A means to detect failed / out of service machines and=20 redirect traffic to alternative servers * A means to delocalize user sessions between servers The first requirement can be handled with programs already mentioned such as wackamole/spread or hacluster -- or another alternative is=20 hoststated(8)[*] on OpenBSD. You can use mod_proxy_balancer[+] on recent= =20 Apache 2.2.x to good effect. Certain web technologies provide this sort of capability directly: eg. mod_jk or the newer mod_proxy_ajp13 modules for apache can balance traffic across a number of back-end tomcat= =20 workers: of course this only applies to sites written in Java. If you're dealing with high traffic levels and have plenty of money to=20 spend, then a hardware load balancer (Cisco Arrowpoint, Alteon Acedirecto= r,=20 Foundry ServerIron etc.) is a pretty standard choice. The second requirement is more subtle. Any reasonably complicated web application nowadays is unlikely to completely stateless. Either you have to recognise each session and direct the traffic back to the same server each time, or you have to store the session state in a way that is accessible to all servers -- typically in a back-end database.=20 Implementing 'sticky sessions' is generally slightly easier in terms of=20 application programming, but less resilient to machine failure. There are other alternatives: Java Servlet based applications running under Apache Tomcat can cluster about 4 machines together so that session state is replicated to all of them. This solution is however not at all scalable beyond 4 machines, as they'll quickly spend more time passin= g state information between themselves than they do actually serving incomi= ng=20 web queries. Mail clustering is an entirely different beast. In fact, it's two different beasts with entirely different characteristics. The easy part with mail is the MTA -- SMTP has built in intrinsic concept= s=20 of fail-over and retrying with alternate servers. Just set up appropriat= e=20 MX records in the DNS pointing at a selection of servers and it all shoul= d=20 work pretty much straight away. You may need to share certain data betwe= en=20 your SMTP servers (like greylisting status, Bayesian spam filtering,=20 authentication databases) but the software is generally written with this= =20 capability built in. The hard part with mail clustering is the mail store which provides the IMAP or POP3 or WebMail interface to allow users to actually read their=20 mail. To my knowledge there is no freely available opensource solution that provides an entirely resilient IMAP/POP3 solution. Cyrus Murder comes close, in that it provides multiple back-end mail stores, easy=20 migration of mailboxes between stores and resilient front ends. The=20 typical approach here is to use a high-spec server with RAIDed disk=20 systems, multiple PSUs etc. and to keep very good backups. Cheers, Matthew [!] http://gridengine.sunsource.net/ [*] hoststated(8) integrates with the traffic redirection capabilities of= =20 pf(4) to provide pretty much the same sort of functionality as a hardware= =20 loadbalancer via a firewall machine, but a lot cheaper. http://www.openbsd.org/cgi-bin/man.cgi?query=3Dhoststated&sektion=3D8&for= mat=3Dhtml [+] http://httpd.apache.org/docs/2.2/mod/mod_proxy_balancer.html --=20 Dr Matthew J Seaman MA, D.Phil. 7 Priory Courtyard Flat 3 PGP: http://www.infracaninophile.co.uk/pgpkey Ramsgate Kent, CT11 9PW --------------enigB2045A7DE69EC70AE914C385 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (FreeBSD) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iEYEAREIAAYFAkiYK8QACgkQ8Mjk52CukIwkFQCfWwG7YY4ppoeDwgk3ZzGirEK3 spwAn1S6/S6tSYdVLBQ2oe1POhS8E9iE =rD0E -----END PGP SIGNATURE----- --------------enigB2045A7DE69EC70AE914C385--