Developers guide
Chapter 8
Copyright © 2008-2013 Inverse inc.
Operating System Best Practices 67
∏ pf2 is the second PacketFence server
∏ PacketFence is properly configured on each server
∏ the DRBD partition is 30G long
∏ we use HeartBeat v1
Creation of the DRBD partition
During the OS installation, reduce the size of the main partition and create a new one (that will be used
for the replicated MySQL database) of 30G. In order to do so, on VolGroup00:
∏ leave at least 30G of drive space for a new partition. Do not create that partition during the install
process, we will do it later.
Partitioning
After the install, you need to create the extra partition for drbd. Using fdisk, create you new partition and
save the table. You will probably need to reboot your server after this step.
DRBD and Linux-HA Installation
CentOS 6
Download the drbd-8.3 and drbd-kmdl-*-8.3 RPMs from http://dl.atrpms.net/el6-x86_64/atrpms/stable/
(for 64bit) or http://dl.atrpms.net/el6-386/atrpms/stable/ (for 32bit).
Use the following line to install the required packages.
yum install ./drbd*.rpm heartbeat heartbeat-pils heartbeat-stonith
DRBD Configuration and setup
Caution
Initializing, configuring and troubleshooting DRBD is not straight forward! We strongly
recommend that you read the online documentation available on DRBD website so you
have a better idea about how it works.
Here we assume the name of the partition is mysql.
Load the DRBD kernel module:
modprobe drbd
Edit /etc/drbd.conf and put the following content: