From: Oguz Bektas <o.bektas@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH container] api: clone_vm: don't include 'parent' property in clones
Date: Tue, 12 Oct 2021 15:32:36 +0200 [thread overview]
Message-ID: <20211012133236.1533765-1-o.bektas@proxmox.com> (raw)
apparently this caused a weird[0] bug... when a container with a
snapshot 'foo' was cloned, it would take 'parent: foo' from the original
container. when you add a new snapshot 'bar' to the cloned container,
and then another one 'foo', this causes the snapshots to become parents
of each other (thus not parsed correctly in the tree view of GUI nor
with 'pct listsnapshot CTID')
[0]: https://forum.proxmox.com/threads/snapshots-of-one-lxc-disappeared.97711/
Signed-off-by: Oguz Bektas <o.bektas@proxmox.com>
---
src/PVE/API2/LXC.pm | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/PVE/API2/LXC.pm b/src/PVE/API2/LXC.pm
index 1f2f1f0..15a1926 100644
--- a/src/PVE/API2/LXC.pm
+++ b/src/PVE/API2/LXC.pm
@@ -1515,6 +1515,7 @@ __PACKAGE__->register_method({
delete $newconf->{snapshots};
delete $newconf->{pending};
delete $newconf->{template};
+ delete $newconf->{parent};
if ($param->{hostname}) {
$newconf->{hostname} = $param->{hostname};
}
--
2.30.2
next reply other threads:[~2021-10-12 13:32 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-12 13:32 Oguz Bektas [this message]
2021-10-13 9:12 ` Fabian 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=20211012133236.1533765-1-o.bektas@proxmox.com \
--to=o.bektas@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