From: Stoiko Ivanov <s.ivanov@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH common/container] fix syncfs usage for snapshot backup
Date: Thu, 17 Sep 2020 21:16:59 +0200 [thread overview]
Message-ID: <20200917191701.2236-1-s.ivanov@proxmox.com> (raw)
while investigating #2991 (and probably related #1911) I straced pvedaemon
noticing that the syncfs-calls all failed (errno EBADF).
This happens because we open the mountpoint path with O_PATH (open(2)), which
causes syncfs to fail.
Since I expect syncfs failing to be a potential cause for the inconstent
state of containers on ceph-storages while backing up in snapshot mode this
patchset hopefully mitigates the reported issues.
(if this is not the solution, I was also investigating calling
ioctl(fd, FIFREEZE) on the mountpoint before creating the snapshot)
The patch to pve-container is maybe not necessary, but should save us a few
syscalls, which don't help.
Would be grateful for review from more experienced eyes - I ran limted tests
with the patches applied - creating snapshot backups on a container with
lvmthin backed rootfs and on one with ceph backed rootfs.
pve-common
Stoiko Ivanov (1):
sync_mountpoint: open path so that sync works
src/PVE/Tools.pm | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
pve-container:
Stoiko Ivanov (1):
sync_container_namespace: skip virtual filesystems
src/PVE/LXC.pm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--
2.20.1
next reply other threads:[~2020-09-17 19:17 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-17 19:16 Stoiko Ivanov [this message]
2020-09-17 19:17 ` [pve-devel] [PATCH common 1/1] sync_mountpoint: open path so that sync works Stoiko Ivanov
2020-09-18 10:01 ` [pve-devel] applied: " Thomas Lamprecht
2020-09-17 19:17 ` [pve-devel] [PATCH container 1/1] sync_container_namespace: skip virtual filesystems Stoiko Ivanov
2020-09-18 10:07 ` Thomas Lamprecht
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200917191701.2236-1-s.ivanov@proxmox.com \
--to=s.ivanov@proxmox.com \
--cc=pve-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox