Space not getting freed up after deleting files from nfs mount point

Solution Verified - Updated -


  • Red Hat Enterprise Linux
  • Third party NFS Server


  • Space not getting freed up even after deleting files from /nfs_mount_point. df -h shows same disk usage as before and there is no PID holding the deleted file.
  • Space not getting freed up after deleting files from nfs mount share


  • As NFS Server is of third party, need to contact to NFS Storage vendor.

Root Cause

  • Storage level snapshot occupied the disk space.

Diagnostic Steps

  • No PID holding the files from /nfs_mount_point.
#lsof /nfs_mount_point | grep -i deleted
  • Check the usage in df command
#df -h /nfs_mount_point
Filesystem                         Size      Used         Avail        Use%        Mounted on                12TB      11.17TB      849GB       93%       /nfs_mount_point
  • du shows only 6.4 Tb data in /nfs_mount_point
#du -sxkh /nfs_mount_point/
6.4T    /nfs_mount_point/
  • Capture tcpdump while running df and analyze tcpdump.pcap to get the FSSTAT.
$tshark -n -tad -r tcpdump.pcap -Y 'nfs.procedure_v3 == FSSTAT'
 93 2019-04-11 09:46:39 -> NFS 208 V3 FSSTAT Call, FH: 0xd2a692d9
 94 2019-04-11 09:46:39 -> NFS 156 V3 FSSTAT Reply (Call In 93)
  • Check for the reply sent by NFS Server for the FSSTAT Call made by client and filtering it to get total size in bytes.
$tshark -n -tad -r tcpdump.pcap -Y 'frame.number == 94' -T fields -e nfs.fsstat3_resok.tbytes
  • Calculate total Size of the filesystem in TiB
Size in TiB = 13194139533312/1024/1024/1024/1024 = 12 TiB
  • Free space in the filesystem in bytes as per response from nfs server.
$ tshark -n -tad -r tcpdump.pcap -Y 'frame.number == 94' -T fields -e nfs.fsstat3_resok.fbytes
  • Available size of the filesystem in GiB.
 911985344512 /1024/1024/1024 = 849.352539063 GiB
  • Calculate used percentage.
used space = Total space - Free Space = 13194139533312 - 911985344512 = 1.228215419×10¹³ Bytes.

Converting used space into TiB = 1.228215419×10¹³/1024/1024/1024/1024 = 11.17 TiB

Used Percentage based on the bytes or data provided by the NFS Server:-

Used Space/Total Space * 100

11.17/12 * 100 = 93.08 %
  • This is the used space based on the data provided by the NFS Server on the basis of reply for FSSTAT call created by the NFS client for df. Hence it needs to be checked at nfs server end.

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.