Commit Graph

57 Commits

Author SHA1 Message Date
delphij
d6d53b5cee ANSI'fy nfsd(8) and some minor changes to make it WARNS=6 clean.
This commit does not affect the code generated, as proven by md5'ing
resulting binaries.

Bump WARNS accordingly.

Compiled on:	sparc64, ia64, i386
Reviewed by:	alfred (but blame me if anything goes wrong :-)
2004-11-06 18:15:44 +00:00
imp
9fbed704d5 Per letter dated July 22, 1999 remove 3rd clause of Berkeley derived software
(with permission of addtional copyright holders where appropriate)
2004-08-07 04:28:56 +00:00
ru
6294018a20 Mechanically kill hard sentence breaks. 2004-07-02 23:13:00 +00:00
simon
235edc76a6 Add a cross reference to exports(5). While exports is not directly
tied to nfsd(8), exports is the configuration file users will most
likely need to configure when dealing with a NFS server.

Submitted by:	Florian Hars <hars@bik-gmbh.de>
PR:		docs/64714
MFC after:	3 days
2004-03-30 20:43:07 +00:00
rwatson
6f9fb3945a Problem:
When an NFS server is port-scanned nfsd sometimes exits. This has
  happened 3 times the last few weeks.

  Nfsd has been written to exit when accept(2) fails. Unfortunately
  accept can sometimes make a "normal" return with errno ECONNABORTED
  and in this case nfsd exits prematurely.

Solution:

  Check for ECONNABORTED (and also EINTR, since nfsd uses signals)
  and continue.

Submitted by:	Bjoern Groenvall <bg@sics.se>
PR:		61084
2004-01-11 01:29:03 +00:00
obrien
a920d12f89 style.Makefile(5) 2003-04-04 17:49:21 +00:00
mux
90e875280c Update manpage to match the code, vfsload() is not used
here since some time, kldload() is used instead.
2002-08-11 15:19:49 +00:00
peter
0168549826 Bah, I forgot to commit this part of the nfssvc() cleanup. Sorry folks. 2002-07-25 06:18:22 +00:00
ume
9c2c51a1e6 use IPV6_V6ONLY instead of non standard IPV6_BINDV6ONLY.
MFC after:	1 week
2002-07-22 15:22:53 +00:00
kan
751552f6c8 Initialize sockbits variable with FD_ZERO, to avoid passing a fd_set
with random garbage in lower bits corresponding to stdin, stdout and
stderr to select(2).

This fixes the problem with nfsd sometimes getting stuck in a tight
select(2) loop eating 100% CPU time.

Reviewed by:	iedowse
Approved by:	obrien
2002-07-22 14:01:44 +00:00
charnier
a2accd01f0 The .Nm utility 2002-07-06 19:34:18 +00:00
gordon
739d7b5c19 Fix spelling nit in error message. 2002-06-05 01:06:33 +00:00
peter
c6d2a0b342 Make this compile and not segfault on ia64. ptr = strdup("foo"); is
fatal if the declaration of strdup() isn't in scope.  The upper 32 bits
of the pointer are lost since it defaults to returning "int".  Fix some
warnings while here, including trying to make gcc-3.1 happy.
2002-05-01 06:49:43 +00:00
pb
f0ab132d69 Fix problem in macro definition breaking compiles with -DDEBUG.
PR:		bin/35773
Submitted by:	Thomas Quinot <thomas@cuivre.fr.eu.org>
2002-03-26 17:37:59 +00:00
obrien
9baf2f1b03 Default to WARNS=2.
Binary builds that cannot handle this must explicitly set WARNS=0.

Reviewed by:	mike
2001-12-04 02:19:58 +00:00
iedowse
6feb6a4c15 When nfsd was started with only UDP servers, the master nfsd would
spin in a loop eating CPU time. This bug has existed since the
TI-RPC import. The problem is that we should only enter the select
loop if at least one TCP server was started.  Fix this by having
the master nfsd become a UDP server itself if there are no TCP
servers.

