lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <90a2061e-e358-a608-0d12-38f747fa5e93@secunet.com>
Date:   Tue, 4 Sep 2018 11:11:27 +0200
From:   Torsten Hilbrich <torsten.hilbrich@...unet.com>
To:     <linux-ext4@...r.kernel.org>
CC:     "Theodore Y. Ts'o" <tytso@....edu>
Subject: Free space can be larger that size of volume if doing online resizing

I noticed a problem when doing ext4 online resizing and using according
resize parameters when creating the file system to allow for larger size
increase.

The problem was initially found on kernel v4.14.65, but I could verify
that it is still present in v4.19-rc2.

The script performs the following actions:

- a logical volume is created
- a new file system is created within
- the file system is mounted
- the logical volume size is increased
- the file system is resized
=> here the df already reports a free size larger than the size of the
file system

df -h /mnt
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/vg-foo31  1.1G  -16T   17T    - /mnt

- the file system is resized to a larger size
=> here the resize2fs will loop forever because a underflow happens
there when processing the file system information

A script for reproducing the problem as attached as reproducer, its
output is attached as reproducer.log

I already contacted tytso@....edu as Maintainer of the e2fsprogs and he
told me it seems to be a problem with the online resizing in the kernel.

I noticed that the problems disappears if I reduced the resize option to
a third of the value (357913941 instead of the current 1073741824).

With Regards,

	Torsten Hilbrich

View attachment "reproducer.log" of type "text/x-log" (1504 bytes)

View attachment "reproducer" of type "text/plain" (412 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