weizhouapache commented on issue #8703: URL: https://github.com/apache/cloudstack/issues/8703#issuecomment-1963562116
> @weizhouapache > > ``` > mysql> show create table vm_template \G; > *************************** 1. row *************************** > Table: vm_template > Create Table: CREATE TABLE `vm_template` ( > `id` bigint unsigned NOT NULL AUTO_INCREMENT, > `unique_name` varchar(255) NOT NULL, > `name` varchar(255) NOT NULL, > `uuid` varchar(40) DEFAULT NULL, > `public` int unsigned NOT NULL, > `featured` int unsigned NOT NULL, > `type` varchar(32) DEFAULT NULL, > `hvm` int unsigned NOT NULL COMMENT 'requires HVM', > `bits` int unsigned NOT NULL COMMENT '32 bit or 64 bit', > `url` varchar(255) DEFAULT NULL COMMENT 'the url where the template exists externally', > `format` varchar(32) NOT NULL COMMENT 'format for the template', > `created` datetime NOT NULL COMMENT 'Date created', > `removed` datetime DEFAULT NULL COMMENT 'Date removed if not null', > `account_id` bigint unsigned NOT NULL COMMENT 'id of the account that created this template', > `checksum` varchar(255) DEFAULT NULL COMMENT 'checksum for the template root disk', > `display_text` varchar(4096) DEFAULT NULL COMMENT 'Description text set by the admin for display purpose only', > `enable_password` int unsigned NOT NULL DEFAULT '1' COMMENT 'true if this template supports password reset', > `enable_sshkey` int unsigned NOT NULL DEFAULT '0' COMMENT 'true if this template supports sshkey reset', > `guest_os_id` bigint unsigned NOT NULL COMMENT 'the OS of the template', > `bootable` int unsigned NOT NULL DEFAULT '1' COMMENT 'true if this template represents a bootable ISO', > `prepopulate` int unsigned NOT NULL DEFAULT '0' COMMENT 'prepopulate this template to primary storage', > `cross_zones` int unsigned NOT NULL DEFAULT '0' COMMENT 'Make this template available in all zones', > `extractable` int unsigned NOT NULL DEFAULT '0' COMMENT 'Is this template extractable', > `hypervisor_type` varchar(32) DEFAULT NULL COMMENT 'hypervisor that the template belongs to', > `source_template_id` bigint unsigned DEFAULT NULL COMMENT 'Id of the original template, if this template is created from snapshot', > `template_tag` varchar(255) DEFAULT NULL COMMENT 'template tag', > `sort_key` int NOT NULL DEFAULT '0' COMMENT 'sort key used for customising sort method', > `size` bigint unsigned DEFAULT NULL, > `state` varchar(255) DEFAULT NULL, > `update_count` bigint unsigned DEFAULT NULL, > `updated` datetime DEFAULT NULL, > `dynamically_scalable` tinyint unsigned NOT NULL DEFAULT '0' COMMENT 'true if template contains XS/VMWare tools inorder to support dynamic scaling of VM cpu/memory', > `parent_template_id` bigint unsigned DEFAULT NULL COMMENT 'If datadisk template, then id of the root template this template belongs to', > `direct_download` tinyint(1) DEFAULT '0' COMMENT 'Indicates if Secondary Storage is bypassed and template is downloaded to Primary Storage', > `deploy_as_is` tinyint(1) NOT NULL DEFAULT '0' COMMENT 'True if the template should be deployed with disks and networks as defined by OVF', > `user_data_id` bigint unsigned DEFAULT NULL COMMENT 'id of the user data', > `user_data_link_policy` varchar(255) DEFAULT NULL COMMENT 'user data link policy with template', > PRIMARY KEY (`id`), > UNIQUE KEY `uc_vm_template__uuid` (`uuid`), > KEY `i_vm_template__removed` (`removed`), > KEY `i_vm_template__public` (`public`), > KEY `fk_vm_template__user_data_id` (`user_data_id`), > CONSTRAINT `fk_vm_template__user_data_id` FOREIGN KEY (`user_data_id`) REFERENCES `user_data` (`id`) > ) ENGINE=InnoDB AUTO_INCREMENT=211 DEFAULT CHARSET=utf8mb3 > ``` thanks @kiranchavala It looks like relates to the non-existing `removed` column in `user_data`. Once userdata is removed, the record is gone from `user_data` table. cc @harikrishna-patnala -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
