]> git.proxmox.com Git - pve-container.git/commit
fix #4470: pct fstrim: ignore bind or read-only mountpoints
authorFriedrich Weber <f.weber@proxmox.com>
Mon, 20 Feb 2023 10:04:45 +0000 (11:04 +0100)
committerWolfgang Bumiller <w.bumiller@proxmox.com>
Mon, 20 Feb 2023 10:27:30 +0000 (11:27 +0100)
commit22be1b3f80645938974d99e98ae8b495d7425e09
tree083a716224a04da7ab84cecc1c6f543c75b20337
parent0d1d137eb10bd49fdcc12b397b2ed817d6ba2dc7
fix #4470: pct fstrim: ignore bind or read-only mountpoints

Currently, `pct fstrim` will run `fstrim` on all mountpoints
of the container, including bind and read-only mountpoints.

However, trimming a bind mountpoint might trim a host
filesystem, which users may not expect. Also, trimming can
be considered a write operation, which users may not expect
to be carried out on a read-only mountpoint.

Hence, exclude bind mointpoints and read-only mountpoints
from trimming.

Signed-off-by: Friedrich Weber <f.weber@proxmox.com>
src/PVE/CLI/pct.pm