How to monitor which files are accessed through NFS?
You can use either lsof or ftop (the last one is on EPEL repo)
For example:
lsof -N /mnt/nfs/*
HTH
Related videos on Youtube
![Admin](/assets/logo_square_200-5d0d61d6853298bd2a4fe063103715b4daf2819fc21225efa21dfb93e61952ea.png)
Admin
Updated on September 18, 2022Comments
-
Admin almost 2 years
I have a linux file server running CentOS 6. Files are accessed via NFS4.
Sometimes I have problems with disk io load. I want to find out what is causing them.
I can find out which client is causing them with tcpdump and nfsiostat (on the clients). But I want to know either which files are accessed or which process is doing the accesses. Then I can think about a solution for it.
I have tried to use wireshark to decode the accesses, but it is hard to read when open and read/write are not close together or you have lots of files with similar names (directories are not shown, just dir handles). If you have a lot of activity it would be nice to have a way to sort files by activity to find out what is the culprit.
Does anybody know of a solution for this?
-
Admin almost 12 yearsDo you want to look on the client or the server?
-
Admin over 5 yearsI have the same problem and want to find out on the server.
-
-
DarkNeuron over 5 yearsA late comment, but this seems to be for local disks, and not NFS.