-----Original Message-----
From: Daniel P. Berrangé <berrange(a)redhat.com>
Subject: Re: [PATCH rfcv3 11/11] conf: Add support to keep same domid for
hard reboot
On Mon, Nov 27, 2023 at 04:55:21PM +0800, Zhenzhong Duan wrote:
> After hard reboot, domid is increased by 1 as a new domain.
> Hard reboot simulate TD-guest reboot by calling qemuProcessStop
> and qemuProcessStart which will release and recreate domain
> resource including domid.
This is risky.
We use 'domid' as a mechanism to *guarantee* certain paths
are unique when re-spawning QEMU, so re-using domid for
a new QEMU is liable to cause bugs.
The domain ID is not guest visible, so we don't need to
preserve it from that POV.
I think we should just document domid is going to change
for confidential guests when the reboot is faked.
Most mgmt apps focus on UUID for most of their work
anyway, with domain ID largely irrelevant beyond it
being presented in users in a few places.
OK, will drop this patch.
Thanks
Zhenzhong