Hi, Thanks to all input, I finally managed to get a working NFS cluster using the exportfs RA and works like it should. Only i HAVE to mount the nfs share using UDP, because when I mount using TCP the connection is not reinstated after a failover. Is there a workaround for this so I can use TCP? What is the advantage/disadvantage of using UDP vs TCP for the mount?
Kind regards, Caspar Smit 2011/3/22 RaSca <[email protected]> > Il giorno Mar 22 Mar 2011 15:11:34 CET, Caspar Smit ha scritto: > > Thanks for this, but I don't see any portmap, nfs-common and/or >> nfs-kernel-server lsb scripts used in that article. >> That was just the part I was interested in :) >> Kind regards >> Caspar Smit >> > > You're absolutely right :-) Take a look at this configuration: > > node ubuntu-nodo1 > node ubuntu-nodo2 > primitive drbd0 ocf:linbit:drbd \ > params drbd_resource="r0" \ > op monitor interval="20s" timeout="40s" \ > meta target-role="started" > primitive drbd1 ocf:linbit:drbd \ > params drbd_resource="r1" \ > op monitor interval="20s" timeout="40s" > primitive nfs-kernel-server lsb:nfs-kernel-server \ > op monitor interval="10s" timeout="30s" > primitive ping ocf:pacemaker:ping \ > params host_list="172.16.0.1" multiplier="100" name="ping" \ > op monitor interval="20s" timeout="60s" \ > op start interval="0" timeout="60s" > primitive portmap lsb:portmap \ > op monitor interval="10s" timeout="30s" > primitive share-a-exportfs ocf:heartbeat:exportfs \ > params directory="/share-a" clientspec="172.16.0.0/24" > options="rw,async,no_subtree_check,no_root_squash" fsid="1" \ > op monitor interval="10s" timeout="30s" \ > op start interval="0" timeout="40s" \ > op stop interval="0" timeout="40s" \ > meta is-managed="true" target-role="started" > primitive share-a-fs ocf:heartbeat:Filesystem \ > params device="/dev/drbd0" directory="/share-a" fstype="ext3" > options="noatime" fast_stop="no" \ > op monitor interval="20s" timeout="40s" \ > op start interval="0" timeout="60s" \ > op stop interval="0" timeout="60s" \ > meta is-managed="true" target-role="started" > primitive share-a-ip ocf:heartbeat:IPaddr2 \ > params ip="172.16.0.63" nic="eth0" \ > op monitor interval="20s" timeout="40s" \ > meta is-managed="true" target-role="started" > primitive share-b-exportfs ocf:heartbeat:exportfs \ > params directory="/share-b" clientspec="172.16.0.0/24" > options="rw,no_root_squash" fsid="2" \ > op monitor interval="10s" timeout="30s" \ > op start interval="0" timeout="40s" \ > op stop interval="0" timeout="40s" \ > meta target-role="started" > primitive share-b-fs ocf:heartbeat:Filesystem \ > params device="/dev/drbd1" directory="/share-b" fstype="ext3" > options="noatime" fast_stop="no" \ > op monitor interval="20s" timeout="40s" \ > op start interval="0" timeout="60s" \ > op stop interval="0" timeout="60s" \ > meta target-role="started" > primitive share-b-ip ocf:heartbeat:IPaddr2 \ > params ip="172.16.0.64" nic="eth0" \ > op monitor interval="20s" timeout="40s" \ > meta target-role="started" > primitive statd lsb:statd \ > op monitor interval="10s" timeout="30s" > group nfs portmap statd nfs-kernel-server > group share-a share-a-fs share-a-exportfs share-a-ip > group share-b share-b-fs share-b-exportfs share-b-ip > ms ms_drbd0 drbd0 \ > meta master-max="1" master-node-max="1" clone-max="2" > clone-node-max="1" notify="true" > ms ms_drbd1 drbd1 \ > meta master-max="1" master-node-max="1" clone-max="2" > clone-node-max="1" notify="true" target-role="Started" > clone nfs_clone nfs \ > meta globally-unique="false" > clone ping_clone ping \ > meta globally-unique="false" > location share-a_on_connected_node share-a \ > rule $id="share-a_on_connected_node-rule" -inf: not_defined ping or > ping lte 0 > location share-b_on_connected_node share-b \ > rule $id="share-b_on_connected_node-rule" -inf: not_defined ping or > ping lte 0 > colocation share-a_on_ms_drbd0 inf: share-a ms_drbd0:Master > colocation share-b_on_ms_drbd1 inf: share-b ms_drbd1:Master > order share-a_after_ms_drbd0 inf: ms_drbd0:promote share-a:start > order share-b_after_ms_drbd1 inf: ms_drbd1:promote share-b:start > property $id="cib-bootstrap-options" \ > dc-version="1.0.8-042548a451fce8400660f6031f4da6f0223dd5dd" \ > cluster-infrastructure="openais" \ > expected-quorum-votes="2" \ > no-quorum-policy="ignore" \ > stonith-enabled="false" \ > last-lrm-refresh="1300276063" > > I omitted the nfs server part in my article because explaining also that > part would make the article even longer... > > Bye, > > > -- > RaSca > Mia Mamma Usa Linux: Niente รจ impossibile da capire, se lo spieghi bene! > [email protected] > http://www.miamammausalinux.org > > _______________________________________________ Linux-HA mailing list [email protected] http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
