Phantom Used Space

Joined
May 2, 2017
Messages
211
I have a dataset that I'm moving data from. Browsing the NFS shares with "show hidden files" shows everything is empty. I deleted all my snapshots and the pool interface still shows it has about 50GB of data in it. Is there a ZFS command to show what is using this space, or force a recalculation?

Thanks!
 

Whattteva

Wizard
Joined
Mar 5, 2013
Messages
1,824
To check your pool capacity:
Code:
zpool list


To check your datasets usage:
Code:
zfs list


To check your snapshots usage:
Code:
 zfs list -t snap


To check how much space a folder/directory takes (beware, this could take a long time if you have a lot of data under that folder):
Code:
du -hd0 /path/to/folder
 
Last edited:
Joined
May 2, 2017
Messages
211
du -hd0 /path/to/folder

This returns 2.0 KB, the interface shows 44.8 GB. I'm trying to make sure I'm not missing any files before I nuke the dataset. Might have to reboot here shortly and see if that clears up this buggy interface reporting...
 

Whattteva

Wizard
Joined
Mar 5, 2013
Messages
1,824
du -hd0 /path/to/folder

This returns 2.0 KB, the interface shows 44.8 GB. I'm trying to make sure I'm not missing any files before I nuke the dataset. Might have to reboot here shortly and see if that clears up this buggy interface reporting...
Are there any nested datasets under that path. du isn't really built for ZFS so it may not report that correctly and you should probably use the output of zfs list instead.
 
Joined
Oct 22, 2019
Messages
3,641
If you want a comprehensive list:
Code:
zfs list -r -t filesystem -o space


This will help you narrow down where data still exists.
 
Joined
May 2, 2017
Messages
211
A reboot fixed it. The GUI wasn't updating properly, apparently.
 
Top