public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: Christoph Heiss <c.heiss@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH manager/storage] fix #4289: wait for backup verification to finish before updating volume attribute
Date: Mon,  2 Jan 2023 13:36:31 +0100	[thread overview]
Message-ID: <20230102123633.2493599-1-c.heiss@proxmox.com> (raw)

When creating a backup to a PBS datastore which has the 'Verify New'
flag set, the backup will fail with an "unable to set protected flag"
error. This is due to the volume being immediately locked by the PBS
server for verifying, before PVE has a chance to set the 'protected'
flag.

Fix this by waiting on the verification job to finish before attempting
to set the volume flag.

[ This is really more of an RFC if it even can be done in this 'naive' way: It
feels a bit hacky, esp. the matching of the `worker_id` value, since this can
be an arbitrary string according to the documentation. Maybe there is a better
way to check for that? Also, should this use some timeout just to be safe? ]

Christoph Heiss (1):
      vzdump: pass logfunc down into storage plugin when updating volume attribute

 PVE/VZDump.pm | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

Christoph Heiss (1):
      fix #4289: pbs: wait for backup verification to finish before updating volume attribute

 PVE/Storage.pm           |  4 ++--
 PVE/Storage/PBSPlugin.pm | 27 ++++++++++++++++++++++++++-
 2 files changed, 28 insertions(+), 3 deletions(-)




             reply	other threads:[~2023-01-02 12:37 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-02 12:36 Christoph Heiss [this message]
2023-01-02 12:36 ` [pve-devel] [PATCH manager] vzdump: pass logfunc down into storage plugin when " Christoph Heiss
2023-01-02 12:36 ` [pve-devel] [PATCH storage] fix #4289: pbs: wait for backup verification to finish before " Christoph Heiss
2023-01-04 10:50   ` Fiona Ebner
2023-01-10 11:11     ` Christoph Heiss
2023-01-10 12:34       ` Fiona Ebner
2023-01-10 12:44         ` Christoph Heiss
     [not found]           ` <159837ba-f916-7b03-2cab-8e486b38b6bb@proxmox.com>
2023-01-10 13:21             ` Fiona Ebner

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=20230102123633.2493599-1-c.heiss@proxmox.com \
    --to=c.heiss@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
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal