Skip to content

Commit 51166a8

Browse files
committed
Add SQL query to enable KVM + storage motion
1 parent af1d503 commit 51166a8

2 files changed

Lines changed: 7 additions & 1 deletion

File tree

engine/schema/src/main/resources/META-INF/db/schema-41000to41100.sql

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -426,6 +426,7 @@ INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (uuid, hypervisor_type, hypervi
426426
-- Add XenServer 7.2 hypervisor guest OS mappings (copy 7.1.0 & remove Windows Vista, Windows XP, Windows 2003, CentOS 4.x, RHEL 4.xS, LES 10 (all versions) as per XenServer 7.2 Release Notes)
427427
INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) SELECT UUID(),'Xenserver', '7.2.0', guest_os_name, guest_os_id, utc_timestamp(), 0 FROM `cloud`.`guest_os_hypervisor` WHERE hypervisor_type='Xenserver' AND hypervisor_version='7.1.0' AND guest_os_id not in (1,2,3,4,56,101,56,58,93,94,50,51,87,88,89,90,91,92,26,27,28,29,40,41,42,43,44,45,96,97,107,108,109,110,151,152,153);
428428

429+
<<<<<<< HEAD:engine/schema/src/main/resources/META-INF/db/schema-41000to41100.sql
429430
-- Add table to track primary storage in use for snapshots
430431
DROP TABLE IF EXISTS `cloud_usage`.`usage_snapshot_on_primary`;
431432
CREATE TABLE `cloud_usage`.`usage_snapshot_on_primary` (

engine/schema/src/main/resources/META-INF/db/schema-41100to41200.sql

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,9 @@ ALTER TABLE `cloud`.`network_acl_item` ADD COLUMN `reason` VARCHAR(2500) AFTER `
2626
ALTER TABLE `cloud`.`alert` ADD COLUMN `content` VARCHAR(5000);
2727

2828
-- Fix the name of the column used to hold IPv4 range in 'vlan' table.
29-
ALTER TABLE `vlan` CHANGE `description` `ip4_range` varchar(255);
29+
ALTER TABLE `vlan` CHANGE `description` `ip4_range` varchar(255);
30+
31+
-- Enable storage motion for KVM hypervisor
32+
UPDATE `cloud`.`hypervisor_capabilities`
33+
SET `storage_motion_supported` = 1
34+
WHERE `hypervisor_capabilities`.`hypervisor_type` = 'KVM';

0 commit comments

Comments
 (0)