[pve-devel] Adding creation time as metadata field to VM/containers?

Thomas Lamprecht t.lamprecht at proxmox.com
Wed Jun 10 08:47:01 CEST 2020


Hi,

On 6/9/20 11:13 PM, Victor Hooi wrote:
> Hi,
> 
> Is there any chance of adding creation time as a queryable metadata field
> for VMs/containers?
> 
> The use-case for us is - we want to know the overall age of a machine, for
> things like patching schedules etc. (We want to auto-kill machines beyond a
> certain age).

I thought about this too recently, initially I hoped that we could just return the
"create time" of the config file as an really cheap and normally true creation time,
but then remembered that our the pmxcfs saves only modification time and sets that
for all, atime, mtime, ctime.

As a workaround for now, you could use the "description" to save some structured
data which includes this info, e.g., in JSON or the like format.

I'd be open to have metadata field, maybe it could also host Dominik's tag he has
in the works - so we'd only have one such field in the config.

cheers,
Thomas




More information about the pve-devel mailing list