nfsd.1m revision c770959538dce966320e9b537c527f030e4a2822

The contents of this file are subject to the terms of the
Common Development and Distribution License (the "License").
You may not use this file except in compliance with the License.

You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
or http://www.opensolaris.org/os/licensing.
See the License for the specific language governing permissions
and limitations under the License.

When distributing Covered Code, include this CDDL HEADER in each
file and include the License file at usr/src/OPENSOLARIS.LICENSE.
If applicable, add the following below this CDDL HEADER, with the
fields enclosed by brackets "[]" replaced with your own identifying
information: Portions Copyright [yyyy] [name of copyright owner]


Copyright 1989 AT&T
Copyright (c) 2004, Sun Microsystems, Inc. All Rights Reserved
Copyright 2016 Nexenta Systems, Inc.

.Dd March 12, 2016 .Dt NFSD 1M .Os .Sh NAME .Nm nfsd .Nd NFS daemon .Sh SYNOPSIS .Nm /usr/lib/nfs/nfsd .Op Fl a .Op Fl c Ar max_conn .Op Fl l Ar listen_backlog .Op Fl p Ar protocol .Op Fl t Ar device .Op Ar nservers .Sh DESCRIPTION .Nm is the daemon that handles client file system requests. Only users with rq Sy PRIV_SYS_NFS and sufficient privileges to write to

a /var/run can run this daemon.

p The .Nm daemon is automatically invoked using .Xr share 1M with the .Fl a option.

p By default, .Nm starts over the TCP and UDP transports for versions 2 and 3. By default, it starts over the TCP for version 4. You can change this with the .Fl p option.

p A previously invoked .Nm daemon started with or without options must be stopped before invoking another .Nm command.

p See .Xr nfs 4 for available configuration properties for .Nm . .Ss Options The following options are supported: l -tag -width Ds t Fl a Start a NFS daemon over all available connectionless and connection-oriented transports, including UDP and TCP. Equivalent of setting the .Sy protocol property to .Sy all . t Fl c Ar max_conn Set the maximum number of connections allowed to the NFS server over connection-oriented transports. By default, the number of connections is unlimited. Equivalent of the .Sy max_connections property. t Fl l Set connection queue length for the NFS server over a connection-oriented transport. The default value is 32 entries. Equivalent of the .Sy listen_backlog property. t Fl p Ar protocol Start a NFS daemon over the specified protocol. Equivalent of the .Sy protocol property. t Fl t Ar device Start a NFS daemon for the transport specified by the given device. Equivalent of the .Sy device property. .El .Ss Operands The following operands are supported: l -tag -width Ds t Ar nservers This sets the maximum number of concurrent NFS requests that the server can handle. This concurrency is achieved by up to .Ar nservers threads created as needed in the kernel. .Ar nservers should be based on the load expected on this server. 16 is the usual number of .Ar nservers . If .Ar nservers is not specified, the maximum number of concurrent NFS requests will default to 1. Equivalent of the .Sy servers property. .El .Ss Usage If the .Sy nfs_portmon variable is set to non-zero value in

a /etc/system , then clients are required to use privileged ports

o ports < .Dv IPPORT_RESERVED

c to get NFS services. This variable is equal to zero by default. This variable has been moved from the .Qq nfs module to the .Qq nfssrv module. To set the variable, edit the

a /etc/system file and add this entry: d -literal -offset indent set nfssrv:nfs_portmon = 1 .Ed .Sh FILES l -tag -width Ds t Pa .nfsXXX Client machine pointer to an open-but-unlinked file. t Pa /etc/system System configuration information file. t Xo

a /var/nfs/v4_state

a /var/nfs/v4_oldstate .Xc Directories used by the server to manage client state information. These directories should not be removed. .El .Sh EXIT STATUS l -tag -width Ds t Sy 0 Daemon started successfully. t Sy 1 Daemon failed to start. .El .Sh SEE ALSO .Xr svcs 1 , .Xr mountd 1M , .Xr share 1M , .Xr sharectl 1M , .Xr sharemgr 1M , .Xr svcadm 1M , .Xr nfs 4 , .Xr sharetab 4 , .Xr system 4 , .Xr attributes 5 , .Xr smf 5 .Sh NOTES Manually starting and restarting .Nm is not recommended. If it is necessary to do so, use .Nm svcadm to enable or disable the nfs service

q svc:/network/nfs/server . If it is disabled, it will be enabled by .Xr share_nfs 1M , unless its .Sy application Ns / Ns Sy auto_enable property is set to .Sy false . See the , and .Xr svcadm 1M for more information.

p The .Nm service is managed by the service management facility, .Xr smf 5 , under the service identifier: d -literal -offset indent svc:/network/nfs/server .Ed

p Administrative actions on this service, such as enabling, disabling, or requesting restart, can be performed using .Xr svcadm 1M . The service's status can be queried using the .Xr svcs 1 command.

p If .Nm is killed with .Sy SIGTERM , it will not be restarted by the service management facility. Instead, .Nm can be restarted by other signals, such as .Sy SIGINT .