apache / cloudstack

Apache CloudStack is an opensource Infrastructure as a Service (IaaS) cloud computing platform
https://cloudstack.apache.org/
Apache License 2.0
2.06k stars 1.1k forks source link

Template reported as Ready/Installed only based on the template_stor_ref, ignoring template_zone_ref #8388

Closed andrijapanicsb closed 5 months ago

andrijapanicsb commented 10 months ago

ACS 4.18.1

As the title says:

image

Reproduce the issue (with systemVM template specifically, can be tested with User templates):

This can be fixed by simply adding a record back to the zone ref table, for the correct template_id and that's all.

Problem: The UI (and/or API) should not show template as Ready and available only based on the template_store_ref

Proposal: improve it to explain that either 1) Template is not ready in the given Zone or 2) Say that the template is installed, but not "registered" in that specific Zone

weizhouapache commented 10 months ago

@andrijapanicsb did you face the issue in other scenario ? for example, add new zone ? I wonder if there is a way to reproduce the issue without manual db changes.

andrijapanicsb commented 10 months ago

I faced the issue when triggering template auto-install for ADDITIONAL zone, while (by mistake) the template was not marked as cross_zone=1 (it was =0)

Not sure if this might be an isolated case and how this could be visible for other templates.

weizhouapache commented 5 months ago

Fixed by https://github.com/apache/cloudstack/pull/8395