
On Thu, 20 Aug 2020 at 16:59, stripes theotoky via luv-main < luv-main@luv.asn.au> wrote:
Dear Group,
I am looking for advice on ZFS. My computer is running painfully slowly. I assume this is due to ZFS snapshots eating the entire disk space. My knowledge of ZFS is almost zero, this box was installed by a friend in the UK back in 2016 in the days when Ubuntu 16:04 was experimental and is still running 16.04. I have run the following commands
sudo zpool set listsnapshots=on alexandria zfs list -o space -r alexandria Which seems to show the space is being eaten by snapshots of the home directory and oddly that there are no snapshots from before 2019. The computer is in effect unuseable at the moment. All suggestions are very welcome. The box is a dual boot Linux / Windows but the windows partition could be drastically reduced in size if this is the real problem.
NAME AVAIL USED USEDSNAP USEDDS USEDREFRESERV USEDCHILD alexandria 1.06G 332G 320K 96K 0 332G alexandria@zfs-auto-snap_monthly-2019-07-13-0141 - 64K - - - - alexandria@zfs-auto-snap_monthly-2019-08-25-1034 - 0 - - - - alexandria@zfs-auto-snap_monthly-2019-10-09-0831 - 0 - - - - alexandria@zfs-auto-snap_monthly-2019-11-09-2312 - 0 - - - - alexandria@zfs-auto-snap_monthly-2019-12-09-1923 - 0 - - - - alexandria@zfs-auto-snap_monthly-2020-01-23-0728 - 0 - - - - alexandria@zfs-auto-snap_monthly-2020-02-27-0408 - 0 - - - -
alexandria/home 1.06G 332G 90.3G 242G 0 0 alexandria/home@zfs-auto-snap_monthly-2019-07-13-0141 - 328M - - - - alexandria/home@zfs-auto-snap_hourly-2019-07-18-0319 - 46.6M - - - - alexandria/home@zfs-auto-snap_hourly-2019-07-18-0818 - 37.5M - - - - alexandria/home@zfs-auto-snap_hourly-2019-07-19-0019 - 83.3M - - - - alexandria/home@zfs-auto-snap_monthly-2019-08-25-1034 - 282M - - - - alexandria/home@zfs-auto-snap_monthly-2019-10-09-0831 - 241M - - - - alexandria/home@zfs-auto-snap_monthly-2019-11-09-2312 - 787M - - - - alexandria/home@zfs-auto-snap_monthly-2019-12-09-1923 - 975M - - - - alexandria/home@zfs-auto-snap_monthly-2020-01-23-0728 - 513M - - - - alexandria/home@zfs-auto-snap_monthly-2020-02-27-0408 - 810M - - - - alexandria/home@zfs-auto-snap_monthly-2020-03-28-0921 - 754M - - - - alexandria/home@zfs-auto-snap_monthly-2020-04-27-1130 - 704M - - - -
Your pool 'alexandria' has - 1.06G of available capacity (AVAIL) - is using 332G (USED) - of which Snapshots are using 320K (USEDSNAP) - the dataset itself is using 96K (USEDDS) - of the USED capacity, 332G is in children of the dataset (USEDCHILD) Which in this case is in 'alexandria/home', presumably your home folder, and by the evidence you've listed is where all the action is. - 1.06G of available capacity (AVAIL) - is using 332G (USED) - of which Snapshots are using 90.3G (USEDSNAP) - the dataset itself is using 242G (USEDDS) Where is your root filesystem located? Wiser and more learned folk will give you a better answer but it will help if you can provide more data by sending the output of the following: sudo zpool list sudo zpool status sudo zfs list sudo zfs list -o space Here's what mine look like... ~$ sudo zpool list NAME SIZE ALLOC FREE EXPANDSZ FRAG CAP DEDUP HEALTH ALTROOT data 5.44T 2.75T 2.69T - 3% 50% 1.00x ONLINE - Here you can see my 'data' pool is at 50% capacity ~$ sudo zpool status pool: data state: ONLINE scan: scrub repaired 0 in 4h1m with 0 errors on Sun Aug 16 06:01:14 2020 config: NAME STATE READ WRITE CKSUM data ONLINE 0 0 0 mirror-0 ONLINE 0 0 0 sda ONLINE 0 0 0 sdb ONLINE 0 0 0 mirror-1 ONLINE 0 0 0 sdd ONLINE 0 0 0 sdc ONLINE 0 0 0 logs ata-OCZ-AGILITY3_OCZ-7FM2M2KI1395XLWG-part5 ONLINE 0 0 0 cache ata-OCZ-AGILITY3_OCZ-7FM2M2KI1395XLWG-part6 ONLINE 0 0 0 errors: No known data errors ~$ sudo zfs list -o space NAME AVAIL USED USEDSNAP USEDDS USEDREFRESERV USEDCHILD data 2.52T 2.75T 0 128K 0 2.75T data/backup 2.52T 50.1G 28.0G 22.1G 0 0 data/home 2.52T 29.6G 19.7G 9.92G 0 0 data/images 2.52T 959G 13.8G 945G 0 0 data/media 2.52T 1.72T 34.2G 1.69T 0 0 data/www 2.52T 14.7G 106M 14.6G 0 0 Here you can see for my larger datasets (images, media) that the snapshots are the lesser of the used capacity as that data is relatively static. Compare that to home and backup where changing data within the dataset causes the snapshot used space to grow larger than the dataset. BTW you can list the snapshots without doing ' sudo zpool set listsnapshots=on alexandria' thus sudo zfs list -o space -t snapshot or sudo zfs list -t snapshot or sudo zfs list -t all But I don't think that ZFS pool and it's dataset are the cause of your issues but it might be that the ZFS logs have consumed space. What does df -h show for your system? -- Colin Fee tfeccles@gmail.com