Tudor is a techie turned manager who fights like mad to keep his tech skills honed and relevant. Everything from web hosting, networking, *nix and the like. Constantly developing and co-ordinating with others to make the web a better (and easier to use) place.
Friday, 25th Feb 2011 Posted @ 14:06
After a couple of days off with the kids and missus and a morning of meetings, I thought I would finish off the pen config.
To recap: I have 2 RAQ3 boxes running Centos 4.8 running ucarp (alpha and beta). They also have Webmin installed with most services disabled apart from Denyhosts, mysqld, named, postfix and sshd
Incidentally, I found problems with running named on the carp address, so I added a exec /sbin/service named restart
to the vip-up script in /etc/sysconfig/carp/
directory, which fixed it neatly.
I have my PC with its DNS set to the carp address shared between alpha
and beta
and this fails over nicely, with nary a lookup failure. The next step was to get pen running.
yum install penSimple enough. Setting up a simple failover balancer is done thus:
pen 80 -C localhost:19000 www.hostname1.tld:80 www.hostname2.tld:80This sets up pen listening on port 80 (on all addresses including the carp address) and sends the first (and all subsequent requests from the same host) to www.hostname1.tld. The next (and subsequent) request that comes in from another host will be sent to www.hostname2.tld. I ran that on
alpha
and then beta
as well.[ no comments : Add ]