[CentOS] Heartbeat and mount --bind for NFS v4.

Wed Feb 8 12:51:42 UTC 2006
Will McDonald <wmcdonald at gmail.com>

Hi all.

This is probably more of a HA list, or possibly even linux-practices,
question but all hosts concerned are running CentOS and I reckon some
of you guys might have some good suggestions. Feel free to tell me to
piss off. :)

I'm building a new CentOS, DRBD, Heartbeat and NFS HA cluster. We
already have boxes running similar setups on FC2/3 running NFS v2/3
with the Ultra Monkey Heartbeat packages. These new systems are using
CentOS packages as much as possible.

[root at tempmailstore1a ha.d]# rpm -qa | grep -Ei 'heartbeat|drbd'

I'm messing around with NFS v4 (any and all experience/horror stories
about EL4's NFS v4 in production environments more than welcome as I'm
still at the evaluation/test stage) and looking at the best way to
setup the --bind mounts for the NFS v4 pseudofilesystem.

So far in /etc/ha.d/haresources I have...

tempmailstore1a IPaddr::                                 
        drbddisk::r0                                                           \
        Filesystem::/dev/drbd0::/mnt/drbd::ext3::rw,acl,data=journal    \
        portmap                                                                \
        nfslock                                                                \
        nfs                                                                    \

Now, after the Filesystem resource.d script's called ideally I'd like
to setup the --bind mounts as detailed here...


As follows...

mount --bind /mnt/drbd /export/drbd

I would've thought the best way to achieve this, since it's
effectively another filesystem of type "none" when mounted would be
with the resource.d/Filesystem script... which can't take a --mount

Obviously I can hack around in the shell script or write my own, has
anyone else bumped up against this? And how did you deal with it.