Just bumped master to 4.4.0 and Wido did the upgrade scripts

Cheers,

Hugo

On 21 nov. 2013, at 16:19, Alex Huang <alex.hu...@citrix.com> wrote:

> Here's a wiki page about it. 
> 
> https://cwiki.apache.org/confluence/display/CLOUDSTACK/DB+Upgrade+in+CloudStack
> 
> --Alex
> 
>> -----Original Message-----
>> From: Syed Ahmed [mailto:sah...@cloudops.com]
>> Sent: Wednesday, November 20, 2013 12:37 PM
>> To: dev@cloudstack.apache.org
>> Cc: Wei ZHOU
>> Subject: Re: Error while running master
>> 
>> Is this change going in 4.3? Is so then the Alter table I guess should be in
>> schema-421to430.sql. I don't see a schema-430to440.sql though.
>> How deploydb read the files? Does it go through all the schema files or does
>> it pick the latest one?
>> 
>> 
>> Thanks,
>> -Syed
>> 
>> 
>> On Wed 20 Nov 2013 03:24:37 PM EST, Wei ZHOU wrote:
>>> Wido committed 1edaa36cc68e845a42339d5f267d49c82343aefb today.
>>> try after "ALTER TABLE  disk_offering ADD COLUMN cache_mode
>> varchar(20)"
>>> I do not know which schema file should be inserted into,
>>> schema-421to430.sql or schema-430to440.sql ?
>>> 
>>> 2013/11/20 Syed Ahmed <sah...@cloudops.com>
>>> 
>>>> Hi All,
>>>> 
>>>> I am facing the following error when running the latest master. I have
>>>> done a clean compile and have dropped and created the db again.
>>>> 
>>>> [WARNING] Nested in
>> org.springframework.context.ApplicationContextException:
>>>> Failed to start bean 'cloudStackLifeCycle'; nested exception is
>>>> com.cloud.utils.exception.CloudRuntimeException: DB Exception on:
>>>> com.mysql.jdbc.JDBC4PreparedStatement@538a1556: SELECT
>> disk_offering.id,
>>>> disk_offering.domain_id, disk_offering.unique_name,
>> disk_offering.name,
>>>> disk_offering.display_text, disk_offering.disk_size, disk_offering.tags,
>>>> disk_offering.type, disk_offering.removed, disk_offering.created,
>>>> disk_offering.recreatable, disk_offering.use_local_storage,
>>>> disk_offering.system_use, disk_offering.customized, disk_offering.uuid,
>>>> disk_offering.customized_iops, disk_offering.min_iops,
>>>> disk_offering.max_iops, disk_offering.sort_key,
>>>> disk_offering.bytes_read_rate, disk_offering.bytes_write_rate,
>>>> disk_offering.iops_read_rate, disk_offering.iops_write_rate,
>>>> disk_offering.cache_mode, disk_offering.display_offering,
>>>> disk_offering.state, disk_offering.hv_ss_reserve, service_offering.cpu,
>>>> service_offering.speed, service_offering.ram_size,
>>>> service_offering.nw_rate, service_offering.mc_rate,
>>>> service_offering.ha_enabled, service_offering.limit_cpu_use,
>>>> service_offering.is_volatile, service_offering.host_tag,
>>>> service_offering.default_use, service_offering.vm_type,
>>>> service_offering.sort_key, service_offering.deployment_planner FROM
>>>> service_offering INNER JOIN disk_offering ON service_offering.id=disk_
>>>> offering.id  WHERE disk_offering.type='Service' AND
>>>> disk_offering.unique_name = _binary'Cloud.Com-Small Instance'  AND
>>>> disk_offering.system_use = 1 AND disk_offering.removed IS NULL :
>>>> com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Unknown
>> column
>>>> 'disk_offering.cache_mode' in 'field list'
>>>> 
>>>> 
>>>> This is the definition of disk_offering from create-schema.sql
>>>> 
>>>> CREATE TABLE `cloud`.`disk_offering` (
>>>>   `id` bigint unsigned NOT NULL auto_increment,
>>>>   `domain_id` bigint unsigned,
>>>>   `name` varchar(255) NOT NULL,
>>>>   `uuid` varchar(40),
>>>>   `display_text` varchar(4096) NULL COMMENT 'Descrianaption text set by
>>>> the admin for display purpose only',
>>>>   `disk_size` bigint unsigned NOT NULL COMMENT 'disk space in byte',
>>>>   `type` varchar(32) COMMENT 'inheritted by who?',
>>>>   `tags` varchar(4096) COMMENT 'comma separated tags about the
>>>> disk_offering',
>>>>   `recreatable` tinyint(1) unsigned NOT NULL DEFAULT 0 COMMENT 'The
>> root
>>>> disk is always recreatable',
>>>>   `use_local_storage` tinyint(1) unsigned NOT NULL DEFAULT 0 COMMENT
>>>> 'Indicates whether local storage pools should be used',
>>>>   `unique_name` varchar(32) UNIQUE COMMENT 'unique name',
>>>>   `system_use` tinyint(1) unsigned NOT NULL DEFAULT 0 COMMENT 'is
>> this
>>>> offering for system used only',
>>>>   `customized` tinyint(1) unsigned NOT NULL DEFAULT 0 COMMENT '0
>> implies
>>>> not customized by default',
>>>>   `removed` datetime COMMENT 'date removed',
>>>>   `created` datetime COMMENT 'date the disk offering was created',
>>>>   `sort_key` int(32) NOT NULL default 0 COMMENT 'sort key used for
>>>> customising sort method',
>>>>   PRIMARY KEY  (`id`),
>>>>   INDEX `i_disk_offering__removed`(`removed`),
>>>>   CONSTRAINT `uc_disk_offering__uuid` UNIQUE (`uuid`)
>>>> ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
>>>> 
>>>> 
>>>> And this is in my DB
>>>> 
>>>> mysql> describe disk_offering;
>>>> +-------------------+---------------------+------+-----+----
>>>> -----+----------------+
>>>> | Field             | Type                | Null | Key | Default | Extra
>>>>        |
>>>> +-------------------+---------------------+------+-----+----
>>>> -----+----------------+
>>>> | id                | bigint(20) unsigned | NO   | PRI | NULL    |
>>>> auto_increment |
>>>> | domain_id         | bigint(20) unsigned | YES  |     | NULL    |
>>>>        |
>>>> | name              | varchar(255)        | NO   |     | NULL    |
>>>>        |
>>>> | uuid              | varchar(40)         | YES  | UNI | NULL    |
>>>>        |
>>>> | display_text      | varchar(4096)       | YES  |     | NULL    |
>>>>        |
>>>> | disk_size         | bigint(20) unsigned | NO   |     | NULL    |
>>>>        |
>>>> | type              | varchar(32)         | YES  |     | NULL    |
>>>>        |
>>>> | tags              | varchar(4096)       | YES  |     | NULL    |
>>>>        |
>>>> | recreatable       | tinyint(1) unsigned | NO   |     | 0       |
>>>>        |
>>>> | use_local_storage | tinyint(1) unsigned | NO   |     | 0       |
>>>>        |
>>>> | unique_name       | varchar(32)         | YES  | UNI | NULL    |
>>>>        |
>>>> | system_use        | tinyint(1) unsigned | NO   |     | 0       |
>>>>        |
>>>> | customized        | tinyint(1) unsigned | NO   |     | 0       |
>>>>        |
>>>> | removed           | datetime            | YES  | MUL | NULL    |
>>>>        |
>>>> | created           | datetime            | YES  |     | NULL    |
>>>>        |
>>>> | sort_key          | int(32)             | NO   |     | 0       |
>>>>        |
>>>> | display_offering  | tinyint(1)          | NO   |     | 1       |
>>>>        |
>>>> | customized_iops   | tinyint(1) unsigned | YES  |     | NULL    |
>>>>        |
>>>> | min_iops          | bigint(20) unsigned | YES  |     | NULL    |
>>>>        |
>>>> | max_iops          | bigint(20) unsigned | YES  |     | NULL    |
>>>>        |
>>>> | bytes_read_rate   | bigint(20)          | YES  |     | NULL    |
>>>>        |
>>>> | bytes_write_rate  | bigint(20)          | YES  |     | NULL    |
>>>>        |
>>>> | iops_read_rate    | bigint(20)          | YES  |     | NULL    |
>>>>        |
>>>> | iops_write_rate   | bigint(20)          | YES  |     | NULL    |
>>>>        |
>>>> | state             | char(40)            | NO   |     | Active  |
>>>>        |
>>>> | hv_ss_reserve     | int(32) unsigned    | YES  |     | NULL    |
>>>>        |
>>>> +-------------------+---------------------+------+-----+----
>>>> -----+----------------+
>>>> 26 rows in set (0.00 sec)
>>>> 
>>>> 
>>>> I don't see "cache_mode" anywhere. Does anyone else have this problem?
>>>> 
>>>> Thanks,
>>>> -Syed
>>>> 
>>>> 
>>> 
>> 
> 

Reply via email to