You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cloudstack.apache.org by "Nux (JIRA)" <ji...@apache.org> on 2014/02/07 20:25:19 UTC

[jira] [Comment Edited] (CLOUDSTACK-6061) Unable to execute upgrade script: schema-421to430.sql, Duplicate column name 'related'

    [ https://issues.apache.org/jira/browse/CLOUDSTACK-6061?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13894874#comment-13894874 ] 

Nux edited comment on CLOUDSTACK-6061 at 2/7/14 7:24 PM:
---------------------------------------------------------

Alena,

Ok, this is what I did:

- revert to 4.2.1 with working DB and everything 

- installed new sysVM:
/usr/share/cloudstack-common/scripts/storage/secondary/cloud-install-sys-tmplt -m /mnt/secondary -u http://jenkins.buildacloud.org/view/4.3/job/cloudstack-4.3-systemvm
/lastSuccessfulBuild/artifact/tools/appliance/dist/systemvmtemplate-2014-02-07-master-kvm.qcow2.bz2  -h kvm -F

- service cloudstack-management stop

- yum upgrade (to 4.3.0)

- service cloudstack-management start

- this is what I get:
2014-02-07 19:09:38,751 DEBUG [c.c.u.d.Upgrade421to430] (main:null) Updating VMware System Vms
2014-02-07 19:09:38,751 WARN  [c.c.u.d.Upgrade421to430] (main:null) 4.3.0 VMware SystemVm template not found. VMware hypervisor is not used, so not failing upgrade
2014-02-07 19:09:38,752 DEBUG [c.c.u.d.Upgrade421to430] (main:null) Updating KVM System Vms
2014-02-07 19:09:38,759 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null) Unable to upgrade the database
com.cloud.utils.exception.CloudRuntimeException: 4.3.0 KVM SystemVm template not found. Cannot upgrade system Vms

Also:
grep -i "Database upgrade must be performed from" /var/log/cloudstack/management/management-server.log
2014-02-07 19:09:35,975 INFO  [c.c.u.DatabaseUpgradeChecker] (main:null) Database upgrade must be performed from 4.2.1 to 4.3.0

So the question is, at what point during the upgrade procedure must the new System VM template be installed?




was (Author: nuxro):
Alena,

Ok, this is what I did:

- revert to 4.2.1 with working DB and everything 

- installed new sysVM:
/usr/share/cloudstack-common/scripts/storage/secondary/cloud-install-sys-tmplt -m /mnt/secondary -u http://jenkins.buildacloud.org/view/4.3/job/cloudstack-4.3-systemvm
/lastSuccessfulBuild/artifact/tools/appliance/dist/systemvmtemplate-2014-02-07-master-kvm.qcow2.bz2  -h kvm -F

- service cloudstack-management stop

- yum upgrade (to 4.3.0)

- service cloudstack-management start

- this is what I get:
2014-02-07 19:09:38,751 DEBUG [c.c.u.d.Upgrade421to430] (main:null) Updating VMware System Vms
2014-02-07 19:09:38,751 WARN  [c.c.u.d.Upgrade421to430] (main:null) 4.3.0 VMware SystemVm template not found. VMware hypervisor is not used, so not failing upgrade
2014-02-07 19:09:38,752 DEBUG [c.c.u.d.Upgrade421to430] (main:null) Updating KVM System Vms
2014-02-07 19:09:38,759 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null) Unable to upgrade the database
com.cloud.utils.exception.CloudRuntimeException: 4.3.0 KVM SystemVm template not found. Cannot upgrade system Vms

Also:
grep -i "Database upgrade must be performed from" /var/log/cloudstack/management/management-server.log
2014-02-07 19:09:35,975 INFO  [c.c.u.DatabaseUpgradeChecker] (main:null) Database upgrade must be performed from 4.2.1 to 4.3.0



> Unable to execute upgrade script: schema-421to430.sql, Duplicate column name 'related'
> --------------------------------------------------------------------------------------
>
>                 Key: CLOUDSTACK-6061
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-6061
>             Project: CloudStack
>          Issue Type: Bug
>      Security Level: Public(Anyone can view this level - this is the default.) 
>          Components: Management Server
>    Affects Versions: 4.2.1, 4.3.0
>         Environment: CentOS 6.5 x86_64 management server
> Using http://tmp.nux.ro/cloudsnap430_4308/ built from revision 4308
>            Reporter: Nux
>            Assignee: Alena Prokharchyk
>            Priority: Critical
>              Labels: db, upgrade
>
> Running an advanced zone with SG on 4.2.1, NFS primary and secondary storage, one instance and one extra volume. One management server, 2 HVs.
> Upgraded to 4.3.0 as follows:
> 1. service cloudstack-management stop
> 2. yum -y update (to update cloudstack-* rpms)
> 3. Add new SystemVM tmplate
> /usr/share/cloudstack-common/scripts/storage/secondary/cloud-install-sys-tmplt -m /mnt/secondary -u http://jenkins.buildacloud.org/view/4.3/job/cloudstack-4.3-systemvm/lastSuccessfulBuild/artifact/tools/appliance/dist/systemvmtemplate-2014-02-06-master-kvm.qcow2.bz2  -h kvm -F
> 4. service cloudstack-management start
> The following shows up in the management log:
> http://fpaste.org/75337/
> This is how my cloud DB looked like BEFORE the upgrade; this is the working 4.2.1 DB:
> http://tmp.nux.ro/ifu82kcloud.sql
> One Note:
> If I install 4.2.1 and run cloudstack-setup-databases and right after this upgrade to 4.3.0 then there is no problem.
> If I start using 4.2.1, add zones, HVs etc to it and THEN try to upgrade to 4.3.0 then the problem appears.



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)