[oS-en] How to see nfsserver exports actually being used?
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hi, "showmount -e" lists exports from an nfs server. How can I see what clients are actually mounting, this moment, something and what? I tried: Telcontar:~ # showmount -a All mount points on Telcontar: *.valinor:/Grande/nfs 127.0.0.1:/data/storage_c/repositorios_zypp 192.168.1.129:/data/storage_c/repositorios_zypp 192.168.1.129:/data/storage_c/repositorios_zypp/11_3/packages 192.168.1.12:/ 192.168.1.12:/Grande/nfs 192.168.1.14:/ Telcontar:~ # But that information is false. - -- Cheers Carlos E. R. (from 15.4 x86_64 at Telcontar) -----BEGIN PGP SIGNATURE----- iHoEARECADoWIQQZEb51mJKK1KpcU/W1MxgcbY1H1QUCZAS9Exwccm9iaW4ubGlz dGFzQHRlbGVmb25pY2EubmV0AAoJELUzGBxtjUfVJqsAnjkRYvO9+NZwVkErdoVx W1dhH+mrAJ47YmbT0yt4rCwJ0YTC+KxJVmHBXA== =rnnm -----END PGP SIGNATURE-----
On Mon, Mar 6, 2023 at 1:31 PM Carlos E. R. <robin.listas@telefonica.net> wrote:
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
Hi,
"showmount -e" lists exports from an nfs server. How can I see what clients are actually mounting, this moment, something and what?
You cannot. See "man showmount". Besides, "mounting" an NFS resource is a misnomer. All that it does is provide a handle for the top level directory. Once a client has this handle, it can always access NFS export, whether it issued a "mount request" or not. For TCP based mounts you can check active sockets.
On 2023-03-06 11:59, Andrei Borzenkov wrote:
On Mon, Mar 6, 2023 at 1:31 PM Carlos E. R. <robin.listas@telefonica.net> wrote:
Hi,
"showmount -e" lists exports from an nfs server. How can I see what clients are actually mounting, this moment, something and what?
You cannot. See "man showmount".
Besides, "mounting" an NFS resource is a misnomer. All that it does is provide a handle for the top level directory. Once a client has this handle, it can always access NFS export, whether it issued a "mount request" or not.
For TCP based mounts you can check active sockets.
Ah. I saw references and scripts for that when googling. I thought the server would simply keep track, somehow. -- Cheers / Saludos, Carlos E. R. (from 15.4 x86_64 at Telcontar)
On 07.03.2023 20:56, Carlos E. R. wrote:
On 2023-03-06 11:59, Andrei Borzenkov wrote:
On Mon, Mar 6, 2023 at 1:31 PM Carlos E. R. <robin.listas@telefonica.net> wrote:
Hi,
"showmount -e" lists exports from an nfs server. How can I see what clients are actually mounting, this moment, something and what?
You cannot. See "man showmount".
Besides, "mounting" an NFS resource is a misnomer. All that it does is provide a handle for the top level directory. Once a client has this handle, it can always access NFS export, whether it issued a "mount request" or not.
For TCP based mounts you can check active sockets.
Ah.
I saw references and scripts for that when googling. I thought the server would simply keep track, somehow.
Yes, it keeps track, but this track in unreliable. The case of client accessing NFS server without previous mount request is probably very unusual, but the case of client stuck in server table (e.g. because client crashed or skipped umount for whatever reason) is common. So stale information will accumulate over time.
On 2023-03-07 19:36, Andrei Borzenkov wrote:
On 07.03.2023 20:56, Carlos E. R. wrote:
On 2023-03-06 11:59, Andrei Borzenkov wrote:
On Mon, Mar 6, 2023 at 1:31 PM Carlos E. R. <> wrote:
Hi,
"showmount -e" lists exports from an nfs server. How can I see what clients are actually mounting, this moment, something and what?
You cannot. See "man showmount".
Besides, "mounting" an NFS resource is a misnomer. All that it does is provide a handle for the top level directory. Once a client has this handle, it can always access NFS export, whether it issued a "mount request" or not.
For TCP based mounts you can check active sockets.
Ah.
I saw references and scripts for that when googling. I thought the server would simply keep track, somehow.
Yes, it keeps track, but this track in unreliable. The case of client accessing NFS server without previous mount request is probably very unusual, but the case of client stuck in server table (e.g. because client crashed or skipped umount for whatever reason) is common.
Yes, I remember that. I have a bunch of those entries.
So stale information will accumulate over time.
Indeed. Telcontar:~ # showmount -a All mount points on Telcontar: *.valinor:/Grande/nfs 127.0.0.1:/data/storage_c/repositorios_zypp 192.168.1.129:/data/storage_c/repositorios_zypp 192.168.1.129:/data/storage_c/repositorios_zypp/11_3/packages 192.168.1.12:/ 192.168.1.12:/Grande/nfs 192.168.1.14:/ Telcontar:~ # Telcontar:~ # host 192.168.1.12 12.1.168.192.in-addr.arpa domain name pointer nimrodel.valinor. Telcontar:~ # That machine is "archived" physically since a decade ago at least :-D 129 is my old laptop, but it certainly is not running or using 11.3 packages, LOL. -- Cheers / Saludos, Carlos E. R. (from 15.4 x86_64 at Telcontar)
participants (2)
-
Andrei Borzenkov
-
Carlos E. R.