public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: Fabian Ebner <f.ebner@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [RFC manager 3/3] vzdump: new: add reminder to get rid of duplicate activate_storage
Date: Thu,  2 Dec 2021 12:00:05 +0100	[thread overview]
Message-ID: <20211202110005.38699-3-f.ebner@proxmox.com> (raw)
In-Reply-To: <20211202110005.38699-1-f.ebner@proxmox.com>

While it's unlikely that something breaks in practice, because
pvestatd calls activate_storage() for enabled storages every few
seconds, there's no rush to remove the duplicate call.

What could require the storage to be active between the activation in
new() and the activation in exec_backup() is:
1. An external storage plugin that requires the storage to be active
   for its get_subdir() implementation (unlikely to exist).
2. A job-start hook-script that requires the storage to be active.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
---
 PVE/VZDump.pm | 1 +
 1 file changed, 1 insertion(+)

diff --git a/PVE/VZDump.pm b/PVE/VZDump.pm
index 8c70906d..4a28e74f 100644
--- a/PVE/VZDump.pm
+++ b/PVE/VZDump.pm
@@ -501,6 +501,7 @@ sub new {
 
     if ($opts->{storage}) {
 	my $storage_cfg = PVE::Storage::config();
+	# FIXME: remove for PVE 8.0
 	# Ignore errors here. exec_backup will die if activation fails there.
 	eval { PVE::Storage::activate_storage($storage_cfg, $opts->{storage}) };
 
-- 
2.30.2





  parent reply	other threads:[~2021-12-02 11:00 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-02 11:00 [pve-devel] [PATCH manager 1/3] close #3476: allow user to prepare storage for activation in job-start hook Fabian Ebner
2021-12-02 11:00 ` [pve-devel] [RFC manager 2/3] vzdump: exec_backup: pick up latest version of storage.cfg after " Fabian Ebner
2021-12-02 11:00 ` Fabian Ebner [this message]
2022-01-14 11:46 ` [pve-devel] [PATCH manager 1/3] close #3476: allow user to prepare storage for activation in " Fabian Grünbichler
2022-01-14 12:39   ` Fabian Ebner
2022-01-14 13:07     ` Fabian Grünbichler

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=20211202110005.38699-3-f.ebner@proxmox.com \
    --to=f.ebner@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