Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.kernel > #73701
| From | "Trent W. Buck" <trentbuck@gmail.com> |
|---|---|
| Newsgroups | linux.debian.bugs.dist, linux.debian.kernel |
| Subject | Bug#409272: nfsmount: incompatible with nfsv4 |
| Date | 2021-11-17 01:50 +0100 |
| Message-ID | <Dkhjb-7Ok-1@gated-at.bofh.it> (permalink) |
| References | <Dkg3M-798-5@gated-at.bofh.it> <Dkg3M-798-5@gated-at.bofh.it> <Dkg3M-798-3@gated-at.bofh.it> <Dkg3M-798-5@gated-at.bofh.it> <Dkg3M-798-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Cross-posted to 2 groups.
[Multipart message — attachments visible in raw view] - view raw
Trent W. Buck wrote:
> 3. A single mount(2) call also works!
>
> It is quite annoying that we need *anything* special in userland, because
> a nfsvers=4.2,sec=sys mount requires only 2049/tcp (no other ports/services), and
> the actual filesystem is in-kernel, so
> really all that should be needed is enough of a C program to issue a single mount(2)!
>
> As an experiment, I tried do compile in EXACTLY that, and it works for me:
>
> root@main:~# >nfsmount.c printf '#include <stdlib.h>\n#include <sys/mount.h>\nint main() {exit(mount("10.0.2.100:/srv/netboot", "/mnt", "nfs", 0, "vers=4.2,addr=10.0.2.100,clientaddr=10.0.2.15"));}'
> root@main:~# klcc -o nfsmount nfsmount.c
> root@main:~# ./nfsmount; echo $?
> ./nfsmount; echo $?
> Nov 17 10:11:31 main.lan kernel: process '/root/nfsmount' started with executable stack
> 0
>
> This is pretty narrow in scope and is probably achievable.
> It allows you to boot off NFSv4, without putting glibc into the initrd.
I had a go at actually packaging this (attached), but
it turns out to be slightly harder than I thought (see comments in mount.nfs.c).
I don't have time to pursue this further.
Back to linux.debian.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
Bug#409272: nfsmount: incompatible with nfsv4 "Trent W. Buck" <trentbuck@gmail.com> - 2021-11-17 00:30 +0100 Bug#409272: nfsmount: incompatible with nfsv4 "Trent W. Buck" <trentbuck@gmail.com> - 2021-11-17 01:50 +0100
csiph-web