Where did 35 GB go?

I used a 320 GB disk for installing FreeBSD 12.0. Just the most automatic installation. I see now that 35 GB disappeared. It seems I will need to install again. Are 35 GB to few today to care about? Any idea what happened?

The kernel oversaw 15 GB

Code:
ada0 at ahcich2 bus 0 scbus2 target 0 lun 0
ada0: <WDC WD3200BUCT-63TWBY0 01.01A02> ATA8-ACS SATA 2.x device
ada0: Serial Number WD-WX41A4395693
ada0: 300.000MB/s transfers (SATA 2.x, UDMA6, PIO 8192bytes)
ada0: Command Queueing enabled
ada0: 305245MB (625142448 512 byte sectors)

And the installer ommitted 20 GB more:

Code:
# df -h
Filesystem            Size    Used   Avail Capacity  Mounted on
zroot/ROOT/default    285G    2.5G    282G     1%    /
devfs                 1.0K    1.0K      0B   100%    /dev
zroot/tmp             282G    120K    282G     0%    /tmp
zroot/usr/home        283G    440M    282G     0%    /usr/home
zroot/usr/ports       283G    718M    282G     0%    /usr/ports
zroot/usr/src         283G    682M    282G     0%    /usr/src
zroot/var/audit       282G     88K    282G     0%    /var/audit
zroot/var/crash       282G     88K    282G     0%    /var/crash
zroot/var/log         282G    244K    282G     0%    /var/log
zroot/var/mail        282G    112K    282G     0%    /var/mail
zroot/var/tmp         282G     88K    282G     0%    /var/tmp
zroot                 282G     88K    282G     0%    /zroot
 
Last edited by a moderator:
Code:
$ echo $((305245 * 1024 * 1024))
320072581120
$ echo $((625142448 * 512))
320072933376
-> 320.07GB

The kernel's message uses binary prefixes here. Might be a good idea to change those message to read "MiB" instead of "MB" that people always confuse with the standard decimal prefixes.

And the installer ommitted 20 GB more:
Code:
$ echo $((285 * 1024 * 1024 * 1024))
306016419840
So, in fact, ZFS just "eats" roughly 14 GB. This is used for filesystem structures, metadata, etc.
 
I forgot 2 GB for sawp. So, 12 GB are lost.

Not long ago I used a computer with a 10 GB disk.
 
I forgot 2 GB for sawp. So, 12 GB are lost.
Well, at most -- I assume your swap space is 2 GiB, not 2 GB (which is a difference of 147.5 MB). And then, even the partition table needs some space.

Furthermore, it isn't "lost", it's put to good use, so you can manage files at all :) Plus some other goodies ZFS provides, like e.g. checksumming. Oh, and ZFS can compress on the fly ...
 
And then, even the partition table needs some space.

You see the number of sectors in the dmesg. Then you can calculate:

625142448*512 - 305245*1024*1024 = 352256

This ZFS is in tha main disc with the system. I would have preferred to have UFS, but since I have a raid
with 2 ZFS disks and read that the combination ZFS+UFS does not work good, I put also here ZFS.

By the way:

Code:
# gpart show ada0
=>       40  625142368  ada0  GPT  (298G)
         40       1024     1  freebsd-boot  (512K)
       1064        984        - free -  (492K)
       2048    4194304     2  freebsd-swap  (2.0G)
    4196352  620945408     3  freebsd-zfs  (296G)
  625141760        648        - free -  (324K)
 
Last edited by a moderator:
To a certain degree, the bigger the volume, the bigger its metadata. A filesystem needs some space to store all those structures that describe the partition itself and all the files stored on it, as well as all the backup copies of all these structures that are used to ensure its internal consistency.

Not long ago I used a computer with a 10 GB disk.
And you probably could still get away with it, even using FreeBSD 12. The system itself only got slightly bigger in the latest version compared to all versions that preceded it in, say, the past decade. But you'd probably want to stick to UFS then.
 
And you probably could still get away with it, even using FreeBSD 12.

Of course. Look this thread:


The stick has 4 GB and it is not full after installation.
 
Back
Top