1 Description: systemd units from upstream
2 Origin: upstream, 1.3.2
4 Index: nfs-utils-1.2.8/systemd/README
5 ===================================================================
7 +++ nfs-utils-1.2.8/systemd/README
10 +Notes about systemd unit files for nfs-utils.
12 +The unit files provided here should be sufficient for systemd
13 +to manage all daemons and related services provides by nfs-utils.
15 +They do *not* include any unit files for separate services such as
16 +rpc.rquotad (in the 'quota' package) or rpcbind.
18 +There are 4 units that can be 'enabled' or 'disabled' by systemctl, or
19 +by a suitable 'preset' setting:
22 + If enabled, nfs service is started together with dependencies
23 + such as mountd, statd, rpc.idmapd
24 + This is a "service" file rather than a "target" (which is the
25 + normal grouping construct) so that
26 + systemctl start nfs-server
27 + can work (if no type is given, ".service" is assumed).
30 + If enabled, daemons needs for an nfs client are enabled.
31 + This does *not* include rpc.statd. the rpc-statd.service unit
32 + is started by /usr/sbin/start-statd which mount.nfs will run
36 + If enabled, then blkmapd will be run when nfs-client.target is
39 +Another special unit is "nfs-utils.service". This doesn't really do
40 +anything, but exists so that other units may declare themselves as
41 +"PartOf" nfs-utils.service.
42 +The effect of this is that
43 + systemctl restart nfs-utils
44 +will restart all nfs-utils daemons as maybe be required during
45 +software update. It isn't possible to make
46 + systemctl try-restart nfs-server nfs-client.target
47 +do this as some daemon are included in both, and rpc.statd would
48 +not be restarted if nfs-server were not active (as nfs-client doesn't
49 +Want it - it is started by mount.nfs running start-statd).
51 +It is possible that we should have an nfs-statd.target which can
52 +selectively enable statd being stared by -server and sm-notify
53 +being started by -server or -client. That way it could be disabled
54 +completely on V4-only configurations. Currently statd is always
55 +started on the server and sm-notify is always run if server or
58 +Stopping nfs-server will also stop rpc.mountd, and rpc.svcgssd.
59 +It cannot stop rpc.statd or rpc.gssd as they may be in use by the
60 +client and systemd cannot specify is two-pronged reverse dependency.
61 +(i.e. stop this unit if none of these units are running)
63 +Distro specific commandline configuration can be provided by
64 +installing a script /usr/lib/systemd/scripts/nfs-utils_env.sh
65 +This should write /run/sysconfig/nfs-utils based on configuration
66 +information such as in /etc/sysconfig/nfs or /etc/defaults/nfs.
67 +It is run once by nfs-config.service.
69 +rpc.gssd and rpc.svcgssd are assumed to be needed if /etc/krb5.keytab
71 +If a site needs this file present but does not want the gss daemons
72 +running, it should create
73 + /etc/systemd/system/rpc-gssd.service.d/01-disable.conf
75 + /etc/systemd/system/rpc-svcgssd.service.d/01-disable.conf
80 Index: nfs-utils-1.2.8/systemd/auth-rpcgss-module.service
81 ===================================================================
83 +++ nfs-utils-1.2.8/systemd/auth-rpcgss-module.service
85 +# We want to start gss-proxy on kernels that support it and rpc.svcgssd
86 +# on those that don't. Those services check for support by checking
87 +# for existence of the path /proc/net/rpc/use-gss-proxy. Before they
88 +# can perform that check, they need this module loaded. (Unless
89 +# rpcsec_gss support is built directly into the kernel, in which case this
90 +# unit will fail. But that's OK.)
92 +Description=Kernel Module supporting RPCSEC_GSS
93 +Before=gssproxy.service rpc-svcgssd.service rpc-gssd.service
94 +Wants=gssproxy.service rpc-svcgssd.service rpc-gssd.service
95 +ConditionPathExists=/etc/krb5.keytab
99 +ExecStart=/sbin/modprobe -q auth_rpcgss
100 Index: nfs-utils-1.2.8/systemd/nfs-blkmap.service
101 ===================================================================
103 +++ nfs-utils-1.2.8/systemd/nfs-blkmap.service
106 +Description=pNFS block layout mapping daemon
107 +DefaultDependencies=no
108 +Conflicts=umount.target
109 +After=var-lib-nfs-rpc_pipefs.mount
110 +Requires=var-lib-nfs-rpc_pipefs.mount
112 +Requisite=nfs-blkmap.target
113 +After=nfs-blkmap.target
115 +PartOf=nfs-utils.service
119 +PIDFile=/var/run/blkmapd.pid
120 +ExecStart=/usr/sbin/blkmapd $BLKMAPDARGS
121 Index: nfs-utils-1.2.8/systemd/nfs-blkmap.target
122 ===================================================================
124 +++ nfs-utils-1.2.8/systemd/nfs-blkmap.target
127 +Description= PNFS blkmaping enablement.
128 +# If this target is enabled, then blkmapd will be started
129 +# as required. If it is not enabled it won't.
132 +WantedBy=remote-fs.target
133 +WantedBy=multi-user.target
134 \ No newline at end of file
135 Index: nfs-utils-1.2.8/systemd/nfs-client.target
136 ===================================================================
138 +++ nfs-utils-1.2.8/systemd/nfs-client.target
141 +Description=NFS client services
142 +Before=remote-fs-pre.target
143 +Wants=remote-fs-pre.target
145 +# Note: we don't "Wants=rpc-statd.service" as "mount.nfs" will arrange to
146 +# start that on demand if needed.
147 +Wants=nfs-blkmap.service rpc-statd-notify.service
148 +After=nfs-blkmap.service
150 +# GSS services dependencies and ordering
151 +Wants=auth-rpcgss-module.service
152 +After=rpc-gssd.service rpc-svcgssd.service gssproxy.service
155 +WantedBy=multi-user.target
156 +WantedBy=remote-fs.target
157 Index: nfs-utils-1.2.8/systemd/nfs-config.service
158 ===================================================================
160 +++ nfs-utils-1.2.8/systemd/nfs-config.service
163 +Description=Preprocess NFS configuration
168 +ExecStart=/usr/lib/systemd/scripts/nfs-utils_env.sh
169 Index: nfs-utils-1.2.8/systemd/nfs-idmapd.service
170 ===================================================================
172 +++ nfs-utils-1.2.8/systemd/nfs-idmapd.service
175 +Description=NFSv4 ID-name mapping service
176 +Requires=var-lib-nfs-rpc_pipefs.mount
177 +After=var-lib-nfs-rpc_pipefs.mount
179 +BindsTo=nfs-server.service
181 +Wants=nfs-config.service
182 +After=nfs-config.service
185 +EnvironmentFile=-/run/sysconfig/nfs-utils
187 +ExecStart=/usr/sbin/rpc.idmapd $RPCIDMAPDARGS
188 Index: nfs-utils-1.2.8/systemd/nfs-mountd.service
189 ===================================================================
191 +++ nfs-utils-1.2.8/systemd/nfs-mountd.service
194 +Description=NFS Mount Daemon
195 +Requires=proc-fs-nfsd.mount
196 +After=proc-fs-nfsd.mount
197 +After=network.target
198 +BindsTo=nfs-server.service
200 +Wants=nfs-config.service
201 +After=nfs-config.service
204 +EnvironmentFile=-/run/sysconfig/nfs-utils
206 +ExecStart=/usr/sbin/rpc.mountd $RPCMOUNTDARGS
207 Index: nfs-utils-1.2.8/systemd/nfs-server.service
208 ===================================================================
210 +++ nfs-utils-1.2.8/systemd/nfs-server.service
213 +Description=NFS server and services
214 +Requires= network.target proc-fs-nfsd.mount rpcbind.target
215 +Requires= nfs-mountd.service
216 +Wants=rpc-statd.service nfs-idmapd.service
217 +Wants=rpc-statd-notify.service
219 +After= network.target proc-fs-nfsd.mount rpcbind.target nfs-mountd.service
220 +After= nfs-idmapd.service rpc-statd.service
221 +Before= rpc-statd-notify.service
223 +# GSS services dependencies and ordering
224 +Wants=auth-rpcgss-module.service
225 +After=rpc-gssd.service gssproxy.service rpc-svcgssd.service
227 +Wants=nfs-config.service
228 +After=nfs-config.service
231 +EnvironmentFile=-/run/sysconfig/nfs-utils
235 +ExecStartPre=/usr/sbin/exportfs -r
236 +ExecStart=/usr/sbin/rpc.nfsd $RPCNFSDARGS
237 +ExecStop=/usr/sbin/rpc.nfsd 0
238 +ExecStopPost=/usr/sbin/exportfs -au
239 +ExecStopPost=/usr/sbin/exportfs -f
241 +ExecReload=/usr/sbin/exportfs -r
244 +WantedBy=multi-user.target
245 Index: nfs-utils-1.2.8/systemd/nfs-utils.service
246 ===================================================================
248 +++ nfs-utils-1.2.8/systemd/nfs-utils.service
251 +Description=NFS server and client services
252 +# This service should never be stopped, only restarted.
253 +# When it is re-started, all other services which declare
254 +# themselves to be "PartOf" this service will also be
256 +# systemctl restart nfs-utils
257 +# will restart all daemons which are part of nfs-utils
258 +# and which are running. This is useful after a software
261 +# This is a "service" rather than "target" so that we
262 +# don't need to say "systemctl restart nfs-utils.target".
267 Index: nfs-utils-1.2.8/systemd/proc-fs-nfsd.mount
268 ===================================================================
270 +++ nfs-utils-1.2.8/systemd/proc-fs-nfsd.mount
273 +Description=NFSD configuration filesystem
279 Index: nfs-utils-1.2.8/systemd/rpc-gssd.service
280 ===================================================================
282 +++ nfs-utils-1.2.8/systemd/rpc-gssd.service
285 +Description=RPC security service for NFS client and server
286 +DefaultDependencies=no
287 +Conflicts=umount.target
288 +Requires=var-lib-nfs-rpc_pipefs.mount
289 +After=var-lib-nfs-rpc_pipefs.mount
291 +ConditionPathExists=/etc/krb5.keytab
293 +PartOf=nfs-utils.service
295 +Wants=nfs-config.service
296 +After=nfs-config.service
299 +EnvironmentFile=-/run/sysconfig/nfs-utils
302 +ExecStart=/usr/sbin/rpc.gssd $GSSDARGS
303 Index: nfs-utils-1.2.8/systemd/rpc-statd-notify.service
304 ===================================================================
306 +++ nfs-utils-1.2.8/systemd/rpc-statd-notify.service
309 +Description=Notify NFS peers of a restart
310 +Requires=network-online.target
311 +After=network.target nss-lookup.target
313 +# if we run an nfs server, it needs to be running before we
314 +# tell clients that it has restarted.
315 +After=nfs-server.service
317 +PartOf=nfs-utils.service
319 +Wants=nfs-config.service
320 +After=nfs-config.service
323 +EnvironmentFile=-/run/sysconfig/nfs-utils
325 +ExecStart=-/usr/sbin/sm-notify $SMNOTIFYARGS
326 Index: nfs-utils-1.2.8/systemd/rpc-statd.service
327 ===================================================================
329 +++ nfs-utils-1.2.8/systemd/rpc-statd.service
332 +Description=NFS status monitor for NFSv2/3 locking.
333 +DefaultDependencies=no
334 +Conflicts=umount.target
335 +Requires=nss-lookup.target rpcbind.target
336 +After=network.target nss-lookup.target rpcbind.target
338 +PartOf=nfs-utils.service
340 +Wants=nfs-config.service
341 +After=nfs-config.service
344 +EnvironmentFile=-/run/sysconfig/nfs-utils
346 +PIDFile=/var/run/rpc.statd.pid
347 +ExecStart=/usr/sbin/rpc.statd --no-notify $STATDARGS
348 Index: nfs-utils-1.2.8/systemd/rpc-svcgssd.service
349 ===================================================================
351 +++ nfs-utils-1.2.8/systemd/rpc-svcgssd.service
354 +Description=RPC security service for NFS server
355 +Requires=var-lib-nfs-rpc_pipefs.mount
356 +After=var-lib-nfs-rpc_pipefs.mount
357 +PartOf=nfs-server.service
358 +PartOf=nfs-utils.service
360 +After=gssproxy.service
361 +ConditionPathExists=|!/run/gssproxy.pid
362 +ConditionPathExists=|!/proc/net/rpc/use-gss-proxy
363 +ConditionPathExists=/etc/krb5.keytab
365 +Wants=nfs-config.service
366 +After=nfs-config.service
369 +EnvironmentFile=-/run/sysconfig/nfs-utils
371 +ExecStart=/usr/sbin/rpc.svcgssd $SVCGSSDARGS
372 Index: nfs-utils-1.2.8/systemd/var-lib-nfs-rpc_pipefs.mount
373 ===================================================================
375 +++ nfs-utils-1.2.8/systemd/var-lib-nfs-rpc_pipefs.mount
378 +Description=RPC Pipe File System
379 +DefaultDependencies=no
380 +Conflicts=umount.target
384 +Where=/var/lib/nfs/rpc_pipefs