From: "Fabian Grünbichler" <f.gruenbichler@proxmox.com>
To: Aaron Lauterer <a.lauterer@proxmox.com>, pve-devel@lists.proxmox.com
Subject: Re: [pve-devel] [PATCH v2 qemu-server 1/5] disk reassign: add API endpoint
Date: Thu, 03 Sep 2020 11:07:51 +0200 [thread overview]
Message-ID: <1599123649.4ibqozwy6z.astroid@nora.none> (raw)
In-Reply-To: <d4a227a4-aa0e-90f6-2aa0-5271bad407c1@proxmox.com>
On September 3, 2020 10:30 am, Aaron Lauterer wrote:
>
>
> On 9/3/20 9:46 AM, Fabian Grünbichler wrote:
>> On September 1, 2020 2:44 pm, Aaron Lauterer wrote:
>
>
> [..]
>
>>> +
>>> + my $drive = PVE::QemuServer::parse_drive($disk, $conf->{$disk});
>>> + die "disk '$disk' has no associated volume\n" if !$drive->{file};
>>
>> missing check for whether it's actually volume-based, and not
>> pass-through.. what about templates/base volumes/linked
>> clones/snapshots?
>
> Passed through disks will fail later on in the code but having a check right away with a nicer error msg is probably a good idea. I haven't thought about templates, base volumes and linked clones yet. Same goes for Snapshots :/
>
> I guess we won't want to rename a ZFS dataset with snapshots present? Another thing is that renaming the dataset will most likely break replication.
>
from the top of my head, but please verify/check for missing stuff:
snapshot: can't re-assign if volume is referenced in a snapshot (would
invalidate that reference!), need to remove snapshot(s) first
base volume: does not make much sense (except if it does not have any clones, in
which case we could re-assign to another template but that seems rather
contrived)
linked volume: needs special handling in storage (pass and encode base
volume/template VMID so that new volid is still correct)
replicated source: reassigning from a VM that is replicated should work (from
replication's PoV, that's just like removing a disk -> it will get
cleaned up on the next run), but some special handling to also remove
the replication snapshots might be a good idea to return the volume to a
clean slate
replicated target: should work, but check that volume is replicatable
(like when adding a disk) might make sense?
next prev parent reply other threads:[~2020-09-03 9:07 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-01 12:44 [pve-devel] [PATCH v2 series 0/5] disk reassign: add new feature Aaron Lauterer
2020-09-01 12:44 ` [pve-devel] [PATCH v2 qemu-server 1/5] disk reassign: add API endpoint Aaron Lauterer
2020-09-03 7:46 ` Fabian Grünbichler
2020-09-03 8:30 ` Aaron Lauterer
2020-09-03 9:07 ` Fabian Grünbichler [this message]
2020-09-01 12:44 ` [pve-devel] [PATCH v2 qemu-server 2/5] cli: disk reassign: add reassign_disk to qm command Aaron Lauterer
2020-09-01 12:44 ` [pve-devel] [PATCH v2 storage 3/5] add disk reassign feature Aaron Lauterer
2020-09-03 7:55 ` Fabian Grünbichler
2020-09-01 12:44 ` [pve-devel] [PATCH v2 storage 4/5] disk reassign: add not implemented yet message to storages Aaron Lauterer
2020-09-03 7:58 ` Fabian Grünbichler
2020-09-03 9:01 ` Aaron Lauterer
2020-09-03 9:06 ` Aaron Lauterer
2020-09-03 9:19 ` Fabian Grünbichler
2020-09-01 12:44 ` [pve-devel] [PATCH v2 widget-toolkit 5/5] utils: task_desc_table: add qmreassign Aaron Lauterer
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=1599123649.4ibqozwy6z.astroid@nora.none \
--to=f.gruenbichler@proxmox.com \
--cc=a.lauterer@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