On Tue, Feb 25, 2025 at 5:17 PM Chuck Lever <chuck.lever@xxxxxxxxxx> wrote: > > On 2/25/25 11:04 AM, Takeshi Nishimura wrote: > > how can I run 4 separate NFSv4.0/4.1/4.2 servers on 4 separate TCP > > ports, say 2049, 12049, 22049, 32049, on the same Linux kernel, and > > have a separate exports file for each of them? > > This question has been asked in the past. We've explored implementing it > with a single NFSD instance, but it looks difficult to impossible > without massive code changes. > > The solution we recommend is to run separate NFSD instances in guests > (containers or qemu). The host system might provide a NAT routing > service that makes the guests appear on the same IP address but > different ports. Running in QEmu is not acceptable for performance, and it adds at least a 1GB RAM usage for nothing. A container is also not a really preferred option, because the OS files in the container must be maintained and CVEs handled. Why is it so hard to run more than one instance of a nfsd server? > > This has the benefit of providing administrative isolation between the > NFS services. It would work well with NFSv4, but would be somewhat > awkward for NFSv2/3 due to the required use of auxiliary protocols such > as MNT and NLM (and of course rpcbind). I am NOT interested in NFSv2/3, because we are no longer allowed to use these obsoleted protocols in our local network. Only NFSv4.0/4.1/4.2 are of interest Is there a cookbook or howto which documents how to set up a MINIMUM container for this? -- Internationalization&localization dev / 大阪大学 Takeshi Nishimura <takeshi.nishimura.linux@xxxxxxxxx>