View Full Version : SLES 12 SP1 df shows on btrfs wrong disk size

23-Mar-2016, 14:42

I hope someone can explain this behavior:

I have a virtual machine (hypervisor ESXi 5.X), installed OS is SLES 12 SP 1 and the used filesystem is btrfs.
I know that btrfs and df are showing different values for used and free space.
But I don't know how I should understand, that df shows a bigger partition then configured.

The root partition is 28,5 GiB big and I get these values:

- df - size 37GB

sles12vm:~ # df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sda2 37G 9.1G 19G 34% /
devtmpfs 939M 0 939M 0% /dev
tmpfs 948M 0 948M 0% /dev/shm
tmpfs 948M 9.7M 938M 2% /run
tmpfs 948M 0 948M 0% /sys/fs/cgroup
/dev/sda2 37G 9.1G 19G 34% /var/tmp
/dev/sda2 37G 9.1G 19G 34% /var/spool
/dev/sda2 37G 9.1G 19G 34% /var/lib/pgsql
/dev/sda2 37G 9.1G 19G 34% /var/crash
/dev/sda2 37G 9.1G 19G 34% /tmp
/dev/sda2 37G 9.1G 19G 34% /srv
/dev/sda2 37G 9.1G 19G 34% /var/opt
/dev/sda2 37G 9.1G 19G 34% /var/log
/dev/sda2 37G 9.1G 19G 34% /var/lib/named
/dev/sda2 37G 9.1G 19G 34% /var/lib/mailman
/dev/sda2 37G 9.1G 19G 34% /usr/local
/dev/sda2 37G 9.1G 19G 34% /home
/dev/sda2 37G 9.1G 19G 34% /opt
/dev/sda2 37G 9.1G 19G 34% /boot/grub2/x86_64-efi
/dev/sda2 37G 9.1G 19G 34% /boot/grub2/i386-pc

- btrfs

sles12vm:~ # btrfs filesystem show /
Label: none uuid: 5e77d6a7-b282-49ba-9417-ccb688be3b02
Total devices 1 FS bytes used 8.44GiB
devid 1 size 28.54GiB used 11.28GiB path /dev/sda2

So from where get's df the additional 9~ GiB ?


D. Stabla

Automatic reply
28-Mar-2016, 05:30

It appears that in the past few days you have not received a response to your
posting. That concerns us, and has triggered this automated reply.

These forums are peer-to-peer, best effort, volunteer run and that if your issue
is urgent or not getting a response, you might try one of the following options:

- Visit http://www.suse.com/support and search the knowledgebase and/or check all
the other support options available.
- Open a service request: https://www.suse.com/support
- You could also try posting your message again. Make sure it is posted in the
correct newsgroup. (http://forums.suse.com)

Be sure to read the forum FAQ about what to expect in the way of responses:

If this is a reply to a duplicate posting or otherwise posted in error, please
ignore and accept our apologies and rest assured we will issue a stern reprimand
to our posting bot..

Good luck!

Your SUSE Forums Team

28-Mar-2016, 11:29
Could you please paste the output of the below command ?

# btrfs filesystem usage /

03-Jun-2016, 08:44

sorry for the late reply.

sles12vm:~ # btrfs filesystem usage /
Device size: 28.54GiB
Device allocated: 18.92GiB
Device unallocated: 9.62GiB
Device missing: 0.00B
Used: 16.47GiB
Free (estimated): 10.97GiB (min: 6.16GiB)
Data ratio: 1.00
Metadata ratio: 2.00
Global reserve: 320.00MiB (used: 0.00B)

Data,single: Size:16.00GiB, Used:14.65GiB
/dev/sda2 16.00GiB

Metadata,DUP: Size:1.43GiB, Used:931.41MiB
/dev/sda2 2.85GiB

System,DUP: Size:32.00MiB, Used:16.00KiB
/dev/sda2 64.00MiB

/dev/sda2 9.62GiB


D. Stabla

06-Jun-2016, 10:53
(sorry, wrong response)