summaryrefslogtreecommitdiffstats
path: root/sbin
diff options
context:
space:
mode:
authorkris <kris@FreeBSD.org>2008-02-11 23:23:21 +0000
committerkris <kris@FreeBSD.org>2008-02-11 23:23:21 +0000
commit989a96d5cb275865259133d5282761b7a4bf0de8 (patch)
tree57916269ae94baf4c1e5e8e07c685703b778cbc7 /sbin
parente3f122733ae5a2ff4d38fe7d3a3da82749c22f68 (diff)
downloadFreeBSD-src-989a96d5cb275865259133d5282761b7a4bf0de8.zip
FreeBSD-src-989a96d5cb275865259133d5282761b7a4bf0de8.tar.gz
Switch the default NFS mount mode from UDP to TCP. UDP mounts are a
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
Diffstat (limited to 'sbin')
-rw-r--r--sbin/mount_nfs/mount_nfs.810
-rw-r--r--sbin/mount_nfs/mount_nfs.c2
2 files changed, 6 insertions, 6 deletions
diff --git a/sbin/mount_nfs/mount_nfs.8 b/sbin/mount_nfs/mount_nfs.8
index 93ea3c2..a8d410f 100644
--- a/sbin/mount_nfs/mount_nfs.8
+++ b/sbin/mount_nfs/mount_nfs.8
@@ -142,11 +142,11 @@ The default is a retry count of zero, which means to keep retrying
forever.
There is a 60 second delay between each attempt.
.It Fl T
-Use TCP transport instead of UDP.
-This is recommended for servers that are not on the same LAN cable as
-the client.
-Not all NFS servers support this method, especially older ones;
-caution should be observed in these cases.
+Use TCP transport.
+This is the default option, as it provides for increased reliability on both
+LAN and WAN configurations compared to UDP.
+Some old NFS servers do not support this method; UDP mounts may be required
+for interoperability.
.It Fl U
Force the mount protocol to use UDP transport, even for TCP NFS mounts.
(Necessary for some old
diff --git a/sbin/mount_nfs/mount_nfs.c b/sbin/mount_nfs/mount_nfs.c
index 44d45e8..48c0a1f 100644
--- a/sbin/mount_nfs/mount_nfs.c
+++ b/sbin/mount_nfs/mount_nfs.c
@@ -155,7 +155,7 @@ struct nfs_args nfsdefargs = {
NFS_ARGSVERSION,
NULL,
sizeof (struct sockaddr_in),
- SOCK_DGRAM,
+ SOCK_STREAM,
0,
NULL,
0,
OpenPOWER on IntegriCloud