1rpc.mountd(8) System Manager's Manual rpc.mountd(8)
2
3
4
6 rpc.mountd - NFS mount daemon
7
9 /usr/sbin/rpc.mountd [options]
10
12 The rpc.mountd program implements the NFS mount protocol. When receiv‐
13 ing a MOUNT request from an NFS client, it checks the request against
14 the list of currently exported file systems. If the client is permitted
15 to mount the file system, rpc.mountd obtains a file handle for
16 requested directory and returns it to the client.
17
18 Exporting NFS File Systems
19 Making file systems available to NFS clients is called exporting.
20
21 Usually, a file system and the hosts it should be made available to are
22 listed in the /etc/exports file, and invoking exportfs -a whenever the
23 system is booted. The exportfs(8) command makes export information
24 available to both the kernel NFS server module and the rpc.mountd dae‐
25 mon.
26
27 Alternatively, you can export individual directories temporarily using
28 exportfs's host:/directory syntax.
29
30 The rmtab File
31 For every mount request received from an NFS client, rpc.mountd adds an
32 entry to the /var/lib/nfs/rmtab file. When receiving an unmount
33 request, that entry is removed.
34
35 However, this file is mostly ornamental. One, the client can continue
36 to use the file handle even after calling rpc.mountd 's UMOUNT proce‐
37 dure. And two, if a client reboots without notifying rpc.mountd , a
38 stale entry will remain in rmtab.
39
41 -d kind or --debug kind
42 Turn on debugging. Valid kinds are: all, auth, call, general and
43 parse.
44
45 -F or --foreground
46 Run in foreground (do not daemonize)
47
48 -f or --exports-file
49 This option specifies the exports file, listing the clients that
50 this server is prepared to serve and parameters to apply to each
51 such mount (see exports(5)). By default, export information is
52 read from /etc/exports.
53
54 -h or --help
55 Display usage message.
56
57 -o num or --descriptors num
58 Set the limit of the number of open file descriptors to num. The
59 default is to leave the limit unchanged.
60
61 -N or --no-nfs-version
62 This option can be used to request that rpc.mountd do not offer
63 certain versions of NFS. The current version of rpc.mountd can
64 support both NFS version 2 and the newer version 3. If the NFS
65 kernel module was compiled without support for NFSv3, rpc.mountd
66 must be invoked with the option --no-nfs-version 3 .
67
68 -n or --no-tcp
69 Don't advertise TCP for mount.
70
71 -P Ignored (compatibility with unfsd??).
72
73 -p or --port num
74 Force rpc.mountd to bind to the specified port num, instead of
75 using the random port number assigned by the portmapper.
76
77 -H or --ha-callout prog
78 Specify a high availability callout program, which will receive
79 callouts for all client mount and unmount requests. This allows
80 rpc.mountd to be used in a High Availability NFS (HA-NFS) envi‐
81 ronment. This callout is not needed (and should not be used)
82 with 2.6 and later kernels (instead, mount the nfsd filesystem
83 on /proc/fs/nfsd ). The program will be called with 4 argu‐
84 ments. The first will be mount or unmount depending on the rea‐
85 son for the callout. The second will be the name of the client
86 performing the mount. The third will be the path that the
87 client is mounting. The last is the number of concurrent mounts
88 that we believe the client has of that path.
89
90 -P, --state-directory-path directory
91 specify a directory in which to place statd state information.
92 If this option is not specified the default of /var/lib/nfs is
93 used.
94
95 -r, --reverse-lookup
96 mountd tracks IP addresses in the rmtab, and when a DUMP request
97 is made (by someone running showmount -a, for instance), it
98 returns IP addresses instead of hostnames by default. This
99 option causes mountd to do a reverse lookup on each IP address
100 and return that hostname instead. Enabling this can have a sub‐
101 stantial negative effect on performance in some situations.
102
103 -t N or --num-threads=N
104 This option specifies the number of worker threads that
105 rpc.mountd spawns. The default is 1 thread, which is probably
106 enough. More threads are usually only needed for NFS servers
107 which need to handle mount storms of hundreds of NFS mounts in a
108 few seconds, or when your DNS server is slow or unreliable.
109
110 -V or --nfs-version
111 This option can be used to request that rpc.mountd offer certain
112 versions of NFS. The current version of rpc.mountd can support
113 both NFS version 2 and the newer version 3.
114
115 -v or --version
116 Print the version of rpc.mountd and exit.
117
118 -g or --manage-gids
119 Accept requests from the kernel to map user id numbers into
120 lists of group id numbers for use in access control. An NFS
121 request will normally (except when using Kerberos or other cryp‐
122 tographic authentication) contains a user-id and a list of
123 group-ids. Due to a limitation in the NFS protocol, at most 16
124 groups ids can be listed. If you use the -g flag, then the list
125 of group ids received from the client will be replaced by a list
126 of group ids determined by an appropriate lookup on the server.
127 Note that the 'primary' group id is not affected so a newgroup
128 command on the client will still be effective. This function
129 requires a Linux Kernel with version at least 2.6.21.
130
131
133 This rpc.mountd version is protected by the tcp_wrapper library. You
134 have to give the clients access to rpc.mountd if they should be allowed
135 to use it. To allow connects from clients of the .bar.com domain you
136 could use the following line in /etc/hosts.allow:
137
138 mountd: .bar.com
139
140 You have to use the daemon name mountd for the daemon name (even if the
141 binary has a different name).
142
143 For further information please have a look at the tcpd(8) and
144 hosts_access(5) manual pages.
145
146
148 rpc.nfsd(8), exportfs(8), exports(5), rpc.rquotad(8).
149
151 /etc/exports, /var/lib/nfs/xtab.
152
154 Olaf Kirch, H. J. Lu, G. Allan Morris III, and a host of others.
155
156
157
158 31 Aug 2004 rpc.mountd(8)