Understanding reported size on an NFS share

Status
Not open for further replies.

akpends

Cadet
Joined
Nov 11, 2018
Messages
2
Hello everyone,

I'm posting here in hope to get a better understanding of how FreeNAS works especially when it comes to NFS shares and ZFS.

I'm currently hosting a /data folder for an application via an NFS share on a QNAP. Last week we had a disk failure and given the age of the device, I don't trust it to last very long. Over the week-end I migrated the data over an NFS share on our FreeNAS box (9.10.2... but we'll upgrade soon™) and the first thing I did after the transfer is run a du -ch to check the data size on the source and the destination. I have 132GB of data on the QNAP and 119GB on the FreeNAS. That got me curious.

I also have a 500+MB log file. Under ls -h, both of the shares report the same size. However if I run du -h, the FreeNAS share reports a size of 48MB. When I md5 the file on both shares, I get the same result hash. At this point I ssh'd on the FreeNAS server and ran zfs get all /path/to/share and I get a compressratio of 1.12x.

So here are my questions :
- Should I worry about the discrepancy in reported sizes or is it just the ZFS compression doing what it's supposed to do?
- To the best of your knowledge, are there other tests I could perform to check the integrity of the transferred data?

Thanks in advance for any input or advice the community could provide.
 

akpends

Cadet
Joined
Nov 11, 2018
Messages
2
Hello Dru,
I did, or so I think. I RTFM'd du(1) and found the -A option that :
Display the apparent size instead of the disk usage. This can be helpful when operating on compressed volumes or sparse files
Results were consistent between the source and the destination so I proceeded to switch from one to the other. The application seems to run fine, no user reported missing/corrupted files. I'm a happy camper.
 
Last edited:
Status
Not open for further replies.
Top