"Fossies" - the Fresh Open Source Software Archive 
Member "freeha-1.0/HEARTBEATS" (23 Nov 2006, 1867 Bytes) of package /linux/privat/old/freeha-1.0.tar.gz:
As a special service "Fossies" has tried to format the requested text file into HTML format (style:
standard) with prefixed line numbers.
Alternatively you can here
view or
download the uninterpreted source code file.
1 Quickie overview of how 'heartbeats' work for freeha:
2
3 You should set up multiple networks between the machines in the cluster
4 (2 networks minimum) , on at least 2 separate interfaces per machine, so
5 that they can tell each other what is going on.
6
7 freeha takes advantage of standard IP 'broadcast' definitions, to send a UDP
8 broadcast packet to all the machines on the heartbeat subnet, with a single
9 packet. This 'heartbeat' packet is sent by each cluster machine every second.
10 That is good, in that it easily allows for multiple machines in standby mode
11 in the cluster. It is "bad", if you happen to be sharing the network with
12 other machines.
13
14 Ideally, you will use dedicated interfaces with private switches, or
15 direct-connect crossover cables, for this. However, it is just as easy to use
16 existing network interfaces, and allocate additional virtual interfaces for
17 them.
18
19 Remember that every machine plugged into the same switch will still see all
20 broadcast traffic, unless you configure the switch to keep the private address
21 range traffic to the appropriate slots on the switch.
22
23
24
25 There are standard 'private' network address ranges that can be used, so that
26 you can allocate networks solely for use between cluster machines.
27
28 Examples of 'reserved networks' appropriate for this use:
29
30 192.168.1.0, 192.168.2.0, 192.168.3.0, and so on.
31
32
33 It is up to YOU, the sysadmin, to ensure that only cluster machines are on
34 that subnet. If there are other machines on the same subnet, they will see a
35 lot of 'garbage' traffic. That is why it is best to use 'private' addresses
36 for heatbeats.
37
38
39 If you are running out of secondary network interfaces, you might choose
40 to use a free serial port in a two-machine cluster, and set up PPP across
41 the serial ports. This should work just as well.
42
43
44 See the 'INSTALL' text file for a specific sample network configuration.