FedFsNfsServer0.8

From Linux NFS

(Difference between revisions)
Jump to: navigation, search
(Created page with "== Project: fedfs-utils == [ Project Home | News | Downloads | Docs | [[FedFsUtilsMailingList...")
(Introduction)
 
(6 intermediate revisions not shown)
Line 13: Line 13:
== Introduction ==
== Introduction ==
-
This article describes how to configure a Linux NFS server to resolve junctionsOnce a file server can resolve junctions in its local file systems, it can participate in a FedFS domain.
+
A [[FedFsGlossary#Junction|junction]] is a link between two shared file systemsJunctions tie together disparate filesystems to create a [[FedFsGlossary#FedFs_Domain|FedFS domain]].
-
A ''[[FedFsGlossary#Junction|junction]]'' is a link between two shared file systems.  The two shared file systems may not reside on the same server.  There may be more than one replica of the linked-to shared file system, stored on several different file servers.  Each replica of the linked-to file system is called a ''[[FedFsGlossary#Location|location]]''.
+
A junction stores a list of [[FedFsGlossary#Location|locations]].  When a client attempts to access a junction, a file server must convert this list into a [[FedFsGlossary#Referral|referral]].  This is known as [[FedFsGlossary#Junction_Resolution|junction resolution]].
-
 
+
-
Junctions store a list of locations.  Each location in the list is represented as an export path paired with a server name or IP address.  When a file-access client encounters a junction, the file server (via a ''[[FedFsGlossary#Referral|referral]]'') provides the stored list of locations to the client, who chooses a location and mounts it.
+
-
 
+
-
A file server must convert the information stored in a junction into a list of locations that's in a format which is correct for the protocol clients are using to access the server (say, NFSv4)The server-side process of recognizing a junction and converting its contents is known as ''[[FedFsGlossary#Junction_Resolution|junction resolution]]''.
+
-
 
+
-
A single junction is useful for linking together two shared file systems.  A web of junctions can be used to create a namespace that crosses between multiple file systems on multiple file servers.  FedFS uses junctions for just such a purpose.
+
On Linux, a junction is denoted by a directory with special mode bits and an extended attribute that contains the junction location list.  The NFS server must convert a junction's location information into an NFSv4 referral which can be sent to NFS clients.
On Linux, a junction is denoted by a directory with special mode bits and an extended attribute that contains the junction location list.  The NFS server must convert a junction's location information into an NFSv4 referral which can be sent to NFS clients.
Line 27: Line 21:
When the Linux in-kernel NFS server encounters a junction, it resolves the junction by performing an upcall to mountd.  It is mountd that actually reads a junction and converts it to information that the kernel NFS server can put on the wire as an NFSv4 referral.
When the Linux in-kernel NFS server encounters a junction, it resolves the junction by performing an upcall to mountd.  It is mountd that actually reads a junction and converts it to information that the kernel NFS server can put on the wire as an NFSv4 referral.
-
== Installing or Building fedfs-utils ==
+
This article describes how to configure a Linux NFS server to resolve junctionsOnce a file server can resolve junctions in its local file systems, it can participate in a FedFS domain.
-
 
+
-
* [[FedFsUtilsBuild0.8|Installing or Building fedfs-utils-0.8]]
+
-
 
+
-
=== Additional instructions ===
+
-
 
+
-
Instead of installing the whole package, you may choose to install just the server componentsThe plug-in library:
+
-
 
+
-
# cd fedfs-utils-0.8/src/plug-ins ; make install
+
-
The header describing the library's API is needed to enable junction support while building nfs-utils:
+
== Build nfs-utils ==
-
  # cd fedfs-utils-0.8/src/include ; make install
+
On Fedora 18, rpc.mountd already has working junction resolution support. On other distributions, you'll need to build a version of rpc.mountd with working junction resolution support.
-
And finally, the "nfsref" command:
+
First, you'll need to install the nfs-plugin.h header.
-
# cd fedfs-utils-0.8/src/nfsref ; make install
+
* [[FedFsUtilsBuild0.8|Building fedfs-utils-0.8]]
-
=== Build nfs-utils ===
+
The "make install" step should install the header in /usr/include/nfs-plugin.h .  If not, you can find it in fedfs-utils-0.8/src/include/nfs-plugin.h and install it by hand.
Now download and unpack the latest nfs-utils tarball on the same system where you built fedfs-utils.  Build nfs-utils, and replace rpc.mountd on your NFS server.  The configure options are complicated;  I usually copy them from the latest nfs-utils RPM spec file from my distribution.
Now download and unpack the latest nfs-utils tarball on the same system where you built fedfs-utils.  Build nfs-utils, and replace rpc.mountd on your NFS server.  The configure options are complicated;  I usually copy them from the latest nfs-utils RPM spec file from my distribution.

Latest revision as of 16:30, 27 November 2012

Project: fedfs-utils

[ Project Home | News | Downloads | Docs | Mailing Lists | Source Control | Issues ]


Introduction

A junction is a link between two shared file systems. Junctions tie together disparate filesystems to create a FedFS domain.

A junction stores a list of locations. When a client attempts to access a junction, a file server must convert this list into a referral. This is known as junction resolution.

On Linux, a junction is denoted by a directory with special mode bits and an extended attribute that contains the junction location list. The NFS server must convert a junction's location information into an NFSv4 referral which can be sent to NFS clients.

When the Linux in-kernel NFS server encounters a junction, it resolves the junction by performing an upcall to mountd. It is mountd that actually reads a junction and converts it to information that the kernel NFS server can put on the wire as an NFSv4 referral.

This article describes how to configure a Linux NFS server to resolve junctions. Once a file server can resolve junctions in its local file systems, it can participate in a FedFS domain.

Build nfs-utils

On Fedora 18, rpc.mountd already has working junction resolution support. On other distributions, you'll need to build a version of rpc.mountd with working junction resolution support.

First, you'll need to install the nfs-plugin.h header.

The "make install" step should install the header in /usr/include/nfs-plugin.h . If not, you can find it in fedfs-utils-0.8/src/include/nfs-plugin.h and install it by hand.

Now download and unpack the latest nfs-utils tarball on the same system where you built fedfs-utils. Build nfs-utils, and replace rpc.mountd on your NFS server. The configure options are complicated; I usually copy them from the latest nfs-utils RPM spec file from my distribution.

$ ./configure yada yada
$ make
$ sudo install utils/mountd/mountd /usr/sbin/rpc.mountd

Then restart the NFS service.

# systemctl restart nfs-server.service
Personal tools