Also improve/correct the code for cleaning up slave nfsd processes
and unregistering with rpcbind when the master nfsd exits.

One issue that remains open is that if a slave nfsd dies, then all
nfsds will shut down. This is because nfssvc() in the master nfsd
returns 0 when the master nfsd receives a SIGCHLD.

Submitted by:	tmm
2001-10-16 21:55:53 +00:00
peter
5f4236f763 Deal with nfs server module changes for autoloading. 2001-09-20 02:18:06 +00:00
peter
68a5e33921 Userland part of nfs client/server split and cleanup. 2001-09-18 23:34:44 +00:00
ru
bde8ec1b70 mdoc(7) police: utilize the new .Ex macro. 2001-08-15 09:09:47 +00:00
dd
a145482cf6 Remove whitespace at EOL. 2001-07-15 07:53:42 +00:00
ru
05e503d80a mdoc(7) police: sort SEE ALSO xrefs (sort -b -f +2 -3 +1 -2). 2001-07-06 16:46:48 +00:00
ru
86642a4ab4 - Backout botched attempt to introduce MANSECT feature.
- MAN[1-9] -> MAN.
2001-03-26 14:33:27 +00:00
alfred
c5d3e9426c Don't call daemon() and setup our signal handlers until after we check
and do the unregister/reregister work.

Don't call syslog in the unregister/reregister code as we haven't called
openlog() yet.

Be a more conservative about accepting errno values from socket(2),
only EPROTONOSUPPORT means that the kernel isn't supporting it
something like INET6.  The other possible errnos would be returned
if there was a mistake in the socket(2) call so remove them from the
list of "acceptable" return values.
2001-03-25 23:32:55 +00:00
alfred
20ed2193f0 Disable ipv6 when getnetconfigent("udp6"/"tcp6") fails.
Submitted by: Martin Blapp <mb@imp.ch>
2001-03-25 23:28:03 +00:00
ru
56b5d7535b Set the default manual section for sbin/ to 8. 2001-03-20 18:13:31 +00:00
ru
acc35dc185 mdoc(7) police: fixes to the previous revision:
- fixed bad formatting
- avoid using German
- removed hard sentence break
2001-03-20 10:57:25 +00:00
alfred
f67e4a8fc7 Bring in a hybrid of SunSoft's transport-independent RPC (TI-RPC) and
associated changes that had to happen to make this possible as well as
bugs fixed along the way.

  Bring in required TLI library routines to support this.

  Since we don't support TLI we've essentially copied what NetBSD
  has done, adding a thin layer to emulate direct the TLI calls
  into BSD socket calls.

  This is mostly from Sun's tirpc release that was made in 1994,
  however some fixes were backported from the 1999 release (supposedly
  only made available after this porting effort was underway).

  The submitter has agreed to continue on and bring us up to the
  1999 release.

  Several key features are introduced with this update:
    Client calls are thread safe. (1999 code has server side thread
    safe)
    Updated, a more modern interface.

  Many userland updates were done to bring the code up to par with
  the recent RPC API.

  There is an update to the pthreads library, a function
  pthread_main_np() was added to emulate a function of Sun's threads
  library.

  While we're at it, bring in NetBSD's lockd, it's been far too
  long of a wait.

  New rpcbind(8) replaces portmap(8) (supporting communication over
  an authenticated Unix-domain socket, and by default only allowing
  set and unset requests over that channel). It's much more secure
  than the old portmapper.

  Umount(8), mountd(8), mount_nfs(8), nfsd(8) have also been upgraded
  to support TI-RPC and to support IPV6.

  Umount(8) is also fixed to unmount pathnames longer than 80 chars,
  which are currently truncated by the Kernel statfs structure.

Submitted by: Martin Blapp <mb@imp.ch>
Manpage review: ru
Secure RPC implemented by: wpaul
2001-03-19 12:50:13 +00:00
ru
ea31070695 mdoc(7) police: use the new features of the Nm macro. 2000-11-20 16:52:27 +00:00
brian
f94d0c01f2 Don't use libutil now that setproctitle() is in libc 2000-09-02 20:52:15 +00:00
sheldonh
ff1f324516 Remove single-space hard sentence breaks. These degrade the quality
of the typeset output, tend to make diffs harder to read and provide
bad examples for new-comers to mdoc.
2000-03-01 11:27:47 +00:00
markm
1bcfc94e36 Use libcrypto instead of libdes. 2000-02-24 21:01:54 +00:00
dillon
2022498b1b Thresh-out the nfs manual page references a bit
Reviewed by: Julian Elischer <julian@elischer.org>
2000-01-13 21:47:21 +00:00
dillon
4c498c4fde Give nfsd the ability to bind to specific IP addresses through the -h
option and add explicit option to bind to the wildcard address.  The
    default is to bind to the wildcard address when no -h option has been
    specified and thus backwards compatibility is maintained.

PR:		kern/13049
Reviewed by:	David Malone <dwmalone@maths.tcd.ie>
Submitted by:	Matt Dillon <dillon@freebsd.org>, David Malone <dwmalone@maths.tcd.ie>
1999-11-11 17:35:36 +00:00
peter
76f0c923fe $Id$ -> $FreeBSD$ 1999-08-28 00:22:10 +00:00
nik
c407bd7862 Add $Id$ to these manpages.
Approved by:            bde
1999-07-12 20:04:59 +00:00
ghelmer
f11e573200 Update refs for KLD's and kldload.
Submitted by:	Nathan Ahlstrom <nrahlstr@winternet.com>
1999-04-01 01:42:28 +00:00
charnier
15dad0ac31 Do not dot terminate syslog() string. Remove unused #includes. Add rcsid. -Wall. 1998-07-15 06:33:15 +00:00
peter
17853abae1 Don't give examples or use the depreciated usage to nfsd
PR: 5635
1998-05-01 13:45:04 +00:00
bde
d53ef8ee6e Removed definition of _NEW_VFSCONF. The new vfsconf interface is now
the default.
1998-01-20 10:40:18 +00:00
jdp
fcde3651a7 Fix two missing arguments detected by "-Wformat". 1997-11-18 03:14:53 +00:00
imp
167db52912 compare return value from getopt against -1 rather than EOF, per the final
posix standard on the topic.
1997-03-29 03:33:12 +00:00
peter
a4f4635e03 Merge from Lite2 (use new getvfsbyname() interface) 1997-03-11 12:51:00 +00:00
mpp
bef6fb830a Use the .Bx macro where appropriate. 1996-08-23 20:36:11 +00:00
bde
95dda376ac Default to udp if neither udp nor tcp is specified. The previous revision
was broken.  It forced udp in all cases except the extremely unusual case
argc == 0.
1996-05-01 03:13:45 +00:00
scrappy
0015477a1b default to udp if no flags specified...closes PR#bin/759
- should this be documented in the man page?
1996-04-13 06:08:24 +00:00
markm
532cda9998 #include <kerberosIV/des.h> -> #include <des.h> 1996-02-11 09:18:18 +00:00
adam
c81b66ce4c oops, do it right this time 1996-01-03 11:48:14 +00:00
adam
36a9cef9cd Link with libutil for kerberos too 1996-01-03 11:37:46 +00:00
peter
ae296d3181 Make nfsd use setproctitle from libutil...
Old code is still #ifdef OLD_SETPROCTITLE for comparison with the old
code.
1996-01-01 08:39:39 +00:00
peter
56f17dc307 The version of setproctitle() inside nfsd was busted. It was not terminating
the argv array, causing parts of the argv[0] to be picked up several times
by libkvm, causing strange ps results for the nfs-server and nfs-master
processes.. :-]

(How many copies of setproctitle() do we need anyway?  NetBSD has it in
 libc and BSDI have it in libutil.)
1995-12-15 13:13:32 +00:00