Note: "permalinks" may not be as permanent as we would like,
direct links of old sources may well be a few messages off.
Eugene Crosser wrote: > > Brett Bolen wrote: > > I would like to run High-Availability NFS on top of drbd, as in the > > drbd.org articles. > > > > What will happen when the first device fails, and the secondary > > takes over? Will I lose uncommitted data from the nfs clients? > > Will by apps need to be restarted ( if they have files open). > > <SNIP> > > Does /var/lib/nfs in a shared directory take care of these things? > > I've seen cases where the file system goes away ( without drbd), > > but the nfs clients continue to operated as if there was a > > file system ( nfs caching?). > > Unlike SMB, NFS server failover, when done carefully, is completely > transparent to the clients, that is, when a client was in the middle of > writing a file at the moment of failover, the operation will continue > after a pause and in the end you will get complete correct file. > > In theory. > > In practice there are some caveats. <SNIP> > Second, *if* you export shares for networks rathar than individual IP > addresses, you *must* have /var/lib/nfs symlinked (or mounted) onto > filesystem residing on DRBD device. Otherwise you will get EPERM errors > after failover, and will have to remount shares on the clients. > <SNIP> Having /var/lib/nfs on a DRBD device (or simlinked) is how the howto[2] showed it and works great, why would you not want to share this state information between the servers? There is another caveat to having the data shared over NFS, the NFS client-server protocol can allow data to be lost in a default configuration[1]. If your /etc/exports is using async (which is the default now) the server (the physical disk machine) will reply to the client that the data has been written to disk, however the NFS server software has not yet sent the data to the filesystem layer, this allows a race to exist between what the client thinks is on a disk and what is on the disk when power is killed. [1] please look at this thread http://lists.linbit.com/pipermail/drbd-user/2004-November/002278.html http://lists.linbit.com/pipermail/drbd-user/2004-November/002287.html http://lists.linbit.com/pipermail/drbd-user/2004-November/002292.html http://lists.linbit.com/pipermail/drbd-user/2004-November/002294.html [2] well at least the one that existed for 0.6.X. -- Todd Denniston Crane Division, Naval Surface Warfare Center (NSWC Crane) Harnessing the Power of Technology for the Warfighter