#
272461 |
|
02-Oct-2014 |
gjb |
Copy stable/10@r272459 to releng/10.1 as part of the 10.1-RELEASE process.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation |
#
256281 |
|
10-Oct-2013 |
gjb |
Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation
|
#
246781 |
|
14-Feb-2013 |
delphij |
Simplify r243637 and make sure that nfsdargs.{min,max}threads are always set to meaningful value:
- When nfsdcnt is set, it dictates all values; - Otherwise, nfsdargs.minthreads is set to user specified value, or the automatically detected value if there is no one specified; nfsdargs.maxthreads is set to the user specified value, or the value of nfsdargs.minthreads if there is no one specified; when it is smaller than nfsdargs.minthreads, the latter's value is always used.
MFC after: 2 weeks
|
#
246780 |
|
13-Feb-2013 |
delphij |
Abstract out setting of nfsdcnt and consistently use MAXNFSDCNT when the proposed value is too high and DEFNFSDCNT when proposed value is too low.
MFC after: 2 weeks
|
#
246778 |
|
13-Feb-2013 |
delphij |
Use static for all functions that do not need to be exported.
MFC after: 2 weeks
|
#
244447 |
|
19-Dec-2012 |
rmacklem |
Post r243965 the nfsd daemon will not start up for kernels built without "options INET6". This patch fixes the problem.
Reported by: avg Tested by: avg MFC after: 2 weeks
|
#
243645 |
|
28-Nov-2012 |
alfred |
Don't allow minthreads > maxthreads.
Suggested by: rmacklem
|
#
243644 |
|
28-Nov-2012 |
alfred |
Fix typo.
Pointed out by: marck
|
#
243637 |
|
27-Nov-2012 |
alfred |
Autoconfigure nfsd threads based on ncpu.
Rick Macklem and I discussed the default number of nfsd threads and concluded that it is too low to perform adiquitely on today's hardware.
We decided to auto tune the number of nfsds based on the number of cpus in the system.
While I'm here I've also added:
1) ability to set the minthreads/maxthreads from userland. 2) ability to run nfsd in debug mode via the cli.
Reviewed by: rmacklem MFC after: 2 weeks
|
#
241849 |
|
22-Oct-2012 |
eadler |
Fix typo in error when unable to create TCP socket
PR: bin/172490 Submitted by: bdrewery Approved by: cperciva MFC after: 3 days
|
#
241737 |
|
19-Oct-2012 |
ed |
More -Wmissing-variable-declarations fixes.
In addition to adding `static' where possible:
- bin/date: Move `retval' into extern.h to make it visible to date.c. - bin/ed: Move globally used variables into ed.h. - sbin/camcontrol: Move `verbose' into camcontrol.h and fix shadow warnings. - usr.bin/calendar: Remove unneeded variables. - usr.bin/chat: Make `line' local instead of global. - usr.bin/elfdump: Comment out unneeded function. - usr.bin/rlogin: Use _Noreturn instead of __dead2. - usr.bin/tset: Pull `Ospeed' into extern.h. - usr.sbin/mfiutil: Put global variables in mfiutil.h. - usr.sbin/pkg: Remove unused `os_corres'. - usr.sbin/quotaon, usr.sbin/repquota: Remove unused `qfname'.
|
#
223492 |
|
24-Jun-2011 |
kevlo |
Remove duplicated header files
|
#
220980 |
|
23-Apr-2011 |
rmacklem |
This patch changes the default NFS server to the new one, which was referred to as the experimental server. It also adds a new command line option "-o" to both mountd and nfsd that forces them to use the old/regular NFS server. The "-e" option for these commands is now a no-op, since the new server is the default. I will be committing rc script and man changes soon. Discussed on freebsd-fs@.
|
#
220510 |
|
10-Apr-2011 |
rmacklem |
Add support for a backup stable restart file to the nfsd, used for NFSv4 restart. This permits the nfsd to create the stable restart file as required and minimizes the risk of trouble if the file is lost.
Suggested by: Tim Kientzle Reviewed by: jhb MFC after: 2 weeks
|
#
218777 |
|
17-Feb-2011 |
jhb |
Save a copy of errno before invoking syslog() if accept() or select() fail. syslog() can trash the errno value causing nfsd to exit for non-fatal errors like ECONNABORTED from accept().
MFC after: 1 week
|
#
201227 |
|
29-Dec-2009 |
ed |
ANSIfy almost all applications that use WARNS=6.
I was considering committing all these patches one by one, but as discussed with brooks@, there is no need to do this. If we ever need/want to merge these changes back, it is still possible to do this per application.
|
#
194880 |
|
24-Jun-2009 |
dfr |
Don't use sys/nfs/rpcv2.h - it is part of the old kernel RPC implementation and will be removed.
|
#
192993 |
|
28-May-2009 |
rmacklem |
Change the "-4" argument for nfsd and mountd to "-e" to avoid confusion, since it does not refer to IPv4 nor NFSv4, but to running the experimental server instead of the regular one.
Approved by: kib (mentor)
|
#
192674 |
|
23-May-2009 |
rmacklem |
Modify nfsd.c to add support for the experimental nfs server. This includes the addition of a new flag "-4" that will force use of the experimental server with nfsv4 support in it. This commit also adds two new man pages to the repository that are NFSv4 specific. One describes the file used by the server to restart nfsv4 services safely. The other is a brief overview of nfsv4 and its setup.
Reviewed by: dfr Approved by: kib (mentor)
|
#
184588 |
|
03-Nov-2008 |
dfr |
Implement support for RPCSEC_GSS authentication to both the NFS client and server. This replaces the RPC implementation of the NFS client and server with the newer RPC implementation originally developed (actually ported from the userland sunrpc code) to support the NFS Lock Manager. I have tested this code extensively and I believe it is stable and that performance is at least equal to the legacy RPC implementation.
The NFS code currently contains support for both the new RPC implementation and the older legacy implementation inherited from the original NFS codebase. The default is to use the new implementation - add the NFS_LEGACYRPC option to fall back to the old code. When I merge this support back to RELENG_7, I will probably change this so that users have to 'opt in' to get the new code.
To use RPCSEC_GSS on either client or server, you must build a kernel which includes the KGSSAPI option and the crypto device. On the userland side, you must build at least a new libc, mountd, mount_nfs and gssd. You must install new versions of /etc/rc.d/gssd and /etc/rc.d/nfsd and add 'gssd_enable=YES' to /etc/rc.conf.
As long as gssd is running, you should be able to mount an NFS filesystem from a server that requires RPCSEC_GSS authentication. The mount itself can happen without any kerberos credentials but all access to the filesystem will be denied unless the accessing user has a valid ticket file in the standard place (/tmp/krb5cc_<uid>). There is currently no support for situations where the ticket file is in a different place, such as when the user logged in via SSH and has delegated credentials from that login. This restriction is also present in Solaris and Linux. In theory, we could improve this in future, possibly using Brooks Davis' implementation of variant symlinks.
Supporting RPCSEC_GSS on a server is nearly as simple. You must create service creds for the server in the form 'nfs/<fqdn>@<REALM>' and install them in /etc/krb5.keytab. The standard heimdal utility ktutil makes this fairly easy. After the service creds have been created, you can add a '-sec=krb5' option to /etc/exports and restart both mountd and nfsd.
The only other difference an administrator should notice is that nfsd doesn't fork to create service threads any more. In normal operation, there will be two nfsd processes, one in userland waiting for TCP connections and one in the kernel handling requests. The latter process will create as many kthreads as required - these should be visible via 'top -H'. The code has some support for varying the number of service threads according to load but initially at least, nfsd uses a fixed number of threads according to the value supplied to its '-n' option.
Sponsored by: Isilon Systems MFC after: 1 month
|
#
153609 |
|
21-Dec-2005 |
delphij |
Previous revision was broken on SPARC, fix it by using more appropriate type.
Reported by: tindebox Pointy hat to: delphij
|
#
153590 |
|
21-Dec-2005 |
delphij |
Use size_t for length.
|
#
140679 |
|
23-Jan-2005 |
rwatson |
Bump the default maximum on nfsd processes from 20 to 256. Real-world measurements suggest that higher degrees of parallelism for large numbers of clients help performance substantially.
Submitted by: Eric Anderson <anderson at centtech dot com>
|
#
137319 |
|
06-Nov-2004 |
delphij |
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 :-)
|
#
133249 |
|
07-Aug-2004 |
imp |
Per letter dated July 22, 1999 remove 3rd clause of Berkeley derived software (with permission of addtional copyright holders where appropriate)
|
#
124357 |
|
10-Jan-2004 |
rwatson |
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
|
#
100656 |
|
25-Jul-2002 |
peter |
Bah, I forgot to commit this part of the nfssvc() cleanup. Sorry folks.
|
#
100505 |
|
22-Jul-2002 |
ume |
use IPV6_V6ONLY instead of non standard IPV6_BINDV6ONLY.
MFC after: 1 week
|
#
100499 |
|
22-Jul-2002 |
kan |
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
|
#
97844 |
|
04-Jun-2002 |
gordon |
Fix spelling nit in error message.
|
#
95861 |
|
01-May-2002 |
peter |
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.
|
#
93233 |
|
26-Mar-2002 |
pb |
Fix problem in macro definition breaking compiles with -DDEBUG.
PR: bin/35773 Submitted by: Thomas Quinot <thomas@cuivre.fr.eu.org>
|
#
85034 |
|
16-Oct-2001 |
iedowse |
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
|
#
83688 |
|
20-Sep-2001 |
peter |
Deal with nfs server module changes for autoloading.
|
#
83653 |
|
18-Sep-2001 |
peter |
Userland part of nfs client/server split and cleanup.
|
#
74800 |
|
25-Mar-2001 |
alfred |
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.
|
#
74799 |
|
25-Mar-2001 |
alfred |
Disable ipv6 when getnetconfigent("udp6"/"tcp6") fails.
Submitted by: Martin Blapp <mb@imp.ch>
|
#
74462 |
|
19-Mar-2001 |
alfred |
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
|
#
65379 |
|
02-Sep-2000 |
brian |
Don't use libutil now that setproctitle() is in libc
|
#
53096 |
|
11-Nov-1999 |
dillon |
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>
|
#
50476 |
|
27-Aug-1999 |
peter |
$Id$ -> $FreeBSD$
|
#
37666 |
|
15-Jul-1998 |
charnier |
Do not dot terminate syslog() string. Remove unused #includes. Add rcsid. -Wall.
|
#
31206 |
|
18-Nov-1997 |
jdp |
Fix two missing arguments detected by "-Wformat".
|
#
24359 |
|
29-Mar-1997 |
imp |
compare return value from getopt against -1 rather than EOF, per the final posix standard on the topic.
|
#
23684 |
|
11-Mar-1997 |
peter |
Merge from Lite2 (use new getvfsbyname() interface)
|
#
15496 |
|
01-May-1996 |
bde |
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.
|
#
15222 |
|
13-Apr-1996 |
scrappy |
default to udp if no flags specified...closes PR#bin/759 - should this be documented in the man page?
|
#
14024 |
|
11-Feb-1996 |
markm |
#include <kerberosIV/des.h> -> #include <des.h>
|
#
13141 |
|
01-Jan-1996 |
peter |
Make nfsd use setproctitle from libutil...
Old code is still #ifdef OLD_SETPROCTITLE for comparison with the old code.
|
#
12869 |
|
15-Dec-1995 |
peter |
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.)
|
#
9336 |
|
27-Jun-1995 |
dfr |
Changes to support version 3 of the NFS protocol. The version 2 support has been tested (client+server) against FreeBSD-2.0, IRIX 5.3 and FreeBSD-current (using a loopback mount). The version 2 support is stable AFAIK. The version 3 support has been tested with a loopback mount and minimally against an IRIX 5.3 server. It needs more testing and may have problems. I have patched amd to support the new variable length filehandles although it will still only use version 2 of the protocol.
Before booting a kernel with these changes, nfs clients will need to at least build and install /usr/sbin/mount_nfs. Servers will need to build and install /usr/sbin/mountd.
NFS diskless support is untested.
Obtained from: Rick Macklem <rick@snowhite.cis.uoguelph.ca>
|
#
2999 |
|
22-Sep-1994 |
wollman |
Automatically load NFS and a bevy of other filesystems.
|
#
2030 |
|
11-Aug-1994 |
dg |
Use nulls to pad proctitle rather than spaces...makes ps(1) output more readable.
|
#
1558 |
|
26-May-1994 |
rgrimes |
BSD 4.4 Lite sbin Sources
Note: XNSrouted and routed NOT imported here, they shall be imported with usr.sbin.
|