[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Re: Sendmail or Qmail ? ..

El vie, 05-03-2004 a las 12:56, Lucius Junevicus escribió:
> I saw your post on setting up qmail over drbd.  I would love to see
> how you did it.
> I'd like to create a how-to on setting up a hybrid cluster (open-mosix
> and drbd) for qmail.

Open Mosix? Isnt that like, autobalanced cluster? Interesting, how does
it help a smtp farm as opposed to simple load balancing?

> I'd love to know how you setup your cluster.
> What do your drbd.conf, ha.cf, haresources files look like?
> Which services do you have heartbeat control? (qmail, spamassassin, ?)
> I know your probably very busy, but any help would be greatly
> appreciated.

This is pretty straighforward.  A most mta's Qmail has configurable
queue directories and can deliver to maildirs anywhare as well (i use
vpopmail as delivery).

All you need is to set up your drbd partition as announced in drbd's
documentation (engeneer your disks, etc.). 

Our nodes look like this:

DELL 6250 PIV XEON 2.4gh DUal Processor 1GB ram
210GB RAID V SCSI storage

DELL 6250 PIV XEON2.4gh Single processor 1GB ram
210GB RAID V SCSI storage

Make a big partition, set up some symlinks to make important directories
reside in this partition (i named it data and its mounted on /data):

/var/qmail -> /data/var/qmail
/home/vpopmail -> /data/home/vpopmail
/webhostingpeople -> /data/webhostingpeople
/var/lib/mysql -> /data/var/lib/mysql
/etc/passwd -> /data/etc/passwd
/etc/group -> /data/etc/group 

.... etc.

HEre is the trick:

In the primary server:
Install (or mod) everything so that important services boot up without a
problem from files in this partition (already using the symlinks and

Make SHURE you profile every possible path of use that may be related to
file access creation, directory creation...etc.

In the secondary server:
Make a data partition
Make shure that data partition is absolutely exactly the same size of
the primary.

In the primary:
In init=1 (make shure all services are OFF) do:

tar cf --exclude-from exludedfiles /  | ssh -lroot secondary "tar xf /" 

In the file excludedfiles you should put /dev/ /var/log /var
...etc...anything that doesnt make sense putting in the failback node
(/proc, /sys).

This will snapshot the primary onto the secondary. Reboot the secondary,
all services should be on and working just as in the primary. If that is
the case, youre ready to roll.

Make the drbd magic you have to on the /data partition.... and youre
home free.

> Lucius

Reply to: