If a virtual machine template file is deleted from the repository file system outside of Abiquo, it will still be visible in the appliance library. However, an error (virtual machine template not present in the repository) will occur if you try to deploy a virtual machine using this template. A virtual machine template is not logically deleted from the appliance library when the template file is deleted. You must delete it manually in the GUI as described above, or by other means, for example, using the API.
You can delete any template (master or instance template) that is not in use. A template is not in use when it is not used in a virtual machine and it does not have any dependent instances.
Dependent instances are instances that have not been promoted to master templates. When you promote an instance to a master template, a copy of the original instance is made, so you can delete the original instance when the promotion is complete.
To remove a template that is not in use, move the mouse over the template and click the delete button that appears. Abiquo will remove the template from the appliance library and the NFS repository file system.
To prevent users from creating new virtual machines from a master template, you can make the template unavailable. This means the template disk file is removed from the NFS Repository.
You can only make a template unavailable using the Abiquo GUI if it is in use, i.e. it is used in a virtual machine or it has dependent instances.
To make a template unavailable, move the mouse over the template that is in use and click the delete buttonthat appears.
Abiquo will delete the disk file but not the template definition. Abiquo will mark this template as unavailable. The template will disappear from the Apps Library view.
Select the checkbox to display Deleted Templates, which are unavailable templates with no disk files. The template will display again and it will be marked with an X.
Here is a simple example of the process of deleting a template. An enterprise downloads a virtual machine template from remote repository. A virtual machine is deployed from the template. Modifications are made to the virtual machine. An instance is created from the deployed virtual machine. A new virtual machine is deployed from the instance. An instance is created from the new virtual machine.
Screenshot: Deploy an instance of the Core in a new virtual machine
Screenshot: There are now two virtual machines - one with the core template and one with an instance of the core template VM
Screenshot: The core template has two instances: Core_Instance_1 and Core_Instance_1_Instance_1
If virtual machines or instances are using a template, you cannot delete it. However, you can make the template unavailable, which means that the template disk file is deleted and it cannot be used to create new virtual machines or instances. The process is the same as for deleting a template–Abiquo will warn you if the template is in use.
Only the owner of a shared template can delete the shared template disk. This template will only be marked as unavailable for all users when the template owner performs a refresh of the Apps Library. The Cloud Admin user can see all templates and virtual machines linked to a shared template for all enterprises.
If a template file is deleted from the NFS repository, the template will become unavailable. However, you can download the template again from the remote repository to restore it.
Note that it is also possible to download a new version of the template disk to replace the other version. User machines that are redeployed will automatically use the new version of the template.
You cannot delete a template that is unavailable if it has:
If you try to delete this template, you will see a message that the template is already unavailable. You can delete the template after you remove the instances and deployed virtual machines.