shiftfs: drop entries from cache on unlink
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
linux (Ubuntu) |
Fix Released
|
Undecided
|
Christian Brauner | ||
Disco |
Fix Released
|
Medium
|
Christian Brauner |
Bug Description
SRU Justification
Impact: LXD on Ubuntu runs on top of zfs by defaults. Users that make use of shiftfs for efficient id-shifting currently hit a bug where zfs is confused about the amount of space that is used in a dataset. For example, creating a file with 1GB of random data will increase the space used by the dataset by 1GB. When the file is removed via rm the space is not freed for zfs. This leads to zfs running out of space pretty quickly.
This bug has been observed, described, and reproduced here https:/
Regression Potential: Limited to shiftfs. This patch has been tested on various backends btrfs, dir, zfs to verify that it doesn't regress other workloads. Shiftfs now also aligns more closely with overlayfs on file deletion.
Test Case:
sudo snap install lxd
sudo snap set lxd shiftfs.enable=true
sudo systemctl restart snap.lxd.daemon
sudo lxd init # make sure to select zfs as backend
sudo lxc launch images:
sudo lxc exec b1 -- dd if=/dev/urandom bs=1M count=1000 of=dummy.file
sudo zfs list default/
sudo lxc exec b1 -- rm dummy.file
sudo zfs list default/
Target Kernels: All LTS kernels with shiftfs support.
CVE References
Changed in linux (Ubuntu): | |
assignee: | nobody → Christian Brauner (cbrauner) |
status: | New → In Progress |
Changed in linux (Ubuntu): | |
status: | In Progress → Fix Committed |
Changed in linux (Ubuntu Disco): | |
importance: | Undecided → Medium |
Changed in linux (Ubuntu Disco): | |
status: | New → Fix Committed |
tags: |
added: verification-done-disco removed: verification-needed-disco |
Changed in linux (Ubuntu Disco): | |
assignee: | nobody → Christian Brauner (cbrauner) |
This bug was fixed in the package linux - 5.3.0-10.11
---------------
linux (5.3.0-10.11) eoan; urgency=medium
* eoan/linux: 5.3.0-10.11 -proposed tracker (LP: #1843232)
* No sound inputs from the external microphone and headset on a Dell machine pin_fixup_ tbl for alc269 family
(LP: #1842265)
- SAUCE: ALSA: hda - Expand pin_match function to match upcoming new tbls
- SAUCE: ALSA: hda - Define a fallback_
* Horizontal corrupted line at top of screen caused by framebuffer compression
(LP: #1840236)
- SAUCE: drm/i915/fbc: disable framebuffer compression on IceLake
* Add bpftool to linux-tools-common (LP: #1774815)
- [Debian] package bpftool in linux-tools-common
* Miscellaneous Ubuntu changes
- update dkms package versions
[ Upstream Kernel Changes ]
* Rebase to v5.3-rc8
-- Paolo Pisati <email address hidden> Mon, 09 Sep 2019 10:00:41 +0200