summaryrefslogtreecommitdiffstats
path: root/sbin/mount_nfs
Commit message (Collapse)AuthorAgeFilesLines
* MFC r273896:trasz2014-11-292-50/+59
| | | | | | Build mount_nfs(8) with WARNS=6. Sponsored by: The FreeBSD Foundation
* MFC r273848:trasz2014-11-291-246/+2
| | | | | | | | | | | Get rid of obsolete code in mount_nfs(8). MFC r273861: Remove two functions unused after r273848. Would be nice if clang or at least scan-build yelled about it. Sponsored by: The FreeBSD Foundation
* MFC r273851:trasz2014-11-291-1/+2
| | | | | | Note that the "timeout" nfs option is in tenths of a second. Sponsored by: The FreeBSD Foundation
* MFC r273849:trasz2014-11-292-1/+46
| | | | | | | | Add support for "timeo", "actimeo", "noac", and "proto" options to mount_nfs(8). They are implemented on Linux, OS X, and Solaris, and thus can be expected to appear in automounter maps. Sponsored by: The FreeBSD Foundation
* MFC r269583:bz2014-08-162-1/+55
| | | | | | | | | | | | | | Provide -o vers= support for mount_nfs. Our mount_nfs does use -o nfsv<2|3|4> or -2 or -3 to specify the version. OSX (these days), Solaris, and Linux use -o vers=<2,3,4>. With the upcoming autofs support we can make a lot of (entrerprisy) setups getting mount options from LDAP just work by providing -o vers= compatibility. Reviewed by: wblock, bjk (man page), rmacklem, emaste Sponsored by: DARPA,AFRL PR: 192379
* MFC: r259089rmacklem2013-12-301-1/+14
| | | | | Document the noncontigwr NFS mount option. This is a content change.
* Document the "gssname" and "allgssname" mount options added by thermacklem2013-07-091-1/+25
| | | | | host-based initiator credential patches. This is a content change.
* GC unused variables. Prefer NULL over 0 for pointers.jkim2013-03-051-7/+6
|
* Document the new NFS mount options added by r244042.rmacklem2012-12-091-1/+13
| | | | This is a content change.
* Add a timeout on positive name cache entries in the NFS client. That is,jhb2012-01-251-0/+4
| | | | | | | | | | | we will only trust a positive name cache entry for a specified amount of time before falling back to a LOOKUP RPC, even if the ctime for the file handle matches the cached copy in the name cache entry. The timeout is configured via a new 'nametimeo' mount option and defaults to 60 seconds. It may be set to zero to disable positive name caching entirely. Reviewed by: rmacklem MFC after: 1 week
* Change checkpath() to not exit on error. This is a prerequisite forjh2012-01-161-1/+2
| | | | | | | fixing the mount(8) "failok" option. PR: 163668 Reviewed by: Garrett Cooper, delphij (previous version)
* Spelling fixes for sbin/uqs2012-01-071-1/+1
|
* Finish making 'wcommitsize' an NFS client mount option.jhb2011-11-142-0/+11
| | | | | Reviewed by: rmacklem MFC after: 1 week
* Implemented a mount option "nocto" that disables cache coherencyru2011-05-041-1/+12
| | | | | | | | checking at open time. It may improve performance for read-only NFS mounts. Use deliberately. MFC after: 1 week Reviewed by: rmacklem, jhb (earlier version)
* Fix the Makefile for mount_nfs so that it creates armacklem2011-05-011-1/+1
| | | | link for mount_oldnfs.8 instead of mount_newnfs.8.
* Update man pages related to the change in default NFS clientrmacklem2011-04-281-4/+8
| | | | | | applied by r221124. I also deleted references to idmapd, since that daemon no longer exists. This is a content change.
* This patch changes head so that the default NFS client is now the newrmacklem2011-04-272-9/+5
| | | | | | | | | | | | | | NFS client (which I guess is no longer experimental). The fstype "newnfs" is now "nfs" and the regular/old NFS client is now fstype "oldnfs". Although mounts via fstype "nfs" will usually work without userland changes, an updated mount_nfs(8) binary is needed for kernels built with "options NFSCL" but not "options NFSCLIENT". Updated mount_nfs(8) and mount(8) binaries are needed to do mounts for fstype "oldnfs". The GENERIC kernel configs have been changed to use options NFSCL and NFSD (the new client and server) instead of NFSCLIENT and NFSSERVER. For kernels being used on diskless NFS root systems, "options NFSCL" must be in the kernel config. Discussed on freebsd-fs@.
* Fix deprecated warning about -L which said -i was deprecated.simon2010-12-261-1/+1
| | | | MFC after: 3 days
* Correct a typo.jh2010-10-271-1/+1
| | | | | | PR: 151321 Submitted by: Simon Walton MFC after: 3 days
* Shut the compiler up; initializes the sotype variable to zero inkevlo2010-09-041-0/+1
| | | | | | nfs_tryproto(). Reviewed by: rmacklem
* Introduce '[ipaddr]:path' notation.ume2010-02-041-6/+16
| | | | | | | | | | | Since the existing implementation searches ':' backward, a path which includes ':' could not be mounted. You can now mount such path by enclosing an IP address by '[]'. Though we should change to search ':' forward, it will break 'ipv6addr:path' which is currently working. So, it still searches ':' backward, at least for now. MFC after: 2 weeks
* static'ify function prototypes and convert K&R to ANSI.delphij2010-02-031-24/+23
| | | | MFC after: 1 month
* Document the negnametimeo option for mount_nfs as implementedrmacklem2010-01-211-0/+4
| | | | | | by r202767. This is a content change. MFC after: 2 weeks
* Fix parsing of mount options specified with -o in case an option withjh2009-10-261-5/+5
| | | | | | | | | value is preceded by an option without value (for example -o option1,option2=value). Options must be separated before searching for '='. Also compare pnextopt explicitly against NULL. PR: bin/134069 Approved by: trasz (mentor)
* Change the default transport protocol for use by the Mount protocolrmacklem2009-09-171-1/+1
| | | | | | | | | | | from UDP to TCP, so that it is consistent with TCP for NFS, which became the default at r176198. Without this change, doing an NFS mount against a server that only supports UDP would result in an unusable mount point if a transport protocol option wasn't specified for the mount. Approved by: kib (mentor) MFC after: 3 days
* Delete the descriptions of the gssname and allgssname optionss fromrmacklem2009-07-291-42/+1
| | | | | | | mount_nfs.8 since these options are not implemented in FreeBSD8. This is content change for the man page. Approved by: re (kensmith), kib (mentor)
* Don't use sys/nfs/rpcv2.h - it is part of the old kernel RPC implementationdfr2009-06-241-12/+12
| | | | and will be removed.
* Code for parsing nmount options in kernel was mergedrodrigc2009-06-011-1/+1
| | | | | | to stable/7 branch in r190315. So only resort to fallback_mount() could which passes struct nfs_args to kernel in kernel versions less than 702100.
* Add support for the experimental nfs client to mount_nfs. Thermacklem2009-05-273-7/+172
| | | | | | | | | | | | experimental client is used when the fstype is "newnfs" or the "nfsv4" option is specified. It includes the addition of the option: gssname - to specify a client side initiator host based principal name which is specific to NFSv4. It also includes a change to mount.c, so that it knows about mount_newnfs, but not mount_nfs4. Reviewed by: dfr Approved by: kib (mentor)
* Remove the unmaintained University of Michigan NFSv4 client from 8.xrwatson2009-05-223-260/+6
| | | | | | | prior to 8.0-RELEASE. Rick Macklem's new and more feature-rich NFSv234 client and server are replacing it. Discussed with: rmacklem
* Set NFSMNT_ACDIRMAX flag in fallback_mount() function.rodrigc2009-02-061-0/+1
|
* Set NFSMNT_ACREGMIN, NFSMNT_ACREGMAX, and NFSMNT_ACDIRMIN flagsrodrigc2009-02-061-0/+9
| | | | | | | | in fallback_mount() function. Add a comment to indicate that the fallback_mount() function should eventually go away. Submitted by: Jaakko Heinonen <jh saunalahti fi>
* Fix parsing of acregmin, acregmax, acdirmin and acdirmax NFS mount optionsrodrigc2009-01-281-4/+4
| | | | | | when passed as strings via nmount(). Submitted by: Jaakko Heinonen <jh saunalahti fi>
* Implement support for RPCSEC_GSS authentication to both the NFS clientdfr2008-11-031-1/+53
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* Use the version of the kernel returned by getosreldate()rodrigc2008-09-191-6/+16
| | | | | | | to determine whether to call the fallback_mount() backwards compatibility function or not. Reviewed by: dfr
* Instead of building up a "struct nfs_args" to pass to the kernelrodrigc2008-09-132-473/+622
| | | | | | | | | | | | | | | via nmount(), build up an iovec where each iovec member is an NFS mount option, and pass the iovec down to the kernel via nmount(). These options are then parsed in the kernel. This should make it easier to add new NFS mount options in future. Many, many thanks to Doug Rabson for taking my initial patches, and cleaning them up. In addition, Doug added a fallback_mount() function so that the newer mount_nfs program will work against older kernels, to facilitate upgrading/downgrading scenarios. Doug also re-wrote the mount_nfs.8 man page. Reviewed by: dfr
* Fix -o mntudp after the conversion to default TCP mountskris2008-07-101-1/+4
| | | | | Submitted by: danfe MFC after: 1 week
* Undo the damage I did in sys/kern/vfs_mount.c #1.274 andyar2008-02-181-9/+0
| | | | | | | sbin/mount_nfs/mount_nfs.c #1.76. Let the dragons sleep. Requested by: rodrigc, des PR: kern/120319 (welcome the bug back)
* Add a work-around to make it possible again to remountyar2008-02-181-0/+9
| | | | | | | | | | | NFS root r/w. The real solution would be to bring the whole nmount(2) framework, including FS drivers and userland tools, into a consistent state at last; but things should work in the meantime, too. Reported by: kris
* Back out rev. 1.74 because the kernel isn't ready yetyar2008-02-181-8/+1
| | | | to see NFS specific string options.
* Don't forget to prepare string options for nmount(2).yar2008-02-181-1/+8
| | | | | | | Otherwise things won't work as intended, e.g., it'll be impossible to upgrade NFS root mount to read-write. Reported by: kris
* Add the -4 option to the synopsis.ceri2008-02-121-1/+1
|
* Bump .Dd for r1.48.ceri2008-02-121-1/+1
|
* Switch the default NFS mount mode from UDP to TCP. UDP mounts are akris2008-02-112-6/+6
| | | | | | | | | | historical relic, and are no longer appropriate for either LAN or WAN mounting. At modern (gigabit and 10 gigabit) LAN speeds packet loss from socket buffer fill events is common, and sequence numbers wrap quickly enough that data corruption is possible. TCP solves both of these problems without imposing significant overhead. MFC after: 1 month
* Add "fg" option as antonym to "bg"; add "hard" option as antonym to "soft".thomas2007-03-052-0/+8
| | | | | | | | This is for better compatibility with other environments (Linux, Solaris, HP-UX, AIX and Tru64 support these options). PR: bin/109924 MFC after: 1 week
* Link mount_nfs -> mount_nfs4, and mount_nfs.8 -> mount_nfs4.8.rodrigc2007-01-231-0/+3
| | | | Suggested by: rees
* Merge mount_nfs4.c and mount_nfs.c into one program.rodrigc2007-01-232-7/+248
| | | | | | | | | | | If argv[0] == "mount_nfs4", then default to mounting NFSv4, otherwise if argv[0] == "mount_nfs", default to the old mount_nfs behavior. - Add a -4 option. - Add the University of Michigan copyright from mount_nfs4.c, for the code merged from mount_nfs4.c. Reviewed by: rees
* Pass a string buffer named "errmsg" to nmount().rodrigc2006-11-291-2/+4
| | | | | | | | This will allow the NFS mount code to return a string error message in addition to returning an error integer value. Reviewed by: mohans MFC after: 1 month
* Deduce the "fstype" parameter to pass to nmount() by looking atrodrigc2006-11-291-2/+8
| | | | | | | | the "_nfs" part of argv[0]. This should facilitate unifying mount_nfs and mount_nfs4 into one binary. MFC after: 1 month Reviewed by: mohans
* Increase WARNS to 3.rodrigc2006-11-211-1/+1
|
OpenPOWER on IntegriCloud