all lists on lists.proxmox.com
 help / color / mirror / Atom feed
From: Fiona Ebner <f.ebner@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [PATCH storage 2/3] zfspool plugin: clone image: use zfs_get_properties() helper
Date: Mon,  6 Jul 2026 11:40:33 +0200	[thread overview]
Message-ID: <20260706094223.54701-3-f.ebner@proxmox.com> (raw)
In-Reply-To: <20260706094223.54701-1-f.ebner@proxmox.com>

No functional change intended.

Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
---
 src/PVE/Storage/ZFSPoolPlugin.pm | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/src/PVE/Storage/ZFSPoolPlugin.pm b/src/PVE/Storage/ZFSPoolPlugin.pm
index 0531a5d..c463112 100644
--- a/src/PVE/Storage/ZFSPoolPlugin.pm
+++ b/src/PVE/Storage/ZFSPoolPlugin.pm
@@ -725,10 +725,7 @@ sub clone_image {
     my $name = $class->find_free_diskname($storeid, $scfg, $vmid, $format);
 
     if ($format eq 'subvol') {
-        my $size = $class->zfs_request(
-            $scfg, undef, 'list', '-Hp', '-o', 'refquota', "$scfg->{pool}/$basename",
-        );
-        chomp($size);
+        my $refquota = $class->zfs_get_properties($scfg, 'refquota', "$scfg->{pool}/$basename");
         $class->zfs_request(
             $scfg,
             undef,
@@ -736,7 +733,7 @@ sub clone_image {
             "$scfg->{pool}/$basename\@$snap",
             "$scfg->{pool}/$name",
             '-o',
-            "refquota=$size",
+            "refquota=$refquota",
         );
     } else {
         $class->zfs_request(
-- 
2.47.3





  parent reply	other threads:[~2026-07-06  9:43 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-06  9:40 [PATCH-SERIES storage 0/3] zfspool plugin: fix container rollback and linked clone with refquota=none Fiona Ebner
2026-07-06  9:40 ` [PATCH storage 1/3] zfspool plugin: fix regression for rollback " Fiona Ebner
2026-07-06  9:40 ` Fiona Ebner [this message]
2026-07-06  9:40 ` [PATCH storage 3/3] zfspool plugin: clone: fix linked clone of container subvol " Fiona Ebner
2026-07-06 10:22 ` [PATCH-SERIES storage 0/3] zfspool plugin: fix container rollback and linked clone " Filip Schauer

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=20260706094223.54701-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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal