meta data for this page
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
linux:remotefs:nfs [2025/02/26 07:46] – created niziak | linux:remotefs:nfs [2025/02/26 08:43] (current) – niziak | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== NFS ====== | ====== NFS ====== | ||
+ | |||
+ | [[https:// | ||
+ | |||
+ | A new feature, available for both 2.4 and 2.5 kernels but not yet integrated into the mainstream kernel at the time | ||
+ | of this writing, is NFS over TCP. Using TCP has a | ||
+ | The advantage is that it works far better than UDP on lossy networks. When using TCP, a single dropped packet | ||
+ | can be retransmitted, | ||
+ | on lossy networks. In addition, TCP will handle network speed differences better than UDP, due to the underlying | ||
+ | flow control at the network level. | ||
+ | |||
+ | ===== performance ===== | ||
+ | |||
+ | On server ''/ | ||
+ | * **no_subtree_check** - If a subdirectory of a filesystem is exported, but the whole filesystem isn't then whenever a NFS request arrives, the server must check not only that the accessed file is in the appropriate filesystem (which is easy) but also that it is in the exported tree (which is harder). This check is called the subtree_check. | ||
+ | * **async** - This option allows the NFS server to violate the NFS protocol and reply to requests before any changes made by that request have been committed to stable storage (e.g. disc drive). | ||
+ | * **all_squash** - Map all uids and gids to the anonymous user. Useful for NFS-exported public FTP directories, | ||
+ | |||
+ | On client ''/ | ||
+ | * '' | ||
+ | |||
+ | |||
+ | ===== diagnostic ===== | ||
+ | |||
+ | [[https:// | ||
+ | |||
+ | <code bash> | ||
+ | mountstats --nfs | ||
+ | </ | ||
+ | |||
===== Issues ===== | ===== Issues ===== | ||
Line 12: | Line 41: | ||
* ''/ | * ''/ | ||
* '' | * '' | ||
+ | * '' | ||
* On " | * On " | ||
* wireshark shows few READDIR requests and then lots of single GETATTR requests for each file | * wireshark shows few READDIR requests and then lots of single GETATTR requests for each file | ||
Line 17: | Line 47: | ||
* ''/ | * ''/ | ||
* '' | * '' | ||
+ | * '' | ||
+ | |||
+ | Reason - debug enabled: | ||
+ | <code bash> | ||
+ | rpcdebug -m nfs -s all | ||
+ | </ | ||
- | slow listing vs fast listing | + | Disable it: |
+ | <code bash> | ||
+ | rpcdebug -m nfs -c all | ||
+ | </ | ||
- | slow / | ||
- | CONFIG_NFSD_V3=y | ||
- | |||
- | fast / | ||
- | CONFIG_NFSD_V2=y | ||
- | CONFIG_NFS_V4_2_SSC_HELPER=y |