Migration 185 does not downgrade on MySQL
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Undecided
|
Joshua Hesketh |
Bug Description
When downgrading migration 185 I get the following error:
OperationalError: (OperationalError) (1061, "Duplicate key name 'virtual_
The virtual_interfaces table has a virtual_
CREATE TABLE `virtual_
`created_at` datetime DEFAULT NULL,
`updated_at` datetime DEFAULT NULL,
`deleted_at` datetime DEFAULT NULL,
`id` int(11) NOT NULL AUTO_INCREMENT,
`address` varchar(255) DEFAULT NULL,
`network_id` int(11) DEFAULT NULL,
`uuid` varchar(36) DEFAULT NULL,
`instance_uuid` varchar(36) DEFAULT NULL,
`deleted` int(11) DEFAULT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `address` (`address`),
KEY `network_id` (`network_id`),
KEY `virtual_
CONSTRAINT `virtual_
) ENGINE=InnoDB DEFAULT CHARSET=utf8
After the 185 upgrade the key still exists. I believe this is because it is not a UNIQUE key and utils.drop_
CREATE TABLE `virtual_
`created_at` datetime DEFAULT NULL,
`updated_at` datetime DEFAULT NULL,
`deleted_at` datetime DEFAULT NULL,
`id` int(11) NOT NULL AUTO_INCREMENT,
`address` varchar(255) DEFAULT NULL,
`network_id` int(11) DEFAULT NULL,
`uuid` varchar(36) DEFAULT NULL,
`instance_uuid` varchar(36) DEFAULT NULL,
`deleted` int(11) DEFAULT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `address` (`address`),
UNIQUE KEY `uniq_virtual_
KEY `network_id` (`network_id`),
KEY `virtual_
CONSTRAINT `virtual_
) ENGINE=InnoDB DEFAULT CHARSET=utf8
So when downgrading 185 the virtual_
Changed in nova: | |
assignee: | nobody → Joshua Hesketh (joshua.hesketh) |
description: | updated |
description: | updated |
Changed in nova: | |
milestone: | none → havana-3 |
status: | Fix Committed → Fix Released |
Changed in nova: | |
milestone: | havana-3 → 2013.2 |
Fix proposed to branch: master /review. openstack. org/39709
Review: https:/