dpearcefl
Contributor
- Joined
 - Aug 4, 2015
 
- Messages
 - 145
 
I'm trying to get my head wrapped around how to calculate disk space usage on a ZFS volume/dataset. There seems to be multiple ways to get disk information, some of which is before or after compression/deduplication but not specified.
For instance:
If I run "du -h -d 1 -A" I get the apparent or actual uncompressed file sizes. From the filesystem's point of view, not very interesting. From a user's perspective, with compression you can actually "use" more disk space than you actually have.
The GUI's "compression rate" and what comes out of "zdb -D dataset" I have found out can be wildly wrong when you have a file with a bunch of empty space.
So if a PHB asks "How fast is the NAS filling up?", how do I get meaningful stats like the following:
Thanks.
	
		
			
		
		
	
			
			For instance:
If I run "du -h -d 1 -A" I get the apparent or actual uncompressed file sizes. From the filesystem's point of view, not very interesting. From a user's perspective, with compression you can actually "use" more disk space than you actually have.
The GUI's "compression rate" and what comes out of "zdb -D dataset" I have found out can be wildly wrong when you have a file with a bunch of empty space.
So if a PHB asks "How fast is the NAS filling up?", how do I get meaningful stats like the following:
- What is the actual compression ratio? (space used on the disk / space of original file)
 - How much is deduplication saving us? (space used on the disk / space of original files)
 
Thanks.