echo "dev-libs/nss" >> /etc/portage/package.keywords echo "dev-libs/nss utils" >> /etc/portage/package.use emerge dev-libs/nss Heartbeat/Corosync/OpenAIS/Pacemaker export PREFIX=/usr/local export LCRSODIR=$PREFIX/libexec/lcrso export STACKS_SUPPORTED="--with-ais --without-heartbeat" Heartbeat: archive at http://hg.linux-ha.org/dev/archive/tip.tar.bz2 ./ConfigureMe bootstrap --prefix=$PREFIX make make install Corosync (>=1.0.0, only needed if using OpenAIS >= 1.0.0) : Get the latest corosync from SVN or pacemaker won't compile svn checkout http://svn.fedorahosted.org/svn/corosync/trunk corosync ./autogen.sh --prefix=$PREFIX ./configure --prefix=$PREFIX --with-lcrso-dir=$LCRSODIR make make install #cp init/generic /etc/init.d/corosync ln -s /usr/local/etc/corosync /etc/corosync echo "PKG_CONFIG_PATH=/usr/local/lib/pkgconfig" >> /etc/env.d/05pkg-config env-update source /etc/profile #OpenAIS (< 1.0.0) : #make PREFIX=$PREFIX LCRSODIR=$LCRSODIR #make install PREFIX=$PREFIX LCRSODIR=$LCRSODIR STATICLIBS=NO OpenAIS (>=1.0.0) : svn checkout http://svn.fedorahosted.org/svn/openais/trunk openais ./autogen.sh --prefix=$PREFIX ./configure --prefix=$PREFIX --with-lcrso-dir=$LCRSODIR make make install cp init/generic /etc/init.d/openais edit /etc/init.d/openais between lines 50 and 51 (before prog is executed), add a line: export COROSYNC_DEFAULT_CONFIG_IFACE="openaisserviceenable:openaisparser" add 21openais file to /etc/env.d: echo "LDPATH=\"/usr/local/lib/openais\"" >> /etc/env.d/21openais env-update source /etc/profile Pacemaker : wget http://hg.clusterlabs.org/pacemaker/stable-1.0/archive/tip.tar.bz2 ./ConfigureMe bootstrap --prefix=$PREFIX --with-lcrso-dir=$LCRSODIR $STACKS_SUPPORTED make make install LibLogThread from Cluster: wget https://fedorahosted.org/releases/c/l/cluster/cluster-3.0.0.tar.gz #./configure --openaisincdir=/usr/local/include --openaislibdir=/usr/local/lib/openais --enable_pacemaker ./configure --openaisincdir=/usr/local/include --openaislibdir=/usr/local/lib/openais --corosyncincdir=/usr/local/include --corosynclibdir=/usr/local/lib/corosync --enable_pacemaker cd common/liblogthread make make install DLM and friends: (after openais) : Download from http://sources.redhat.com/cluster/wiki/ download the latest DLM from GIT ./autogen.sh --prefix=/usr/local If the command does not work, you may need to modify configure.ac change AC_PREREQ([[2.63b]) to be AC_PREREQ([2.63]) comment out LT_PREREQ and LT_INIT ./configure --prefix=/usr/local --enable-pacemaker --disable-cman change line 68 of group/dlm_controld/pacemaker.c to be: log_error("Connection to our AIS plugin (%d) failed", PCMK_SERVICE_ID); make make install Setup LSB init scripts mkdir -p /lib/lsb cp init-functions /lib/lsb/ cp rc.status /lib/lsb ocfs2-tools 1.4.2+ ./autogen.sh --prefix=/usr/local in Config.make add -lpthread to COM_ERR_LIBS modify ./ocfs2_controld/Makefile set line: PCMK_INCLUDES = -I/usr/local/include/pacemaker -I/usr/local/include/heartbeat -I/usr/include/libxml2 $(GLIB_CFLAGS) modify ocfs2_controld/pacemaker.c: set line 158: log_error("Connection to our AIS plugin (%d) failed", PCMK_SERVICE_ID); make make install cd vendor/common #cp o2cb.init /etc/init.d/o2cb #cp ocfs2.init /etc/init.d/ocfs2 cp 51-ocfs2.rules /etc/udev/rules.d/ mkdir -p /usr/lib/ocf/resource.d/ocfs2 cp o2cb.ocf /usr/lib/ocf/resource.d/ocfs2/o2cb/ #copy http://oss.oracle.com/pipermail/ocfs2-devel/attachments/20081118/9c3e6005/attachment.obj # to /usr/lib/ocf/resource.d/ocfs2/o2cb #modify /usr/lib/ocf/resource.d/ocfs2/o2cb to point to the correct location of ocfs2_controld.pcmk # DAEMON="/sbin/ocfs2_controld.${OCF_RESKEY_stack}" #chmod a+x /usr/lib/ocf/resource.d/ocfs2/o2cb Note: The XML for the o2cb resource in pacemaker would be: STONITH device scripts are found in: /usr/local/lib/stonith/plugins/external