You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cloudstack.apache.org by Info Manager <in...@activecloud.co.il> on 2021/01/17 12:48:16 UTC

Update Problem from 4.14 to 4.15

Hi all

Have anyone such problems while updating?

----------------------

 2021-01-17 01:42:47,466 DEBUG [c.c.u.d.ScriptRunner] (main:null) (logid:)
ALTER TABLE `cloud`.`project_account`  ADD COLUMN `user_id` bigint unsigned
COMMENT 'ID of user to be added to the project' AFTER `account_id`,  ADD
CONSTRAINT `fk_project_account__user_id` FOREIGN KEY
`fk_project_account__user_id`(`user_id`) REFERENCES `user`(`id`) ON DELETE
CASCADE,  ADD COLUMN `project_role_id` bigint unsigned COMMENT 'Project
role id' AFTER `project_account_id`,  ADD CONSTRAINT
`fk_project_account__project_role_id` FOREIGN KEY (`project_role_id`)
REFERENCES `project_role` (`id`) ON DELETE SET NULL,  DROP FOREIGN KEY
`fk_project_account__account_id`,  DROP INDEX `account_id`
2021-01-17 01:42:47,480 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:)
Error executing: ALTER TABLE `cloud`.`project_account`  ADD COLUMN
`user_id` bigint unsigned COMMENT 'ID of user to be added to the project'
AFTER `account_id`,  ADD CONSTRAINT `fk_project_account__user_id` FOREIGN
KEY `fk_project_account__user_id`(`user_id`) REFERENCES `user`(`id`) ON
DELETE CASCADE,  ADD COLUMN `project_role_id` bigint unsigned COMMENT
'Project role id' AFTER `project_account_id`,  ADD CONSTRAINT
`fk_project_account__project_role_id` FOREIGN KEY (`project_role_id`)
REFERENCES `project_role` (`id`) ON DELETE SET NULL,  DROP FOREIGN KEY
`fk_project_account__account_id`,  DROP INDEX `account_id`
2021-01-17 01:42:47,480 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:)
java.sql.SQLSyntaxErrorException: Can't DROP 'fk_project_account__account_id';
check that column/key exists
2021-01-17 01:42:47,483 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null)
(logid:) Unable to execute upgrade script
java.sql.SQLSyntaxErrorException: Can't DROP 'fk_project_account__account_id';
check that column/key exists
        at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:185)
        at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
        at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
DatabaseUpgradeChecker.java:203)
        at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(
DatabaseUpgradeChecker.java:258)
        at com.cloud.upgrade.DatabaseUpgradeChecker.check(
DatabaseUpgradeChecker.java:342)
        at org.apache.cloudstack.spring.lifecycle.
CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.
java:64)
        at org.apache.cloudstack.spring.lifecycle.
CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
        at org.springframework.context.support.DefaultLifecycleProcessor.
doStart(DefaultLifecycleProcessor.java:182)
        at org.springframework.context.support.DefaultLifecycleProcessor.
access$200(DefaultLifecycleProcessor.java:53)
        at org.springframework.context.support.DefaultLifecycleProcessor$
LifecycleGroup.start(DefaultLifecycleProcessor.java:360)
        at org.springframework.context.support.DefaultLifecycleProcessor.
startBeans(DefaultLifecycleProcessor.java:158)
        at org.springframework.context.support.DefaultLifecycleProcessor.
onRefresh(DefaultLifecycleProcessor.java:122)
        at org.springframework.context.support.AbstractApplicationContext.
finishRefresh(AbstractApplicationContext.java:894)
        at org.springframework.context.support.AbstractApplicationContext.
refresh(AbstractApplicationContext.java:553)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.java:144)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.java:116)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
        at org.apache.cloudstack.spring.module.factory.
ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.init(CloudStackSpringContext.java:70)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.<init>(CloudStackSpringContext.java:57)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.<init>(CloudStackSpringContext.java:61)
        at org.apache.cloudstack.spring.module.web.
CloudStackContextLoaderListener.contextInitialized(
CloudStackContextLoaderListener.java:51)
        at org.eclipse.jetty.server.handler.ContextHandler.
callContextInitialized(ContextHandler.java:933)
        at org.eclipse.jetty.servlet.ServletContextHandler.
callContextInitialized(ServletContextHandler.java:553)
        at org.eclipse.jetty.server.handler.ContextHandler.
startContext(ContextHandler.java:892)
        at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
ServletContextHandler.java:356)
        at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
WebAppContext.java:1445)
        at org.eclipse.jetty.webapp.WebAppContext.startContext(
WebAppContext.java:1409)
        at org.eclipse.jetty.server.handler.ContextHandler.
doStart(ContextHandler.java:825)
        at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
ServletContextHandler.java:275)
        at org.eclipse.jetty.webapp.WebAppContext.doStart(
WebAppContext.java:524)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:110)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.server.handler.gzip.GzipHandler.
doStart(GzipHandler.java:425)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:117)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.server.Server.start(Server.java:407)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:110)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.server.Server.doStart(Server.java:371)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.apache.cloudstack.ServerDaemon.start(ServerDaemon.java:188)
        at org.apache.cloudstack.ServerDaemon.main(ServerDaemon.java:104)
2021-01-17 01:42:47,485 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null)
(logid:) Unable to upgrade the database
com.cloud.utils.exception.CloudRuntimeException: Unable to execute upgrade
script
        at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
DatabaseUpgradeChecker.java:209)
        at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(
DatabaseUpgradeChecker.java:258)
        at com.cloud.upgrade.DatabaseUpgradeChecker.check(
DatabaseUpgradeChecker.java:342)
        at org.apache.cloudstack.spring.lifecycle.
CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.
java:64)
        at org.apache.cloudstack.spring.lifecycle.
CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
        at org.springframework.context.support.DefaultLifecycleProcessor.
doStart(DefaultLifecycleProcessor.java:182)
        at org.springframework.context.support.DefaultLifecycleProcessor.
access$200(DefaultLifecycleProcessor.java:53)
        at org.springframework.context.support.DefaultLifecycleProcessor$
LifecycleGroup.start(DefaultLifecycleProcessor.java:360)
        at org.springframework.context.support.DefaultLifecycleProcessor.
startBeans(DefaultLifecycleProcessor.java:158)
        at org.springframework.context.support.DefaultLifecycleProcessor.
onRefresh(DefaultLifecycleProcessor.java:122)
        at org.springframework.context.support.AbstractApplicationContext.
finishRefresh(AbstractApplicationContext.java:894)
        at org.springframework.context.support.AbstractApplicationContext.
refresh(AbstractApplicationContext.java:553)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.java:144)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.java:116)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
        at org.apache.cloudstack.spring.module.factory.
ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.init(CloudStackSpringContext.java:70)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.<init>(CloudStackSpringContext.java:57)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.<init>(CloudStackSpringContext.java:61)
        at org.apache.cloudstack.spring.module.web.
CloudStackContextLoaderListener.contextInitialized(
CloudStackContextLoaderListener.java:51)
        at org.eclipse.jetty.server.handler.ContextHandler.
callContextInitialized(ContextHandler.java:933)
        at org.eclipse.jetty.servlet.ServletContextHandler.
callContextInitialized(ServletContextHandler.java:553)
        at org.eclipse.jetty.server.handler.ContextHandler.
startContext(ContextHandler.java:892)
        at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
ServletContextHandler.java:356)
        at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
WebAppContext.java:1445)
        at org.eclipse.jetty.webapp.WebAppContext.startContext(
WebAppContext.java:1409)
        at org.eclipse.jetty.server.handler.ContextHandler.
doStart(ContextHandler.java:825)
        at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
ServletContextHandler.java:275)
        at org.eclipse.jetty.webapp.WebAppContext.doStart(
WebAppContext.java:524)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:110)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.server.handler.gzip.GzipHandler.
doStart(GzipHandler.java:425)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:117)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.server.Server.start(Server.java:407)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:110)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.server.Server.doStart(Server.java:371)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.apache.cloudstack.ServerDaemon.start(ServerDaemon.java:188)
        at org.apache.cloudstack.ServerDaemon.main(ServerDaemon.java:104)
Caused by: java.sql.SQLSyntaxErrorException: Can't DROP
'fk_project_account__account_id'; check that column/key exists
        at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:185)
        at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
        at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
DatabaseUpgradeChecker.java:203)
        ... 50 more
2021-01-17 01:42:47,498 DEBUG [c.c.u.d.T.Transaction] (main:null) (logid:)
Rolling back the transaction: Time = 27 Name =  Upgrade; called by
-TransactionLegacy.rollback:888-TransactionLegacy.removeUpTo:831-
TransactionLegacy.close:655-DatabaseUpgradeChecker.upgrade:273-
DatabaseUpgradeChecker.check:342-CloudStackExtendedLifeCycle.
checkIntegrity:64-CloudStackExtendedLifeCycle.start:54-
DefaultLifecycleProcessor.doStart:182-DefaultLifecycleProcessor.
access$200:53-DefaultLifecycleProcessor$LifecycleGroup.start:360-
DefaultLifecycleProcessor.startBeans:158-DefaultLifecycleProcessor.
onRefresh:122
----------------------

THank's

RE: Missing bridge/device network configuration

Posted by Piotr Pisz <pi...@piszki.pl>.
Ok, everything works, it turned out that the vlan interface names must be standard, i.e. vlan.* and not host.*

Thank you for your help :-)

Piotr


-----Original Message-----
From: Wei ZHOU <us...@gmail.com> 
Sent: Thursday, July 11, 2024 12:46 PM
To: users@cloudstack.apache.org
Subject: Re: Missing bridge/device network configuration

On CloudStack GUI, go to zone-> Physical Network -> click the name -> click the 4th icon "Update traffic labels" on the top-right.


-Wei


On Thu, Jul 11, 2024 at 11:02 AM Piotr Pisz <pi...@piszki.pl> wrote:
>
> Yes, that is the reason.
> When creating the zone, the network label remained unchanged (even though I provided the appropriate names).
> Is it possible to update it without deleting the zone?
>
> Piotr
>
> -----Original Message-----
> From: Wei ZHOU <us...@gmail.com>
> Sent: Thursday, July 11, 2024 10:40 AM
> To: users@cloudstack.apache.org
> Subject: Re: Missing bridge/device network configuration
>
> In addition to what Rohit said, it looks like there are some bridges already created.
> you can update the traffic label of physical networks to guest0 ,
> public0 or ceph0.
> The default traffic labels are cloudbr0/cloudbr1 which might not be what you plan to use.
>
> -Wei
>
> On Thu, Jul 11, 2024 at 10:22 AM Rohit Yadav <ro...@shapeblue.com> wrote:
> >
> > Piotr,
> >
> > I see you don't have a cloudbr0 or similar bridge which is default. If you want to use custom bridge, then you need to configure your zone's physical network's traffic type with such traffic labels before adding the KVM host.
> >
> > You can cross-check this against the KVM host (where it failed) agent.properties file, where in it has private/public/guest network device which isn't setup on your KVM host.
> >
> > References:
> > https://docs.cloudstack.apache.org/en/4.19.0.2/installguide/configur
> > at
> > ion.html#id4
> > https://docs.cloudstack.apache.org/en/4.19.0.2/adminguide/troublesho
> > ot
> > ing.html#trouble-shooting-steps
> > https://www.shapeblue.com/networking-kvm-for-cloudstack/
> >
> >
> >
> > Regards.
> >
> >
> >
> >
> > ________________________________
> > From: Piotr Pisz <pi...@piszki.pl>
> > Sent: Thursday, July 11, 2024 12:29
> > To: users@cloudstack.apache.org <us...@cloudstack.apache.org>
> > Subject: Missing bridge/device network configuration
> >
> > Hi,
> >
> > I'm trying to add a host with ubuntu22 and a network generated by netplan, unfortunately I have the problem as below, have I missed something?
> >
> > SSH command output:Starting to configure your system:
> > Configure Host ...            [OK]
> > Configure Apparmor ...        [OK]
> > Configure Network ...         [Failed]
> > Missing bridge/device network configuration, need to add your 
> > network configuration into /etc/network/interfaces at first Try to restore your system:
> > Restore Host ...              [OK]
> > Restore Apparmor ...          [OK]
> > Restore Network ...           [OK]
> >
> > Agetn setup.log:
> >
> > DEBUG:root:execute:uname -r
> > DEBUG:root:execute:uname -m
> > DEBUG:root:execute:hostname -f
> > DEBUG:root:execute:kvm-ok
> > DEBUG:root:execute:awk '/MemTotal/ { printf "%.3f \n", $2/1024 }'
> > /proc/meminfo DEBUG:root:execute:ip a | grep "^\w" | grep -iv "^lo" 
> > | wc -l DEBUG:root:execute:service apparmor status 
> > DEBUG:root:execute:apparmor_status |grep libvirt DEBUG:root:Failed 
> > to
> > execute:
> > DEBUG:root:cloudbr0 is not a network device, is it down?
> > DEBUG:root:execute:sudo /usr/sbin/service network-manager status 
> > DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
> > DEBUG:root:execute:route -n|awk '/^0.0.0.0/ {print $2,$8}'
> > DEBUG:root:execute:ifconfig host0
> > DEBUG:root:Found default network device:host0 
> > DEBUG:root:execute:ifconfig host0.101 DEBUG:root:execute:sudo 
> > update-rc.d -f apparmor remove DEBUG:root:execute:sudo update-rc.d 
> > -f apparmor defaults DEBUG:root:execute:sudo /usr/sbin/service 
> > apparmor status DEBUG:root:execute:sudo /usr/sbin/service apparmor 
> > start DEBUG:root:execute:sudo /usr/sbin/service apparmor status 
> > DEBUG:root:execute:sudo /usr/sbin/service apparmor start 
> > DEBUG:root:execute:sudo update-rc.d -f network-manager remove 
> > DEBUG:root:execute:sudo update-rc.d -f network-manager defaults 
> > DEBUG:root:Failed to execute:update-rc.d: error: unable to read 
> > /etc/init.d/network-manager DEBUG:root:execute:sudo 
> > /usr/sbin/service network-manager status DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
> > DEBUG:root:execute:sudo /usr/sbin/service network-manager start 
> > DEBUG:root:Failed to execute:Failed to start network-manager.service: Unit network-manager.service not found.
> > DEBUG:root:execute:sudo /usr/sbin/service network-manager status 
> > DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
> > DEBUG:root:execute:sudo /usr/sbin/service network-manager start 
> > DEBUG:root:Failed to execute:Failed to start network-manager.service: Unit network-manager.service not found.
> > DEBUG:root:execute:/etc/init.d/networking stop DEBUG:root:Failed to
> > execute:/bin/sh: 1: /etc/init.d/networking: not found 
> > DEBUG:root:execute:/etc/init.d/networking start DEBUG:root:Failed to
> > execute:/bin/sh: 1: /etc/init.d/networking: not found
> >
> > Bridges and netplan config:
> >
> > root@sdc ~# brctl show
> > bridge name     bridge id               STP enabled     interfaces
> > ceph0           8000.963d69ccc23e       no              ceph0.102
> > docker0         8000.02428faeaa58       no
> > guest0          8000.dab6e62ba668       no              guest0.103
> > host0           8000.32335383ebbb       no              host0.101
> > public0         8000.aa725a4be728       no              public0.227
> > virbr0          8000.525400a74ecc       yes
> >
> > network:
> >   version: 2
> >   renderer: networkd
> >   bonds:
> >     bond0:
> >       interfaces:
> >       - eno49
> >       - eno50
> >       parameters:
> >         lacp-rate: fast
> >         mode: 802.3ad
> >         transmit-hash-policy: layer3+4
> >       mtu: 9000
> >   ethernets:
> >     eno1: {}
> >     eno2: {}
> >     eno3: {}
> >     eno4: {}
> >     eno49:
> >       mtu: 9000
> >     eno50:
> >       mtu: 9000
> >   vlans:
> >     host0.101:
> >       dhcp4: no
> >       id: 101
> >       link: bond0
> >       mtu: 9000
> >     ceph0.102:
> >       dhcp4: no
> >       id: 102
> >       link: bond0
> >       mtu: 9000
> >     guest0.103:
> >       dhcp4: no
> >       id: 103
> >       link: bond0
> >       mtu: 9000
> >     public0.227:
> >       dhcp4: no
> >       id: 227
> >       link: bond0
> >       mtu: 9000
> >   bridges:
> >     host0:
> >       addresses:
> >       - 10.10.101.13/24
> >       nameservers:
> >         addresses:
> >         - 8.8.8.8
> >       routes:
> >       - to: default
> >         via: 10.10.101.254
> >       interfaces:
> >         - host0.101
> >     ceph0:
> >       addresses:
> >       - 10.10.102.13/24
> >       interfaces:
> >         - ceph0.102
> >     guest0:
> >       interfaces:
> >         - guest0.103
> >     public0:
> >       interfaces:
> >         - public0.227
> >
>


Re: Missing bridge/device network configuration

Posted by Wei ZHOU <us...@gmail.com>.
On CloudStack GUI, go to zone-> Physical Network -> click the name ->
click the 4th icon "Update traffic labels" on the top-right.


-Wei


On Thu, Jul 11, 2024 at 11:02 AM Piotr Pisz <pi...@piszki.pl> wrote:
>
> Yes, that is the reason.
> When creating the zone, the network label remained unchanged (even though I provided the appropriate names).
> Is it possible to update it without deleting the zone?
>
> Piotr
>
> -----Original Message-----
> From: Wei ZHOU <us...@gmail.com>
> Sent: Thursday, July 11, 2024 10:40 AM
> To: users@cloudstack.apache.org
> Subject: Re: Missing bridge/device network configuration
>
> In addition to what Rohit said, it looks like there are some bridges already created.
> you can update the traffic label of physical networks to guest0 ,
> public0 or ceph0.
> The default traffic labels are cloudbr0/cloudbr1 which might not be what you plan to use.
>
> -Wei
>
> On Thu, Jul 11, 2024 at 10:22 AM Rohit Yadav <ro...@shapeblue.com> wrote:
> >
> > Piotr,
> >
> > I see you don't have a cloudbr0 or similar bridge which is default. If you want to use custom bridge, then you need to configure your zone's physical network's traffic type with such traffic labels before adding the KVM host.
> >
> > You can cross-check this against the KVM host (where it failed) agent.properties file, where in it has private/public/guest network device which isn't setup on your KVM host.
> >
> > References:
> > https://docs.cloudstack.apache.org/en/4.19.0.2/installguide/configurat
> > ion.html#id4
> > https://docs.cloudstack.apache.org/en/4.19.0.2/adminguide/troubleshoot
> > ing.html#trouble-shooting-steps
> > https://www.shapeblue.com/networking-kvm-for-cloudstack/
> >
> >
> >
> > Regards.
> >
> >
> >
> >
> > ________________________________
> > From: Piotr Pisz <pi...@piszki.pl>
> > Sent: Thursday, July 11, 2024 12:29
> > To: users@cloudstack.apache.org <us...@cloudstack.apache.org>
> > Subject: Missing bridge/device network configuration
> >
> > Hi,
> >
> > I'm trying to add a host with ubuntu22 and a network generated by netplan, unfortunately I have the problem as below, have I missed something?
> >
> > SSH command output:Starting to configure your system:
> > Configure Host ...            [OK]
> > Configure Apparmor ...        [OK]
> > Configure Network ...         [Failed]
> > Missing bridge/device network configuration, need to add your network
> > configuration into /etc/network/interfaces at first Try to restore your system:
> > Restore Host ...              [OK]
> > Restore Apparmor ...          [OK]
> > Restore Network ...           [OK]
> >
> > Agetn setup.log:
> >
> > DEBUG:root:execute:uname -r
> > DEBUG:root:execute:uname -m
> > DEBUG:root:execute:hostname -f
> > DEBUG:root:execute:kvm-ok
> > DEBUG:root:execute:awk '/MemTotal/ { printf "%.3f \n", $2/1024 }'
> > /proc/meminfo DEBUG:root:execute:ip a | grep "^\w" | grep -iv "^lo" |
> > wc -l DEBUG:root:execute:service apparmor status
> > DEBUG:root:execute:apparmor_status |grep libvirt DEBUG:root:Failed to
> > execute:
> > DEBUG:root:cloudbr0 is not a network device, is it down?
> > DEBUG:root:execute:sudo /usr/sbin/service network-manager status
> > DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
> > DEBUG:root:execute:route -n|awk '/^0.0.0.0/ {print $2,$8}'
> > DEBUG:root:execute:ifconfig host0
> > DEBUG:root:Found default network device:host0
> > DEBUG:root:execute:ifconfig host0.101 DEBUG:root:execute:sudo
> > update-rc.d -f apparmor remove DEBUG:root:execute:sudo update-rc.d -f
> > apparmor defaults DEBUG:root:execute:sudo /usr/sbin/service apparmor
> > status DEBUG:root:execute:sudo /usr/sbin/service apparmor start
> > DEBUG:root:execute:sudo /usr/sbin/service apparmor status
> > DEBUG:root:execute:sudo /usr/sbin/service apparmor start
> > DEBUG:root:execute:sudo update-rc.d -f network-manager remove
> > DEBUG:root:execute:sudo update-rc.d -f network-manager defaults
> > DEBUG:root:Failed to execute:update-rc.d: error: unable to read
> > /etc/init.d/network-manager DEBUG:root:execute:sudo /usr/sbin/service
> > network-manager status DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
> > DEBUG:root:execute:sudo /usr/sbin/service network-manager start
> > DEBUG:root:Failed to execute:Failed to start network-manager.service: Unit network-manager.service not found.
> > DEBUG:root:execute:sudo /usr/sbin/service network-manager status
> > DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
> > DEBUG:root:execute:sudo /usr/sbin/service network-manager start
> > DEBUG:root:Failed to execute:Failed to start network-manager.service: Unit network-manager.service not found.
> > DEBUG:root:execute:/etc/init.d/networking stop DEBUG:root:Failed to
> > execute:/bin/sh: 1: /etc/init.d/networking: not found
> > DEBUG:root:execute:/etc/init.d/networking start DEBUG:root:Failed to
> > execute:/bin/sh: 1: /etc/init.d/networking: not found
> >
> > Bridges and netplan config:
> >
> > root@sdc ~# brctl show
> > bridge name     bridge id               STP enabled     interfaces
> > ceph0           8000.963d69ccc23e       no              ceph0.102
> > docker0         8000.02428faeaa58       no
> > guest0          8000.dab6e62ba668       no              guest0.103
> > host0           8000.32335383ebbb       no              host0.101
> > public0         8000.aa725a4be728       no              public0.227
> > virbr0          8000.525400a74ecc       yes
> >
> > network:
> >   version: 2
> >   renderer: networkd
> >   bonds:
> >     bond0:
> >       interfaces:
> >       - eno49
> >       - eno50
> >       parameters:
> >         lacp-rate: fast
> >         mode: 802.3ad
> >         transmit-hash-policy: layer3+4
> >       mtu: 9000
> >   ethernets:
> >     eno1: {}
> >     eno2: {}
> >     eno3: {}
> >     eno4: {}
> >     eno49:
> >       mtu: 9000
> >     eno50:
> >       mtu: 9000
> >   vlans:
> >     host0.101:
> >       dhcp4: no
> >       id: 101
> >       link: bond0
> >       mtu: 9000
> >     ceph0.102:
> >       dhcp4: no
> >       id: 102
> >       link: bond0
> >       mtu: 9000
> >     guest0.103:
> >       dhcp4: no
> >       id: 103
> >       link: bond0
> >       mtu: 9000
> >     public0.227:
> >       dhcp4: no
> >       id: 227
> >       link: bond0
> >       mtu: 9000
> >   bridges:
> >     host0:
> >       addresses:
> >       - 10.10.101.13/24
> >       nameservers:
> >         addresses:
> >         - 8.8.8.8
> >       routes:
> >       - to: default
> >         via: 10.10.101.254
> >       interfaces:
> >         - host0.101
> >     ceph0:
> >       addresses:
> >       - 10.10.102.13/24
> >       interfaces:
> >         - ceph0.102
> >     guest0:
> >       interfaces:
> >         - guest0.103
> >     public0:
> >       interfaces:
> >         - public0.227
> >
>

Re: Missing bridge/device network configuration

Posted by Jithin Raju <ji...@shapeblue.com>.
Yes, you can update them against the traffic types for KVM in the physical networks of the zone.

-Jithin

From: Piotr Pisz <pi...@piszki.pl>
Date: Thursday, 11 July 2024 at 2:32 PM
To: users@cloudstack.apache.org <us...@cloudstack.apache.org>
Subject: RE: Missing bridge/device network configuration
Yes, that is the reason.
When creating the zone, the network label remained unchanged (even though I provided the appropriate names).
Is it possible to update it without deleting the zone?

Piotr

 


-----Original Message-----
From: Wei ZHOU <us...@gmail.com>
Sent: Thursday, July 11, 2024 10:40 AM
To: users@cloudstack.apache.org
Subject: Re: Missing bridge/device network configuration

In addition to what Rohit said, it looks like there are some bridges already created.
you can update the traffic label of physical networks to guest0 ,
public0 or ceph0.
The default traffic labels are cloudbr0/cloudbr1 which might not be what you plan to use.

-Wei

On Thu, Jul 11, 2024 at 10:22 AM Rohit Yadav <ro...@shapeblue.com> wrote:
>
> Piotr,
>
> I see you don't have a cloudbr0 or similar bridge which is default. If you want to use custom bridge, then you need to configure your zone's physical network's traffic type with such traffic labels before adding the KVM host.
>
> You can cross-check this against the KVM host (where it failed) agent.properties file, where in it has private/public/guest network device which isn't setup on your KVM host.
>
> References:
> https://docs.cloudstack.apache.org/en/4.19.0.2/installguide/configurat
> ion.html#id4
> https://docs.cloudstack.apache.org/en/4.19.0.2/adminguide/troubleshoot
> ing.html#trouble-shooting-steps
> https://www.shapeblue.com/networking-kvm-for-cloudstack/
>
>
>
> Regards.
>
>
>
>
> ________________________________
> From: Piotr Pisz <pi...@piszki.pl>
> Sent: Thursday, July 11, 2024 12:29
> To: users@cloudstack.apache.org <us...@cloudstack.apache.org>
> Subject: Missing bridge/device network configuration
>
> Hi,
>
> I'm trying to add a host with ubuntu22 and a network generated by netplan, unfortunately I have the problem as below, have I missed something?
>
> SSH command output:Starting to configure your system:
> Configure Host ...            [OK]
> Configure Apparmor ...        [OK]
> Configure Network ...         [Failed]
> Missing bridge/device network configuration, need to add your network
> configuration into /etc/network/interfaces at first Try to restore your system:
> Restore Host ...              [OK]
> Restore Apparmor ...          [OK]
> Restore Network ...           [OK]
>
> Agetn setup.log:
>
> DEBUG:root:execute:uname -r
> DEBUG:root:execute:uname -m
> DEBUG:root:execute:hostname -f
> DEBUG:root:execute:kvm-ok
> DEBUG:root:execute:awk '/MemTotal/ { printf "%.3f \n", $2/1024 }'
> /proc/meminfo DEBUG:root:execute:ip a | grep "^\w" | grep -iv "^lo" |
> wc -l DEBUG:root:execute:service apparmor status
> DEBUG:root:execute:apparmor_status |grep libvirt DEBUG:root:Failed to
> execute:
> DEBUG:root:cloudbr0 is not a network device, is it down?
> DEBUG:root:execute:sudo /usr/sbin/service network-manager status
> DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
> DEBUG:root:execute:route -n|awk '/^0.0.0.0/ {print $2,$8}'
> DEBUG:root:execute:ifconfig host0
> DEBUG:root:Found default network device:host0
> DEBUG:root:execute:ifconfig host0.101 DEBUG:root:execute:sudo
> update-rc.d -f apparmor remove DEBUG:root:execute:sudo update-rc.d -f
> apparmor defaults DEBUG:root:execute:sudo /usr/sbin/service apparmor
> status DEBUG:root:execute:sudo /usr/sbin/service apparmor start
> DEBUG:root:execute:sudo /usr/sbin/service apparmor status
> DEBUG:root:execute:sudo /usr/sbin/service apparmor start
> DEBUG:root:execute:sudo update-rc.d -f network-manager remove
> DEBUG:root:execute:sudo update-rc.d -f network-manager defaults
> DEBUG:root:Failed to execute:update-rc.d: error: unable to read
> /etc/init.d/network-manager DEBUG:root:execute:sudo /usr/sbin/service
> network-manager status DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
> DEBUG:root:execute:sudo /usr/sbin/service network-manager start
> DEBUG:root:Failed to execute:Failed to start network-manager.service: Unit network-manager.service not found.
> DEBUG:root:execute:sudo /usr/sbin/service network-manager status
> DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
> DEBUG:root:execute:sudo /usr/sbin/service network-manager start
> DEBUG:root:Failed to execute:Failed to start network-manager.service: Unit network-manager.service not found.
> DEBUG:root:execute:/etc/init.d/networking stop DEBUG:root:Failed to
> execute:/bin/sh: 1: /etc/init.d/networking: not found
> DEBUG:root:execute:/etc/init.d/networking start DEBUG:root:Failed to
> execute:/bin/sh: 1: /etc/init.d/networking: not found
>
> Bridges and netplan config:
>
> root@sdc ~# brctl show
> bridge name     bridge id               STP enabled     interfaces
> ceph0           8000.963d69ccc23e       no              ceph0.102
> docker0         8000.02428faeaa58       no
> guest0          8000.dab6e62ba668       no              guest0.103
> host0           8000.32335383ebbb       no              host0.101
> public0         8000.aa725a4be728       no              public0.227
> virbr0          8000.525400a74ecc       yes
>
> network:
>   version: 2
>   renderer: networkd
>   bonds:
>     bond0:
>       interfaces:
>       - eno49
>       - eno50
>       parameters:
>         lacp-rate: fast
>         mode: 802.3ad
>         transmit-hash-policy: layer3+4
>       mtu: 9000
>   ethernets:
>     eno1: {}
>     eno2: {}
>     eno3: {}
>     eno4: {}
>     eno49:
>       mtu: 9000
>     eno50:
>       mtu: 9000
>   vlans:
>     host0.101:
>       dhcp4: no
>       id: 101
>       link: bond0
>       mtu: 9000
>     ceph0.102:
>       dhcp4: no
>       id: 102
>       link: bond0
>       mtu: 9000
>     guest0.103:
>       dhcp4: no
>       id: 103
>       link: bond0
>       mtu: 9000
>     public0.227:
>       dhcp4: no
>       id: 227
>       link: bond0
>       mtu: 9000
>   bridges:
>     host0:
>       addresses:
>       - 10.10.101.13/24
>       nameservers:
>         addresses:
>         - 8.8.8.8
>       routes:
>       - to: default
>         via: 10.10.101.254
>       interfaces:
>         - host0.101
>     ceph0:
>       addresses:
>       - 10.10.102.13/24
>       interfaces:
>         - ceph0.102
>     guest0:
>       interfaces:
>         - guest0.103
>     public0:
>       interfaces:
>         - public0.227
>

RE: Missing bridge/device network configuration

Posted by Piotr Pisz <pi...@piszki.pl>.
Yes, that is the reason.
When creating the zone, the network label remained unchanged (even though I provided the appropriate names). 
Is it possible to update it without deleting the zone?

Piotr

-----Original Message-----
From: Wei ZHOU <us...@gmail.com> 
Sent: Thursday, July 11, 2024 10:40 AM
To: users@cloudstack.apache.org
Subject: Re: Missing bridge/device network configuration

In addition to what Rohit said, it looks like there are some bridges already created.
you can update the traffic label of physical networks to guest0 ,
public0 or ceph0.
The default traffic labels are cloudbr0/cloudbr1 which might not be what you plan to use.

-Wei

On Thu, Jul 11, 2024 at 10:22 AM Rohit Yadav <ro...@shapeblue.com> wrote:
>
> Piotr,
>
> I see you don't have a cloudbr0 or similar bridge which is default. If you want to use custom bridge, then you need to configure your zone's physical network's traffic type with such traffic labels before adding the KVM host.
>
> You can cross-check this against the KVM host (where it failed) agent.properties file, where in it has private/public/guest network device which isn't setup on your KVM host.
>
> References:
> https://docs.cloudstack.apache.org/en/4.19.0.2/installguide/configurat
> ion.html#id4 
> https://docs.cloudstack.apache.org/en/4.19.0.2/adminguide/troubleshoot
> ing.html#trouble-shooting-steps 
> https://www.shapeblue.com/networking-kvm-for-cloudstack/
>
>
>
> Regards.
>
>
>
>
> ________________________________
> From: Piotr Pisz <pi...@piszki.pl>
> Sent: Thursday, July 11, 2024 12:29
> To: users@cloudstack.apache.org <us...@cloudstack.apache.org>
> Subject: Missing bridge/device network configuration
>
> Hi,
>
> I'm trying to add a host with ubuntu22 and a network generated by netplan, unfortunately I have the problem as below, have I missed something?
>
> SSH command output:Starting to configure your system:
> Configure Host ...            [OK]
> Configure Apparmor ...        [OK]
> Configure Network ...         [Failed]
> Missing bridge/device network configuration, need to add your network 
> configuration into /etc/network/interfaces at first Try to restore your system:
> Restore Host ...              [OK]
> Restore Apparmor ...          [OK]
> Restore Network ...           [OK]
>
> Agetn setup.log:
>
> DEBUG:root:execute:uname -r
> DEBUG:root:execute:uname -m
> DEBUG:root:execute:hostname -f
> DEBUG:root:execute:kvm-ok
> DEBUG:root:execute:awk '/MemTotal/ { printf "%.3f \n", $2/1024 }' 
> /proc/meminfo DEBUG:root:execute:ip a | grep "^\w" | grep -iv "^lo" | 
> wc -l DEBUG:root:execute:service apparmor status 
> DEBUG:root:execute:apparmor_status |grep libvirt DEBUG:root:Failed to 
> execute:
> DEBUG:root:cloudbr0 is not a network device, is it down?
> DEBUG:root:execute:sudo /usr/sbin/service network-manager status 
> DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
> DEBUG:root:execute:route -n|awk '/^0.0.0.0/ {print $2,$8}'
> DEBUG:root:execute:ifconfig host0
> DEBUG:root:Found default network device:host0 
> DEBUG:root:execute:ifconfig host0.101 DEBUG:root:execute:sudo 
> update-rc.d -f apparmor remove DEBUG:root:execute:sudo update-rc.d -f 
> apparmor defaults DEBUG:root:execute:sudo /usr/sbin/service apparmor 
> status DEBUG:root:execute:sudo /usr/sbin/service apparmor start 
> DEBUG:root:execute:sudo /usr/sbin/service apparmor status 
> DEBUG:root:execute:sudo /usr/sbin/service apparmor start 
> DEBUG:root:execute:sudo update-rc.d -f network-manager remove 
> DEBUG:root:execute:sudo update-rc.d -f network-manager defaults 
> DEBUG:root:Failed to execute:update-rc.d: error: unable to read 
> /etc/init.d/network-manager DEBUG:root:execute:sudo /usr/sbin/service 
> network-manager status DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
> DEBUG:root:execute:sudo /usr/sbin/service network-manager start 
> DEBUG:root:Failed to execute:Failed to start network-manager.service: Unit network-manager.service not found.
> DEBUG:root:execute:sudo /usr/sbin/service network-manager status 
> DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
> DEBUG:root:execute:sudo /usr/sbin/service network-manager start 
> DEBUG:root:Failed to execute:Failed to start network-manager.service: Unit network-manager.service not found.
> DEBUG:root:execute:/etc/init.d/networking stop DEBUG:root:Failed to 
> execute:/bin/sh: 1: /etc/init.d/networking: not found 
> DEBUG:root:execute:/etc/init.d/networking start DEBUG:root:Failed to 
> execute:/bin/sh: 1: /etc/init.d/networking: not found
>
> Bridges and netplan config:
>
> root@sdc ~# brctl show
> bridge name     bridge id               STP enabled     interfaces
> ceph0           8000.963d69ccc23e       no              ceph0.102
> docker0         8000.02428faeaa58       no
> guest0          8000.dab6e62ba668       no              guest0.103
> host0           8000.32335383ebbb       no              host0.101
> public0         8000.aa725a4be728       no              public0.227
> virbr0          8000.525400a74ecc       yes
>
> network:
>   version: 2
>   renderer: networkd
>   bonds:
>     bond0:
>       interfaces:
>       - eno49
>       - eno50
>       parameters:
>         lacp-rate: fast
>         mode: 802.3ad
>         transmit-hash-policy: layer3+4
>       mtu: 9000
>   ethernets:
>     eno1: {}
>     eno2: {}
>     eno3: {}
>     eno4: {}
>     eno49:
>       mtu: 9000
>     eno50:
>       mtu: 9000
>   vlans:
>     host0.101:
>       dhcp4: no
>       id: 101
>       link: bond0
>       mtu: 9000
>     ceph0.102:
>       dhcp4: no
>       id: 102
>       link: bond0
>       mtu: 9000
>     guest0.103:
>       dhcp4: no
>       id: 103
>       link: bond0
>       mtu: 9000
>     public0.227:
>       dhcp4: no
>       id: 227
>       link: bond0
>       mtu: 9000
>   bridges:
>     host0:
>       addresses:
>       - 10.10.101.13/24
>       nameservers:
>         addresses:
>         - 8.8.8.8
>       routes:
>       - to: default
>         via: 10.10.101.254
>       interfaces:
>         - host0.101
>     ceph0:
>       addresses:
>       - 10.10.102.13/24
>       interfaces:
>         - ceph0.102
>     guest0:
>       interfaces:
>         - guest0.103
>     public0:
>       interfaces:
>         - public0.227
>


Re: Missing bridge/device network configuration

Posted by Wei ZHOU <us...@gmail.com>.
In addition to what Rohit said, it looks like there are some bridges
already created.
you can update the traffic label of physical networks to guest0 ,
public0 or ceph0.
The default traffic labels are cloudbr0/cloudbr1 which might not be
what you plan to use.

-Wei

On Thu, Jul 11, 2024 at 10:22 AM Rohit Yadav <ro...@shapeblue.com> wrote:
>
> Piotr,
>
> I see you don't have a cloudbr0 or similar bridge which is default. If you want to use custom bridge, then you need to configure your zone's physical network's traffic type with such traffic labels before adding the KVM host.
>
> You can cross-check this against the KVM host (where it failed) agent.properties file, where in it has private/public/guest network device which isn't setup on your KVM host.
>
> References:
> https://docs.cloudstack.apache.org/en/4.19.0.2/installguide/configuration.html#id4
> https://docs.cloudstack.apache.org/en/4.19.0.2/adminguide/troubleshooting.html#trouble-shooting-steps
> https://www.shapeblue.com/networking-kvm-for-cloudstack/
>
>
>
> Regards.
>
>
>
>
> ________________________________
> From: Piotr Pisz <pi...@piszki.pl>
> Sent: Thursday, July 11, 2024 12:29
> To: users@cloudstack.apache.org <us...@cloudstack.apache.org>
> Subject: Missing bridge/device network configuration
>
> Hi,
>
> I'm trying to add a host with ubuntu22 and a network generated by netplan, unfortunately I have the problem as below, have I missed something?
>
> SSH command output:Starting to configure your system:
> Configure Host ...            [OK]
> Configure Apparmor ...        [OK]
> Configure Network ...         [Failed]
> Missing bridge/device network configuration, need to add your network configuration into /etc/network/interfaces at first
> Try to restore your system:
> Restore Host ...              [OK]
> Restore Apparmor ...          [OK]
> Restore Network ...           [OK]
>
> Agetn setup.log:
>
> DEBUG:root:execute:uname -r
> DEBUG:root:execute:uname -m
> DEBUG:root:execute:hostname -f
> DEBUG:root:execute:kvm-ok
> DEBUG:root:execute:awk '/MemTotal/ { printf "%.3f \n", $2/1024 }' /proc/meminfo
> DEBUG:root:execute:ip a | grep "^\w" | grep -iv "^lo" | wc -l
> DEBUG:root:execute:service apparmor status
> DEBUG:root:execute:apparmor_status |grep libvirt
> DEBUG:root:Failed to execute:
> DEBUG:root:cloudbr0 is not a network device, is it down?
> DEBUG:root:execute:sudo /usr/sbin/service network-manager status
> DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
> DEBUG:root:execute:route -n|awk '/^0.0.0.0/ {print $2,$8}'
> DEBUG:root:execute:ifconfig host0
> DEBUG:root:Found default network device:host0
> DEBUG:root:execute:ifconfig host0.101
> DEBUG:root:execute:sudo update-rc.d -f apparmor remove
> DEBUG:root:execute:sudo update-rc.d -f apparmor defaults
> DEBUG:root:execute:sudo /usr/sbin/service apparmor status
> DEBUG:root:execute:sudo /usr/sbin/service apparmor start
> DEBUG:root:execute:sudo /usr/sbin/service apparmor status
> DEBUG:root:execute:sudo /usr/sbin/service apparmor start
> DEBUG:root:execute:sudo update-rc.d -f network-manager remove
> DEBUG:root:execute:sudo update-rc.d -f network-manager defaults
> DEBUG:root:Failed to execute:update-rc.d: error: unable to read /etc/init.d/network-manager
> DEBUG:root:execute:sudo /usr/sbin/service network-manager status
> DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
> DEBUG:root:execute:sudo /usr/sbin/service network-manager start
> DEBUG:root:Failed to execute:Failed to start network-manager.service: Unit network-manager.service not found.
> DEBUG:root:execute:sudo /usr/sbin/service network-manager status
> DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
> DEBUG:root:execute:sudo /usr/sbin/service network-manager start
> DEBUG:root:Failed to execute:Failed to start network-manager.service: Unit network-manager.service not found.
> DEBUG:root:execute:/etc/init.d/networking stop
> DEBUG:root:Failed to execute:/bin/sh: 1: /etc/init.d/networking: not found
> DEBUG:root:execute:/etc/init.d/networking start
> DEBUG:root:Failed to execute:/bin/sh: 1: /etc/init.d/networking: not found
>
> Bridges and netplan config:
>
> root@sdc ~# brctl show
> bridge name     bridge id               STP enabled     interfaces
> ceph0           8000.963d69ccc23e       no              ceph0.102
> docker0         8000.02428faeaa58       no
> guest0          8000.dab6e62ba668       no              guest0.103
> host0           8000.32335383ebbb       no              host0.101
> public0         8000.aa725a4be728       no              public0.227
> virbr0          8000.525400a74ecc       yes
>
> network:
>   version: 2
>   renderer: networkd
>   bonds:
>     bond0:
>       interfaces:
>       - eno49
>       - eno50
>       parameters:
>         lacp-rate: fast
>         mode: 802.3ad
>         transmit-hash-policy: layer3+4
>       mtu: 9000
>   ethernets:
>     eno1: {}
>     eno2: {}
>     eno3: {}
>     eno4: {}
>     eno49:
>       mtu: 9000
>     eno50:
>       mtu: 9000
>   vlans:
>     host0.101:
>       dhcp4: no
>       id: 101
>       link: bond0
>       mtu: 9000
>     ceph0.102:
>       dhcp4: no
>       id: 102
>       link: bond0
>       mtu: 9000
>     guest0.103:
>       dhcp4: no
>       id: 103
>       link: bond0
>       mtu: 9000
>     public0.227:
>       dhcp4: no
>       id: 227
>       link: bond0
>       mtu: 9000
>   bridges:
>     host0:
>       addresses:
>       - 10.10.101.13/24
>       nameservers:
>         addresses:
>         - 8.8.8.8
>       routes:
>       - to: default
>         via: 10.10.101.254
>       interfaces:
>         - host0.101
>     ceph0:
>       addresses:
>       - 10.10.102.13/24
>       interfaces:
>         - ceph0.102
>     guest0:
>       interfaces:
>         - guest0.103
>     public0:
>       interfaces:
>         - public0.227
>

Re: Missing bridge/device network configuration

Posted by Rohit Yadav <ro...@shapeblue.com>.
Piotr,

I see you don't have a cloudbr0 or similar bridge which is default. If you want to use custom bridge, then you need to configure your zone's physical network's traffic type with such traffic labels before adding the KVM host.

You can cross-check this against the KVM host (where it failed) agent.properties file, where in it has private/public/guest network device which isn't setup on your KVM host.

References:
https://docs.cloudstack.apache.org/en/4.19.0.2/installguide/configuration.html#id4
https://docs.cloudstack.apache.org/en/4.19.0.2/adminguide/troubleshooting.html#trouble-shooting-steps
https://www.shapeblue.com/networking-kvm-for-cloudstack/



Regards.

 


________________________________
From: Piotr Pisz <pi...@piszki.pl>
Sent: Thursday, July 11, 2024 12:29
To: users@cloudstack.apache.org <us...@cloudstack.apache.org>
Subject: Missing bridge/device network configuration

Hi,

I'm trying to add a host with ubuntu22 and a network generated by netplan, unfortunately I have the problem as below, have I missed something?

SSH command output:Starting to configure your system:
Configure Host ...            [OK]
Configure Apparmor ...        [OK]
Configure Network ...         [Failed]
Missing bridge/device network configuration, need to add your network configuration into /etc/network/interfaces at first
Try to restore your system:
Restore Host ...              [OK]
Restore Apparmor ...          [OK]
Restore Network ...           [OK]

Agetn setup.log:

DEBUG:root:execute:uname -r
DEBUG:root:execute:uname -m
DEBUG:root:execute:hostname -f
DEBUG:root:execute:kvm-ok
DEBUG:root:execute:awk '/MemTotal/ { printf "%.3f \n", $2/1024 }' /proc/meminfo
DEBUG:root:execute:ip a | grep "^\w" | grep -iv "^lo" | wc -l
DEBUG:root:execute:service apparmor status
DEBUG:root:execute:apparmor_status |grep libvirt
DEBUG:root:Failed to execute:
DEBUG:root:cloudbr0 is not a network device, is it down?
DEBUG:root:execute:sudo /usr/sbin/service network-manager status
DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
DEBUG:root:execute:route -n|awk '/^0.0.0.0/ {print $2,$8}'
DEBUG:root:execute:ifconfig host0
DEBUG:root:Found default network device:host0
DEBUG:root:execute:ifconfig host0.101
DEBUG:root:execute:sudo update-rc.d -f apparmor remove
DEBUG:root:execute:sudo update-rc.d -f apparmor defaults
DEBUG:root:execute:sudo /usr/sbin/service apparmor status
DEBUG:root:execute:sudo /usr/sbin/service apparmor start
DEBUG:root:execute:sudo /usr/sbin/service apparmor status
DEBUG:root:execute:sudo /usr/sbin/service apparmor start
DEBUG:root:execute:sudo update-rc.d -f network-manager remove
DEBUG:root:execute:sudo update-rc.d -f network-manager defaults
DEBUG:root:Failed to execute:update-rc.d: error: unable to read /etc/init.d/network-manager
DEBUG:root:execute:sudo /usr/sbin/service network-manager status
DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
DEBUG:root:execute:sudo /usr/sbin/service network-manager start
DEBUG:root:Failed to execute:Failed to start network-manager.service: Unit network-manager.service not found.
DEBUG:root:execute:sudo /usr/sbin/service network-manager status
DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
DEBUG:root:execute:sudo /usr/sbin/service network-manager start
DEBUG:root:Failed to execute:Failed to start network-manager.service: Unit network-manager.service not found.
DEBUG:root:execute:/etc/init.d/networking stop
DEBUG:root:Failed to execute:/bin/sh: 1: /etc/init.d/networking: not found
DEBUG:root:execute:/etc/init.d/networking start
DEBUG:root:Failed to execute:/bin/sh: 1: /etc/init.d/networking: not found

Bridges and netplan config:

root@sdc ~# brctl show
bridge name     bridge id               STP enabled     interfaces
ceph0           8000.963d69ccc23e       no              ceph0.102
docker0         8000.02428faeaa58       no
guest0          8000.dab6e62ba668       no              guest0.103
host0           8000.32335383ebbb       no              host0.101
public0         8000.aa725a4be728       no              public0.227
virbr0          8000.525400a74ecc       yes

network:
  version: 2
  renderer: networkd
  bonds:
    bond0:
      interfaces:
      - eno49
      - eno50
      parameters:
        lacp-rate: fast
        mode: 802.3ad
        transmit-hash-policy: layer3+4
      mtu: 9000
  ethernets:
    eno1: {}
    eno2: {}
    eno3: {}
    eno4: {}
    eno49:
      mtu: 9000
    eno50:
      mtu: 9000
  vlans:
    host0.101:
      dhcp4: no
      id: 101
      link: bond0
      mtu: 9000
    ceph0.102:
      dhcp4: no
      id: 102
      link: bond0
      mtu: 9000
    guest0.103:
      dhcp4: no
      id: 103
      link: bond0
      mtu: 9000
    public0.227:
      dhcp4: no
      id: 227
      link: bond0
      mtu: 9000
  bridges:
    host0:
      addresses:
      - 10.10.101.13/24
      nameservers:
        addresses:
        - 8.8.8.8
      routes:
      - to: default
        via: 10.10.101.254
      interfaces:
        - host0.101
    ceph0:
      addresses:
      - 10.10.102.13/24
      interfaces:
        - ceph0.102
    guest0:
      interfaces:
        - guest0.103
    public0:
      interfaces:
        - public0.227


Missing bridge/device network configuration

Posted by Piotr Pisz <pi...@piszki.pl>.
Hi,

I'm trying to add a host with ubuntu22 and a network generated by netplan, unfortunately I have the problem as below, have I missed something?

SSH command output:Starting to configure your system:
Configure Host ...            [OK]
Configure Apparmor ...        [OK]
Configure Network ...         [Failed]
Missing bridge/device network configuration, need to add your network configuration into /etc/network/interfaces at first
Try to restore your system:
Restore Host ...              [OK]
Restore Apparmor ...          [OK]
Restore Network ...           [OK]

Agetn setup.log:

DEBUG:root:execute:uname -r
DEBUG:root:execute:uname -m
DEBUG:root:execute:hostname -f
DEBUG:root:execute:kvm-ok
DEBUG:root:execute:awk '/MemTotal/ { printf "%.3f \n", $2/1024 }' /proc/meminfo
DEBUG:root:execute:ip a | grep "^\w" | grep -iv "^lo" | wc -l
DEBUG:root:execute:service apparmor status
DEBUG:root:execute:apparmor_status |grep libvirt
DEBUG:root:Failed to execute:
DEBUG:root:cloudbr0 is not a network device, is it down?
DEBUG:root:execute:sudo /usr/sbin/service network-manager status
DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
DEBUG:root:execute:route -n|awk '/^0.0.0.0/ {print $2,$8}'
DEBUG:root:execute:ifconfig host0
DEBUG:root:Found default network device:host0
DEBUG:root:execute:ifconfig host0.101
DEBUG:root:execute:sudo update-rc.d -f apparmor remove
DEBUG:root:execute:sudo update-rc.d -f apparmor defaults
DEBUG:root:execute:sudo /usr/sbin/service apparmor status
DEBUG:root:execute:sudo /usr/sbin/service apparmor start
DEBUG:root:execute:sudo /usr/sbin/service apparmor status
DEBUG:root:execute:sudo /usr/sbin/service apparmor start
DEBUG:root:execute:sudo update-rc.d -f network-manager remove
DEBUG:root:execute:sudo update-rc.d -f network-manager defaults
DEBUG:root:Failed to execute:update-rc.d: error: unable to read /etc/init.d/network-manager
DEBUG:root:execute:sudo /usr/sbin/service network-manager status
DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
DEBUG:root:execute:sudo /usr/sbin/service network-manager start
DEBUG:root:Failed to execute:Failed to start network-manager.service: Unit network-manager.service not found.
DEBUG:root:execute:sudo /usr/sbin/service network-manager status
DEBUG:root:Failed to execute:Unit network-manager.service could not be found.
DEBUG:root:execute:sudo /usr/sbin/service network-manager start
DEBUG:root:Failed to execute:Failed to start network-manager.service: Unit network-manager.service not found.
DEBUG:root:execute:/etc/init.d/networking stop
DEBUG:root:Failed to execute:/bin/sh: 1: /etc/init.d/networking: not found
DEBUG:root:execute:/etc/init.d/networking start
DEBUG:root:Failed to execute:/bin/sh: 1: /etc/init.d/networking: not found

Bridges and netplan config:

root@sdc ~# brctl show
bridge name     bridge id               STP enabled     interfaces
ceph0           8000.963d69ccc23e       no              ceph0.102
docker0         8000.02428faeaa58       no
guest0          8000.dab6e62ba668       no              guest0.103
host0           8000.32335383ebbb       no              host0.101
public0         8000.aa725a4be728       no              public0.227
virbr0          8000.525400a74ecc       yes

network:
  version: 2
  renderer: networkd
  bonds:
    bond0:
      interfaces:
      - eno49
      - eno50
      parameters:
        lacp-rate: fast
        mode: 802.3ad
        transmit-hash-policy: layer3+4
      mtu: 9000
  ethernets:
    eno1: {}
    eno2: {}
    eno3: {}
    eno4: {}
    eno49:
      mtu: 9000
    eno50:
      mtu: 9000
  vlans:
    host0.101:
      dhcp4: no
      id: 101
      link: bond0
      mtu: 9000
    ceph0.102:
      dhcp4: no
      id: 102
      link: bond0
      mtu: 9000
    guest0.103:
      dhcp4: no
      id: 103
      link: bond0
      mtu: 9000
    public0.227:
      dhcp4: no
      id: 227
      link: bond0
      mtu: 9000
  bridges:
    host0:
      addresses:
      - 10.10.101.13/24
      nameservers:
        addresses:
        - 8.8.8.8
      routes:
      - to: default
        via: 10.10.101.254
      interfaces:
        - host0.101
    ceph0:
      addresses:
      - 10.10.102.13/24
      interfaces:
        - ceph0.102
    guest0:
      interfaces:
        - guest0.103
    public0:
      interfaces:
        - public0.227


Re: Update Problem from 4.14 to 4.15

Posted by Info Manager <in...@activecloud.co.il>.
Hi , no ,
i did update from 4.14 to 4.15 , also 4.14 was updated from 4.13 that
released in 14.5.20 from shapeblue reps

On Sun, Jan 17, 2021 at 5:17 PM Rohit Yadav <ro...@shapeblue.com>
wrote:

> Hi Evegeni,
>
> Did you upgrade from ACS 4.14 (or some other build/fork such as ACP), or
> have any changes to schema or try to upgrade again after a failed upgrade
> before? I didn't face this issue while upgrading a local KVM based 4.14.0.0
> env to 4.15.0.0.
>
>
> Regards.
>
> ________________________________
> From: Info Manager <in...@activecloud.co.il>
> Sent: Sunday, January 17, 2021 18:18
> To: dev@cloudstack.apache.org <de...@cloudstack.apache.org>;
> users@cloudstack.apache.org <us...@cloudstack.apache.org>
> Subject: Update Problem from 4.14 to 4.15
>
> Hi all
>
> Have anyone such problems while updating?
>
> ----------------------
>
>  2021-01-17 01:42:47,466 DEBUG [c.c.u.d.ScriptRunner] (main:null) (logid:)
> ALTER TABLE `cloud`.`project_account`  ADD COLUMN `user_id` bigint unsigned
> COMMENT 'ID of user to be added to the project' AFTER `account_id`,  ADD
> CONSTRAINT `fk_project_account__user_id` FOREIGN KEY
> `fk_project_account__user_id`(`user_id`) REFERENCES `user`(`id`) ON DELETE
> CASCADE,  ADD COLUMN `project_role_id` bigint unsigned COMMENT 'Project
> role id' AFTER `project_account_id`,  ADD CONSTRAINT
> `fk_project_account__project_role_id` FOREIGN KEY (`project_role_id`)
> REFERENCES `project_role` (`id`) ON DELETE SET NULL,  DROP FOREIGN KEY
> `fk_project_account__account_id`,  DROP INDEX `account_id`
> 2021-01-17 01:42:47,480 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:)
> Error executing: ALTER TABLE `cloud`.`project_account`  ADD COLUMN
> `user_id` bigint unsigned COMMENT 'ID of user to be added to the project'
> AFTER `account_id`,  ADD CONSTRAINT `fk_project_account__user_id` FOREIGN
> KEY `fk_project_account__user_id`(`user_id`) REFERENCES `user`(`id`) ON
> DELETE CASCADE,  ADD COLUMN `project_role_id` bigint unsigned COMMENT
> 'Project role id' AFTER `project_account_id`,  ADD CONSTRAINT
> `fk_project_account__project_role_id` FOREIGN KEY (`project_role_id`)
> REFERENCES `project_role` (`id`) ON DELETE SET NULL,  DROP FOREIGN KEY
> `fk_project_account__account_id`,  DROP INDEX `account_id`
> 2021-01-17 01:42:47,480 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:)
> java.sql.SQLSyntaxErrorException: Can't DROP
> 'fk_project_account__account_id';
> check that column/key exists
> 2021-01-17 01:42:47,483 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null)
> (logid:) Unable to execute upgrade script
> java.sql.SQLSyntaxErrorException: Can't DROP
> 'fk_project_account__account_id';
> check that column/key exists
>         at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:185)
>         at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
> DatabaseUpgradeChecker.java:203)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(
> DatabaseUpgradeChecker.java:258)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.check(
> DatabaseUpgradeChecker.java:342)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.
> java:64)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> doStart(DefaultLifecycleProcessor.java:182)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> access$200(DefaultLifecycleProcessor.java:53)
>         at org.springframework.context.support.DefaultLifecycleProcessor$
> LifecycleGroup.start(DefaultLifecycleProcessor.java:360)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> startBeans(DefaultLifecycleProcessor.java:158)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> onRefresh(DefaultLifecycleProcessor.java:122)
>         at org.springframework.context.support.AbstractApplicationContext.
> finishRefresh(AbstractApplicationContext.java:894)
>         at org.springframework.context.support.AbstractApplicationContext.
> refresh(AbstractApplicationContext.java:553)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.java:144)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
>         at org.apache.cloudstack.spring.module.model.impl.
>
> DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.java:116)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
>         at org.apache.cloudstack.spring.module.factory.
> ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.init(CloudStackSpringContext.java:70)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:57)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:61)
>         at org.apache.cloudstack.spring.module.web.
> CloudStackContextLoaderListener.contextInitialized(
> CloudStackContextLoaderListener.java:51)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> callContextInitialized(ContextHandler.java:933)
>         at org.eclipse.jetty.servlet.ServletContextHandler.
> callContextInitialized(ServletContextHandler.java:553)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> startContext(ContextHandler.java:892)
>         at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
> ServletContextHandler.java:356)
>         at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
> WebAppContext.java:1445)
>         at org.eclipse.jetty.webapp.WebAppContext.startContext(
> WebAppContext.java:1409)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> doStart(ContextHandler.java:825)
>         at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
> ServletContextHandler.java:275)
>         at org.eclipse.jetty.webapp.WebAppContext.doStart(
> WebAppContext.java:524)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.handler.gzip.GzipHandler.
> doStart(GzipHandler.java:425)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:117)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.server.Server.start(Server.java:407)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.Server.doStart(Server.java:371)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.apache.cloudstack.ServerDaemon.start(ServerDaemon.java:188)
>         at org.apache.cloudstack.ServerDaemon.main(ServerDaemon.java:104)
> 2021-01-17 01:42:47,485 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null)
> (logid:) Unable to upgrade the database
> com.cloud.utils.exception.CloudRuntimeException: Unable to execute upgrade
> script
>         at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
> DatabaseUpgradeChecker.java:209)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(
> DatabaseUpgradeChecker.java:258)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.check(
> DatabaseUpgradeChecker.java:342)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.
> java:64)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> doStart(DefaultLifecycleProcessor.java:182)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> access$200(DefaultLifecycleProcessor.java:53)
>         at org.springframework.context.support.DefaultLifecycleProcessor$
> LifecycleGroup.start(DefaultLifecycleProcessor.java:360)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> startBeans(DefaultLifecycleProcessor.java:158)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> onRefresh(DefaultLifecycleProcessor.java:122)
>         at org.springframework.context.support.AbstractApplicationContext.
> finishRefresh(AbstractApplicationContext.java:894)
>         at org.springframework.context.support.AbstractApplicationContext.
> refresh(AbstractApplicationContext.java:553)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.java:144)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
>         at org.apache.cloudstack.spring.module.model.impl.
>
> DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.java:116)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
>         at org.apache.cloudstack.spring.module.factory.
> ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.init(CloudStackSpringContext.java:70)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:57)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:61)
>         at org.apache.cloudstack.spring.module.web.
> CloudStackContextLoaderListener.contextInitialized(
> CloudStackContextLoaderListener.java:51)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> callContextInitialized(ContextHandler.java:933)
>         at org.eclipse.jetty.servlet.ServletContextHandler.
> callContextInitialized(ServletContextHandler.java:553)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> startContext(ContextHandler.java:892)
>         at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
> ServletContextHandler.java:356)
>         at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
> WebAppContext.java:1445)
>         at org.eclipse.jetty.webapp.WebAppContext.startContext(
> WebAppContext.java:1409)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> doStart(ContextHandler.java:825)
>         at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
> ServletContextHandler.java:275)
>         at org.eclipse.jetty.webapp.WebAppContext.doStart(
> WebAppContext.java:524)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.handler.gzip.GzipHandler.
> doStart(GzipHandler.java:425)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:117)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.server.Server.start(Server.java:407)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.Server.doStart(Server.java:371)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.apache.cloudstack.ServerDaemon.start(ServerDaemon.java:188)
>         at org.apache.cloudstack.ServerDaemon.main(ServerDaemon.java:104)
> Caused by: java.sql.SQLSyntaxErrorException: Can't DROP
> 'fk_project_account__account_id'; check that column/key exists
>         at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:185)
>         at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
> DatabaseUpgradeChecker.java:203)
>         ... 50 more
> 2021-01-17 01:42:47,498 DEBUG [c.c.u.d.T.Transaction] (main:null) (logid:)
> Rolling back the transaction: Time = 27 Name =  Upgrade; called by
> -TransactionLegacy.rollback:888-TransactionLegacy.removeUpTo:831-
> TransactionLegacy.close:655-DatabaseUpgradeChecker.upgrade:273-
> DatabaseUpgradeChecker.check:342-CloudStackExtendedLifeCycle.
> checkIntegrity:64-CloudStackExtendedLifeCycle.start:54-
> DefaultLifecycleProcessor.doStart:182-DefaultLifecycleProcessor.
> access$200:53-DefaultLifecycleProcessor$LifecycleGroup.start:360-
> DefaultLifecycleProcessor.startBeans:158-DefaultLifecycleProcessor.
> onRefresh:122
> ----------------------
>
> THank's
>
> rohit.yadav@shapeblue.com
> www.shapeblue.com
> 3 London Bridge Street,  3rd floor, News Building, London  SE1 9SGUK
> @shapeblue
>
>
>
>

Re: Update Problem from 4.14 to 4.15

Posted by Info Manager <in...@activecloud.co.il>.
Hi , no ,
i did update from 4.14 to 4.15 , also 4.14 was updated from 4.13 that
released in 14.5.20 from shapeblue reps

On Sun, Jan 17, 2021 at 5:17 PM Rohit Yadav <ro...@shapeblue.com>
wrote:

> Hi Evegeni,
>
> Did you upgrade from ACS 4.14 (or some other build/fork such as ACP), or
> have any changes to schema or try to upgrade again after a failed upgrade
> before? I didn't face this issue while upgrading a local KVM based 4.14.0.0
> env to 4.15.0.0.
>
>
> Regards.
>
> ________________________________
> From: Info Manager <in...@activecloud.co.il>
> Sent: Sunday, January 17, 2021 18:18
> To: dev@cloudstack.apache.org <de...@cloudstack.apache.org>;
> users@cloudstack.apache.org <us...@cloudstack.apache.org>
> Subject: Update Problem from 4.14 to 4.15
>
> Hi all
>
> Have anyone such problems while updating?
>
> ----------------------
>
>  2021-01-17 01:42:47,466 DEBUG [c.c.u.d.ScriptRunner] (main:null) (logid:)
> ALTER TABLE `cloud`.`project_account`  ADD COLUMN `user_id` bigint unsigned
> COMMENT 'ID of user to be added to the project' AFTER `account_id`,  ADD
> CONSTRAINT `fk_project_account__user_id` FOREIGN KEY
> `fk_project_account__user_id`(`user_id`) REFERENCES `user`(`id`) ON DELETE
> CASCADE,  ADD COLUMN `project_role_id` bigint unsigned COMMENT 'Project
> role id' AFTER `project_account_id`,  ADD CONSTRAINT
> `fk_project_account__project_role_id` FOREIGN KEY (`project_role_id`)
> REFERENCES `project_role` (`id`) ON DELETE SET NULL,  DROP FOREIGN KEY
> `fk_project_account__account_id`,  DROP INDEX `account_id`
> 2021-01-17 01:42:47,480 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:)
> Error executing: ALTER TABLE `cloud`.`project_account`  ADD COLUMN
> `user_id` bigint unsigned COMMENT 'ID of user to be added to the project'
> AFTER `account_id`,  ADD CONSTRAINT `fk_project_account__user_id` FOREIGN
> KEY `fk_project_account__user_id`(`user_id`) REFERENCES `user`(`id`) ON
> DELETE CASCADE,  ADD COLUMN `project_role_id` bigint unsigned COMMENT
> 'Project role id' AFTER `project_account_id`,  ADD CONSTRAINT
> `fk_project_account__project_role_id` FOREIGN KEY (`project_role_id`)
> REFERENCES `project_role` (`id`) ON DELETE SET NULL,  DROP FOREIGN KEY
> `fk_project_account__account_id`,  DROP INDEX `account_id`
> 2021-01-17 01:42:47,480 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:)
> java.sql.SQLSyntaxErrorException: Can't DROP
> 'fk_project_account__account_id';
> check that column/key exists
> 2021-01-17 01:42:47,483 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null)
> (logid:) Unable to execute upgrade script
> java.sql.SQLSyntaxErrorException: Can't DROP
> 'fk_project_account__account_id';
> check that column/key exists
>         at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:185)
>         at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
> DatabaseUpgradeChecker.java:203)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(
> DatabaseUpgradeChecker.java:258)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.check(
> DatabaseUpgradeChecker.java:342)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.
> java:64)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> doStart(DefaultLifecycleProcessor.java:182)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> access$200(DefaultLifecycleProcessor.java:53)
>         at org.springframework.context.support.DefaultLifecycleProcessor$
> LifecycleGroup.start(DefaultLifecycleProcessor.java:360)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> startBeans(DefaultLifecycleProcessor.java:158)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> onRefresh(DefaultLifecycleProcessor.java:122)
>         at org.springframework.context.support.AbstractApplicationContext.
> finishRefresh(AbstractApplicationContext.java:894)
>         at org.springframework.context.support.AbstractApplicationContext.
> refresh(AbstractApplicationContext.java:553)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.java:144)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
>         at org.apache.cloudstack.spring.module.model.impl.
>
> DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.java:116)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
>         at org.apache.cloudstack.spring.module.factory.
> ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.init(CloudStackSpringContext.java:70)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:57)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:61)
>         at org.apache.cloudstack.spring.module.web.
> CloudStackContextLoaderListener.contextInitialized(
> CloudStackContextLoaderListener.java:51)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> callContextInitialized(ContextHandler.java:933)
>         at org.eclipse.jetty.servlet.ServletContextHandler.
> callContextInitialized(ServletContextHandler.java:553)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> startContext(ContextHandler.java:892)
>         at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
> ServletContextHandler.java:356)
>         at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
> WebAppContext.java:1445)
>         at org.eclipse.jetty.webapp.WebAppContext.startContext(
> WebAppContext.java:1409)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> doStart(ContextHandler.java:825)
>         at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
> ServletContextHandler.java:275)
>         at org.eclipse.jetty.webapp.WebAppContext.doStart(
> WebAppContext.java:524)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.handler.gzip.GzipHandler.
> doStart(GzipHandler.java:425)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:117)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.server.Server.start(Server.java:407)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.Server.doStart(Server.java:371)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.apache.cloudstack.ServerDaemon.start(ServerDaemon.java:188)
>         at org.apache.cloudstack.ServerDaemon.main(ServerDaemon.java:104)
> 2021-01-17 01:42:47,485 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null)
> (logid:) Unable to upgrade the database
> com.cloud.utils.exception.CloudRuntimeException: Unable to execute upgrade
> script
>         at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
> DatabaseUpgradeChecker.java:209)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(
> DatabaseUpgradeChecker.java:258)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.check(
> DatabaseUpgradeChecker.java:342)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.
> java:64)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> doStart(DefaultLifecycleProcessor.java:182)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> access$200(DefaultLifecycleProcessor.java:53)
>         at org.springframework.context.support.DefaultLifecycleProcessor$
> LifecycleGroup.start(DefaultLifecycleProcessor.java:360)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> startBeans(DefaultLifecycleProcessor.java:158)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> onRefresh(DefaultLifecycleProcessor.java:122)
>         at org.springframework.context.support.AbstractApplicationContext.
> finishRefresh(AbstractApplicationContext.java:894)
>         at org.springframework.context.support.AbstractApplicationContext.
> refresh(AbstractApplicationContext.java:553)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.java:144)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
>         at org.apache.cloudstack.spring.module.model.impl.
>
> DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.java:116)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
>         at org.apache.cloudstack.spring.module.factory.
> ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.init(CloudStackSpringContext.java:70)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:57)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:61)
>         at org.apache.cloudstack.spring.module.web.
> CloudStackContextLoaderListener.contextInitialized(
> CloudStackContextLoaderListener.java:51)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> callContextInitialized(ContextHandler.java:933)
>         at org.eclipse.jetty.servlet.ServletContextHandler.
> callContextInitialized(ServletContextHandler.java:553)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> startContext(ContextHandler.java:892)
>         at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
> ServletContextHandler.java:356)
>         at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
> WebAppContext.java:1445)
>         at org.eclipse.jetty.webapp.WebAppContext.startContext(
> WebAppContext.java:1409)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> doStart(ContextHandler.java:825)
>         at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
> ServletContextHandler.java:275)
>         at org.eclipse.jetty.webapp.WebAppContext.doStart(
> WebAppContext.java:524)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.handler.gzip.GzipHandler.
> doStart(GzipHandler.java:425)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:117)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.server.Server.start(Server.java:407)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.Server.doStart(Server.java:371)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.apache.cloudstack.ServerDaemon.start(ServerDaemon.java:188)
>         at org.apache.cloudstack.ServerDaemon.main(ServerDaemon.java:104)
> Caused by: java.sql.SQLSyntaxErrorException: Can't DROP
> 'fk_project_account__account_id'; check that column/key exists
>         at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:185)
>         at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
> DatabaseUpgradeChecker.java:203)
>         ... 50 more
> 2021-01-17 01:42:47,498 DEBUG [c.c.u.d.T.Transaction] (main:null) (logid:)
> Rolling back the transaction: Time = 27 Name =  Upgrade; called by
> -TransactionLegacy.rollback:888-TransactionLegacy.removeUpTo:831-
> TransactionLegacy.close:655-DatabaseUpgradeChecker.upgrade:273-
> DatabaseUpgradeChecker.check:342-CloudStackExtendedLifeCycle.
> checkIntegrity:64-CloudStackExtendedLifeCycle.start:54-
> DefaultLifecycleProcessor.doStart:182-DefaultLifecycleProcessor.
> access$200:53-DefaultLifecycleProcessor$LifecycleGroup.start:360-
> DefaultLifecycleProcessor.startBeans:158-DefaultLifecycleProcessor.
> onRefresh:122
> ----------------------
>
> THank's
>
> rohit.yadav@shapeblue.com
> www.shapeblue.com
> 3 London Bridge Street,  3rd floor, News Building, London  SE1 9SGUK
> @shapeblue
>
>
>
>

Re: Update Problem from 4.14 to 4.15

Posted by Rohit Yadav <ro...@shapeblue.com>.
Hi Evegeni,

Did you upgrade from ACS 4.14 (or some other build/fork such as ACP), or have any changes to schema or try to upgrade again after a failed upgrade before? I didn't face this issue while upgrading a local KVM based 4.14.0.0 env to 4.15.0.0.


Regards.

________________________________
From: Info Manager <in...@activecloud.co.il>
Sent: Sunday, January 17, 2021 18:18
To: dev@cloudstack.apache.org <de...@cloudstack.apache.org>; users@cloudstack.apache.org <us...@cloudstack.apache.org>
Subject: Update Problem from 4.14 to 4.15

Hi all

Have anyone such problems while updating?

----------------------

 2021-01-17 01:42:47,466 DEBUG [c.c.u.d.ScriptRunner] (main:null) (logid:)
ALTER TABLE `cloud`.`project_account`  ADD COLUMN `user_id` bigint unsigned
COMMENT 'ID of user to be added to the project' AFTER `account_id`,  ADD
CONSTRAINT `fk_project_account__user_id` FOREIGN KEY
`fk_project_account__user_id`(`user_id`) REFERENCES `user`(`id`) ON DELETE
CASCADE,  ADD COLUMN `project_role_id` bigint unsigned COMMENT 'Project
role id' AFTER `project_account_id`,  ADD CONSTRAINT
`fk_project_account__project_role_id` FOREIGN KEY (`project_role_id`)
REFERENCES `project_role` (`id`) ON DELETE SET NULL,  DROP FOREIGN KEY
`fk_project_account__account_id`,  DROP INDEX `account_id`
2021-01-17 01:42:47,480 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:)
Error executing: ALTER TABLE `cloud`.`project_account`  ADD COLUMN
`user_id` bigint unsigned COMMENT 'ID of user to be added to the project'
AFTER `account_id`,  ADD CONSTRAINT `fk_project_account__user_id` FOREIGN
KEY `fk_project_account__user_id`(`user_id`) REFERENCES `user`(`id`) ON
DELETE CASCADE,  ADD COLUMN `project_role_id` bigint unsigned COMMENT
'Project role id' AFTER `project_account_id`,  ADD CONSTRAINT
`fk_project_account__project_role_id` FOREIGN KEY (`project_role_id`)
REFERENCES `project_role` (`id`) ON DELETE SET NULL,  DROP FOREIGN KEY
`fk_project_account__account_id`,  DROP INDEX `account_id`
2021-01-17 01:42:47,480 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:)
java.sql.SQLSyntaxErrorException: Can't DROP 'fk_project_account__account_id';
check that column/key exists
2021-01-17 01:42:47,483 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null)
(logid:) Unable to execute upgrade script
java.sql.SQLSyntaxErrorException: Can't DROP 'fk_project_account__account_id';
check that column/key exists
        at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:185)
        at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
        at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
DatabaseUpgradeChecker.java:203)
        at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(
DatabaseUpgradeChecker.java:258)
        at com.cloud.upgrade.DatabaseUpgradeChecker.check(
DatabaseUpgradeChecker.java:342)
        at org.apache.cloudstack.spring.lifecycle.
CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.
java:64)
        at org.apache.cloudstack.spring.lifecycle.
CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
        at org.springframework.context.support.DefaultLifecycleProcessor.
doStart(DefaultLifecycleProcessor.java:182)
        at org.springframework.context.support.DefaultLifecycleProcessor.
access$200(DefaultLifecycleProcessor.java:53)
        at org.springframework.context.support.DefaultLifecycleProcessor$
LifecycleGroup.start(DefaultLifecycleProcessor.java:360)
        at org.springframework.context.support.DefaultLifecycleProcessor.
startBeans(DefaultLifecycleProcessor.java:158)
        at org.springframework.context.support.DefaultLifecycleProcessor.
onRefresh(DefaultLifecycleProcessor.java:122)
        at org.springframework.context.support.AbstractApplicationContext.
finishRefresh(AbstractApplicationContext.java:894)
        at org.springframework.context.support.AbstractApplicationContext.
refresh(AbstractApplicationContext.java:553)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.java:144)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.java:116)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
        at org.apache.cloudstack.spring.module.factory.
ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.init(CloudStackSpringContext.java:70)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.<init>(CloudStackSpringContext.java:57)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.<init>(CloudStackSpringContext.java:61)
        at org.apache.cloudstack.spring.module.web.
CloudStackContextLoaderListener.contextInitialized(
CloudStackContextLoaderListener.java:51)
        at org.eclipse.jetty.server.handler.ContextHandler.
callContextInitialized(ContextHandler.java:933)
        at org.eclipse.jetty.servlet.ServletContextHandler.
callContextInitialized(ServletContextHandler.java:553)
        at org.eclipse.jetty.server.handler.ContextHandler.
startContext(ContextHandler.java:892)
        at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
ServletContextHandler.java:356)
        at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
WebAppContext.java:1445)
        at org.eclipse.jetty.webapp.WebAppContext.startContext(
WebAppContext.java:1409)
        at org.eclipse.jetty.server.handler.ContextHandler.
doStart(ContextHandler.java:825)
        at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
ServletContextHandler.java:275)
        at org.eclipse.jetty.webapp.WebAppContext.doStart(
WebAppContext.java:524)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:110)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.server.handler.gzip.GzipHandler.
doStart(GzipHandler.java:425)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:117)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.server.Server.start(Server.java:407)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:110)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.server.Server.doStart(Server.java:371)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.apache.cloudstack.ServerDaemon.start(ServerDaemon.java:188)
        at org.apache.cloudstack.ServerDaemon.main(ServerDaemon.java:104)
2021-01-17 01:42:47,485 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null)
(logid:) Unable to upgrade the database
com.cloud.utils.exception.CloudRuntimeException: Unable to execute upgrade
script
        at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
DatabaseUpgradeChecker.java:209)
        at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(
DatabaseUpgradeChecker.java:258)
        at com.cloud.upgrade.DatabaseUpgradeChecker.check(
DatabaseUpgradeChecker.java:342)
        at org.apache.cloudstack.spring.lifecycle.
CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.
java:64)
        at org.apache.cloudstack.spring.lifecycle.
CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
        at org.springframework.context.support.DefaultLifecycleProcessor.
doStart(DefaultLifecycleProcessor.java:182)
        at org.springframework.context.support.DefaultLifecycleProcessor.
access$200(DefaultLifecycleProcessor.java:53)
        at org.springframework.context.support.DefaultLifecycleProcessor$
LifecycleGroup.start(DefaultLifecycleProcessor.java:360)
        at org.springframework.context.support.DefaultLifecycleProcessor.
startBeans(DefaultLifecycleProcessor.java:158)
        at org.springframework.context.support.DefaultLifecycleProcessor.
onRefresh(DefaultLifecycleProcessor.java:122)
        at org.springframework.context.support.AbstractApplicationContext.
finishRefresh(AbstractApplicationContext.java:894)
        at org.springframework.context.support.AbstractApplicationContext.
refresh(AbstractApplicationContext.java:553)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.java:144)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.java:116)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
        at org.apache.cloudstack.spring.module.factory.
ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.init(CloudStackSpringContext.java:70)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.<init>(CloudStackSpringContext.java:57)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.<init>(CloudStackSpringContext.java:61)
        at org.apache.cloudstack.spring.module.web.
CloudStackContextLoaderListener.contextInitialized(
CloudStackContextLoaderListener.java:51)
        at org.eclipse.jetty.server.handler.ContextHandler.
callContextInitialized(ContextHandler.java:933)
        at org.eclipse.jetty.servlet.ServletContextHandler.
callContextInitialized(ServletContextHandler.java:553)
        at org.eclipse.jetty.server.handler.ContextHandler.
startContext(ContextHandler.java:892)
        at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
ServletContextHandler.java:356)
        at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
WebAppContext.java:1445)
        at org.eclipse.jetty.webapp.WebAppContext.startContext(
WebAppContext.java:1409)
        at org.eclipse.jetty.server.handler.ContextHandler.
doStart(ContextHandler.java:825)
        at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
ServletContextHandler.java:275)
        at org.eclipse.jetty.webapp.WebAppContext.doStart(
WebAppContext.java:524)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:110)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.server.handler.gzip.GzipHandler.
doStart(GzipHandler.java:425)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:117)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.server.Server.start(Server.java:407)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:110)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.server.Server.doStart(Server.java:371)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.apache.cloudstack.ServerDaemon.start(ServerDaemon.java:188)
        at org.apache.cloudstack.ServerDaemon.main(ServerDaemon.java:104)
Caused by: java.sql.SQLSyntaxErrorException: Can't DROP
'fk_project_account__account_id'; check that column/key exists
        at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:185)
        at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
        at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
DatabaseUpgradeChecker.java:203)
        ... 50 more
2021-01-17 01:42:47,498 DEBUG [c.c.u.d.T.Transaction] (main:null) (logid:)
Rolling back the transaction: Time = 27 Name =  Upgrade; called by
-TransactionLegacy.rollback:888-TransactionLegacy.removeUpTo:831-
TransactionLegacy.close:655-DatabaseUpgradeChecker.upgrade:273-
DatabaseUpgradeChecker.check:342-CloudStackExtendedLifeCycle.
checkIntegrity:64-CloudStackExtendedLifeCycle.start:54-
DefaultLifecycleProcessor.doStart:182-DefaultLifecycleProcessor.
access$200:53-DefaultLifecycleProcessor$LifecycleGroup.start:360-
DefaultLifecycleProcessor.startBeans:158-DefaultLifecycleProcessor.
onRefresh:122
----------------------

THank's

rohit.yadav@shapeblue.com 
www.shapeblue.com
3 London Bridge Street,  3rd floor, News Building, London  SE1 9SGUK
@shapeblue
  
 


Re: Update Problem from 4.14 to 4.15

Posted by Rohit Yadav <ro...@shapeblue.com>.
Hi Evegeni,

Did you upgrade from ACS 4.14 (or some other build/fork such as ACP), or have any changes to schema or try to upgrade again after a failed upgrade before? I didn't face this issue while upgrading a local KVM based 4.14.0.0 env to 4.15.0.0.


Regards.

________________________________
From: Info Manager <in...@activecloud.co.il>
Sent: Sunday, January 17, 2021 18:18
To: dev@cloudstack.apache.org <de...@cloudstack.apache.org>; users@cloudstack.apache.org <us...@cloudstack.apache.org>
Subject: Update Problem from 4.14 to 4.15

Hi all

Have anyone such problems while updating?

----------------------

 2021-01-17 01:42:47,466 DEBUG [c.c.u.d.ScriptRunner] (main:null) (logid:)
ALTER TABLE `cloud`.`project_account`  ADD COLUMN `user_id` bigint unsigned
COMMENT 'ID of user to be added to the project' AFTER `account_id`,  ADD
CONSTRAINT `fk_project_account__user_id` FOREIGN KEY
`fk_project_account__user_id`(`user_id`) REFERENCES `user`(`id`) ON DELETE
CASCADE,  ADD COLUMN `project_role_id` bigint unsigned COMMENT 'Project
role id' AFTER `project_account_id`,  ADD CONSTRAINT
`fk_project_account__project_role_id` FOREIGN KEY (`project_role_id`)
REFERENCES `project_role` (`id`) ON DELETE SET NULL,  DROP FOREIGN KEY
`fk_project_account__account_id`,  DROP INDEX `account_id`
2021-01-17 01:42:47,480 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:)
Error executing: ALTER TABLE `cloud`.`project_account`  ADD COLUMN
`user_id` bigint unsigned COMMENT 'ID of user to be added to the project'
AFTER `account_id`,  ADD CONSTRAINT `fk_project_account__user_id` FOREIGN
KEY `fk_project_account__user_id`(`user_id`) REFERENCES `user`(`id`) ON
DELETE CASCADE,  ADD COLUMN `project_role_id` bigint unsigned COMMENT
'Project role id' AFTER `project_account_id`,  ADD CONSTRAINT
`fk_project_account__project_role_id` FOREIGN KEY (`project_role_id`)
REFERENCES `project_role` (`id`) ON DELETE SET NULL,  DROP FOREIGN KEY
`fk_project_account__account_id`,  DROP INDEX `account_id`
2021-01-17 01:42:47,480 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:)
java.sql.SQLSyntaxErrorException: Can't DROP 'fk_project_account__account_id';
check that column/key exists
2021-01-17 01:42:47,483 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null)
(logid:) Unable to execute upgrade script
java.sql.SQLSyntaxErrorException: Can't DROP 'fk_project_account__account_id';
check that column/key exists
        at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:185)
        at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
        at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
DatabaseUpgradeChecker.java:203)
        at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(
DatabaseUpgradeChecker.java:258)
        at com.cloud.upgrade.DatabaseUpgradeChecker.check(
DatabaseUpgradeChecker.java:342)
        at org.apache.cloudstack.spring.lifecycle.
CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.
java:64)
        at org.apache.cloudstack.spring.lifecycle.
CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
        at org.springframework.context.support.DefaultLifecycleProcessor.
doStart(DefaultLifecycleProcessor.java:182)
        at org.springframework.context.support.DefaultLifecycleProcessor.
access$200(DefaultLifecycleProcessor.java:53)
        at org.springframework.context.support.DefaultLifecycleProcessor$
LifecycleGroup.start(DefaultLifecycleProcessor.java:360)
        at org.springframework.context.support.DefaultLifecycleProcessor.
startBeans(DefaultLifecycleProcessor.java:158)
        at org.springframework.context.support.DefaultLifecycleProcessor.
onRefresh(DefaultLifecycleProcessor.java:122)
        at org.springframework.context.support.AbstractApplicationContext.
finishRefresh(AbstractApplicationContext.java:894)
        at org.springframework.context.support.AbstractApplicationContext.
refresh(AbstractApplicationContext.java:553)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.java:144)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.java:116)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
        at org.apache.cloudstack.spring.module.factory.
ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.init(CloudStackSpringContext.java:70)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.<init>(CloudStackSpringContext.java:57)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.<init>(CloudStackSpringContext.java:61)
        at org.apache.cloudstack.spring.module.web.
CloudStackContextLoaderListener.contextInitialized(
CloudStackContextLoaderListener.java:51)
        at org.eclipse.jetty.server.handler.ContextHandler.
callContextInitialized(ContextHandler.java:933)
        at org.eclipse.jetty.servlet.ServletContextHandler.
callContextInitialized(ServletContextHandler.java:553)
        at org.eclipse.jetty.server.handler.ContextHandler.
startContext(ContextHandler.java:892)
        at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
ServletContextHandler.java:356)
        at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
WebAppContext.java:1445)
        at org.eclipse.jetty.webapp.WebAppContext.startContext(
WebAppContext.java:1409)
        at org.eclipse.jetty.server.handler.ContextHandler.
doStart(ContextHandler.java:825)
        at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
ServletContextHandler.java:275)
        at org.eclipse.jetty.webapp.WebAppContext.doStart(
WebAppContext.java:524)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:110)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.server.handler.gzip.GzipHandler.
doStart(GzipHandler.java:425)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:117)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.server.Server.start(Server.java:407)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:110)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.server.Server.doStart(Server.java:371)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.apache.cloudstack.ServerDaemon.start(ServerDaemon.java:188)
        at org.apache.cloudstack.ServerDaemon.main(ServerDaemon.java:104)
2021-01-17 01:42:47,485 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null)
(logid:) Unable to upgrade the database
com.cloud.utils.exception.CloudRuntimeException: Unable to execute upgrade
script
        at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
DatabaseUpgradeChecker.java:209)
        at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(
DatabaseUpgradeChecker.java:258)
        at com.cloud.upgrade.DatabaseUpgradeChecker.check(
DatabaseUpgradeChecker.java:342)
        at org.apache.cloudstack.spring.lifecycle.
CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.
java:64)
        at org.apache.cloudstack.spring.lifecycle.
CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
        at org.springframework.context.support.DefaultLifecycleProcessor.
doStart(DefaultLifecycleProcessor.java:182)
        at org.springframework.context.support.DefaultLifecycleProcessor.
access$200(DefaultLifecycleProcessor.java:53)
        at org.springframework.context.support.DefaultLifecycleProcessor$
LifecycleGroup.start(DefaultLifecycleProcessor.java:360)
        at org.springframework.context.support.DefaultLifecycleProcessor.
startBeans(DefaultLifecycleProcessor.java:158)
        at org.springframework.context.support.DefaultLifecycleProcessor.
onRefresh(DefaultLifecycleProcessor.java:122)
        at org.springframework.context.support.AbstractApplicationContext.
finishRefresh(AbstractApplicationContext.java:894)
        at org.springframework.context.support.AbstractApplicationContext.
refresh(AbstractApplicationContext.java:553)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.java:144)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.java:116)
        at org.apache.cloudstack.spring.module.model.impl.
DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
        at org.apache.cloudstack.spring.module.factory.
ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.init(CloudStackSpringContext.java:70)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.<init>(CloudStackSpringContext.java:57)
        at org.apache.cloudstack.spring.module.factory.
CloudStackSpringContext.<init>(CloudStackSpringContext.java:61)
        at org.apache.cloudstack.spring.module.web.
CloudStackContextLoaderListener.contextInitialized(
CloudStackContextLoaderListener.java:51)
        at org.eclipse.jetty.server.handler.ContextHandler.
callContextInitialized(ContextHandler.java:933)
        at org.eclipse.jetty.servlet.ServletContextHandler.
callContextInitialized(ServletContextHandler.java:553)
        at org.eclipse.jetty.server.handler.ContextHandler.
startContext(ContextHandler.java:892)
        at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
ServletContextHandler.java:356)
        at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
WebAppContext.java:1445)
        at org.eclipse.jetty.webapp.WebAppContext.startContext(
WebAppContext.java:1409)
        at org.eclipse.jetty.server.handler.ContextHandler.
doStart(ContextHandler.java:825)
        at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
ServletContextHandler.java:275)
        at org.eclipse.jetty.webapp.WebAppContext.doStart(
WebAppContext.java:524)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:110)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.server.handler.gzip.GzipHandler.
doStart(GzipHandler.java:425)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:117)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
start(ContainerLifeCycle.java:169)
        at org.eclipse.jetty.server.Server.start(Server.java:407)
        at org.eclipse.jetty.util.component.ContainerLifeCycle.
doStart(ContainerLifeCycle.java:110)
        at org.eclipse.jetty.server.handler.AbstractHandler.
doStart(AbstractHandler.java:97)
        at org.eclipse.jetty.server.Server.doStart(Server.java:371)
        at org.eclipse.jetty.util.component.AbstractLifeCycle.
start(AbstractLifeCycle.java:72)
        at org.apache.cloudstack.ServerDaemon.start(ServerDaemon.java:188)
        at org.apache.cloudstack.ServerDaemon.main(ServerDaemon.java:104)
Caused by: java.sql.SQLSyntaxErrorException: Can't DROP
'fk_project_account__account_id'; check that column/key exists
        at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:185)
        at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
        at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
DatabaseUpgradeChecker.java:203)
        ... 50 more
2021-01-17 01:42:47,498 DEBUG [c.c.u.d.T.Transaction] (main:null) (logid:)
Rolling back the transaction: Time = 27 Name =  Upgrade; called by
-TransactionLegacy.rollback:888-TransactionLegacy.removeUpTo:831-
TransactionLegacy.close:655-DatabaseUpgradeChecker.upgrade:273-
DatabaseUpgradeChecker.check:342-CloudStackExtendedLifeCycle.
checkIntegrity:64-CloudStackExtendedLifeCycle.start:54-
DefaultLifecycleProcessor.doStart:182-DefaultLifecycleProcessor.
access$200:53-DefaultLifecycleProcessor$LifecycleGroup.start:360-
DefaultLifecycleProcessor.startBeans:158-DefaultLifecycleProcessor.
onRefresh:122
----------------------

THank's

rohit.yadav@shapeblue.com 
www.shapeblue.com
3 London Bridge Street,  3rd floor, News Building, London  SE1 9SGUK
@shapeblue
  
 


Re: Update Problem from 4.14 to 4.15

Posted by Rohit Yadav <ro...@shapeblue.com>.
Hi Evigeni,

Looks like a DB upgrade was attempted and it failed (forgot to register 4.15 systemvmtemplate for example) and the upgrade was retried, if you've DB dumps you can restore it back to 4.14 and retry upgrade. The other solution is to look at the SQL error on case by case basis, manually fix it and try the upgrade (stop+start mgmt server process) again.



Regards.

________________________________
From: Wei ZHOU <us...@gmail.com>
Sent: Monday, January 18, 2021 00:46
To: dev@cloudstack.apache.org <de...@cloudstack.apache.org>
Subject: Re: Update Problem from 4.14 to 4.15

Hi,

Is this the first time you try to upgrade cloudstack from 4.14 to 4.15?
Is there failed attempt prior to this upgrade?

-Wei


On Sunday, 17 January 2021, Info Manager <in...@activecloud.co.il> wrote:

> Hi all
>
> Have anyone such problems while updating?
>
> ----------------------
>
>  2021-01-17 01:42:47,466 DEBUG [c.c.u.d.ScriptRunner] (main:null) (logid:)
> ALTER TABLE `cloud`.`project_account`  ADD COLUMN `user_id` bigint unsigned
> COMMENT 'ID of user to be added to the project' AFTER `account_id`,  ADD
> CONSTRAINT `fk_project_account__user_id` FOREIGN KEY
> `fk_project_account__user_id`(`user_id`) REFERENCES `user`(`id`) ON DELETE
> CASCADE,  ADD COLUMN `project_role_id` bigint unsigned COMMENT 'Project
> role id' AFTER `project_account_id`,  ADD CONSTRAINT
> `fk_project_account__project_role_id` FOREIGN KEY (`project_role_id`)
> REFERENCES `project_role` (`id`) ON DELETE SET NULL,  DROP FOREIGN KEY
> `fk_project_account__account_id`,  DROP INDEX `account_id`
> 2021-01-17 01:42:47,480 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:)
> Error executing: ALTER TABLE `cloud`.`project_account`  ADD COLUMN
> `user_id` bigint unsigned COMMENT 'ID of user to be added to the project'
> AFTER `account_id`,  ADD CONSTRAINT `fk_project_account__user_id` FOREIGN
> KEY `fk_project_account__user_id`(`user_id`) REFERENCES `user`(`id`) ON
> DELETE CASCADE,  ADD COLUMN `project_role_id` bigint unsigned COMMENT
> 'Project role id' AFTER `project_account_id`,  ADD CONSTRAINT
> `fk_project_account__project_role_id` FOREIGN KEY (`project_role_id`)
> REFERENCES `project_role` (`id`) ON DELETE SET NULL,  DROP FOREIGN KEY
> `fk_project_account__account_id`,  DROP INDEX `account_id`
> 2021-01-17 01:42:47,480 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:)
> java.sql.SQLSyntaxErrorException: Can't DROP 'fk_project_account__account_
> id';
> check that column/key exists
> 2021-01-17 01:42:47,483 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null)
> (logid:) Unable to execute upgrade script
> java.sql.SQLSyntaxErrorException: Can't DROP 'fk_project_account__account_
> id';
> check that column/key exists
>         at com.cloud.utils.db.ScriptRunner.runScript(
> ScriptRunner.java:185)
>         at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
> DatabaseUpgradeChecker.java:203)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(
> DatabaseUpgradeChecker.java:258)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.check(
> DatabaseUpgradeChecker.java:342)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.
> java:64)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> doStart(DefaultLifecycleProcessor.java:182)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> access$200(DefaultLifecycleProcessor.java:53)
>         at org.springframework.context.support.DefaultLifecycleProcessor$
> LifecycleGroup.start(DefaultLifecycleProcessor.java:360)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> startBeans(DefaultLifecycleProcessor.java:158)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> onRefresh(DefaultLifecycleProcessor.java:122)
>         at org.springframework.context.support.AbstractApplicationContext.
> finishRefresh(AbstractApplicationContext.java:894)
>         at org.springframework.context.support.AbstractApplicationContext.
> refresh(AbstractApplicationContext.java:553)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.
> java:144)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.
> java:116)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
>         at org.apache.cloudstack.spring.module.factory.
> ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.init(CloudStackSpringContext.java:70)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:57)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:61)
>         at org.apache.cloudstack.spring.module.web.
> CloudStackContextLoaderListener.contextInitialized(
> CloudStackContextLoaderListener.java:51)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> callContextInitialized(ContextHandler.java:933)
>         at org.eclipse.jetty.servlet.ServletContextHandler.
> callContextInitialized(ServletContextHandler.java:553)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> startContext(ContextHandler.java:892)
>         at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
> ServletContextHandler.java:356)
>         at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
> WebAppContext.java:1445)
>         at org.eclipse.jetty.webapp.WebAppContext.startContext(
> WebAppContext.java:1409)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> doStart(ContextHandler.java:825)
>         at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
> ServletContextHandler.java:275)
>         at org.eclipse.jetty.webapp.WebAppContext.doStart(
> WebAppContext.java:524)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.handler.gzip.GzipHandler.
> doStart(GzipHandler.java:425)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:117)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.server.Server.start(Server.java:407)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.Server.doStart(Server.java:371)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.apache.cloudstack.ServerDaemon.start(ServerDaemon.java:188)
>         at org.apache.cloudstack.ServerDaemon.main(ServerDaemon.java:104)
> 2021-01-17 01:42:47,485 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null)
> (logid:) Unable to upgrade the database
> com.cloud.utils.exception.CloudRuntimeException: Unable to execute upgrade
> script
>         at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
> DatabaseUpgradeChecker.java:209)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(
> DatabaseUpgradeChecker.java:258)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.check(
> DatabaseUpgradeChecker.java:342)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.
> java:64)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> doStart(DefaultLifecycleProcessor.java:182)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> access$200(DefaultLifecycleProcessor.java:53)
>         at org.springframework.context.support.DefaultLifecycleProcessor$
> LifecycleGroup.start(DefaultLifecycleProcessor.java:360)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> startBeans(DefaultLifecycleProcessor.java:158)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> onRefresh(DefaultLifecycleProcessor.java:122)
>         at org.springframework.context.support.AbstractApplicationContext.
> finishRefresh(AbstractApplicationContext.java:894)
>         at org.springframework.context.support.AbstractApplicationContext.
> refresh(AbstractApplicationContext.java:553)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.
> java:144)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.
> java:116)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
>         at org.apache.cloudstack.spring.module.factory.
> ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.init(CloudStackSpringContext.java:70)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:57)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:61)
>         at org.apache.cloudstack.spring.module.web.
> CloudStackContextLoaderListener.contextInitialized(
> CloudStackContextLoaderListener.java:51)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> callContextInitialized(ContextHandler.java:933)
>         at org.eclipse.jetty.servlet.ServletContextHandler.
> callContextInitialized(ServletContextHandler.java:553)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> startContext(ContextHandler.java:892)
>         at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
> ServletContextHandler.java:356)
>         at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
> WebAppContext.java:1445)
>         at org.eclipse.jetty.webapp.WebAppContext.startContext(
> WebAppContext.java:1409)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> doStart(ContextHandler.java:825)
>         at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
> ServletContextHandler.java:275)
>         at org.eclipse.jetty.webapp.WebAppContext.doStart(
> WebAppContext.java:524)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.handler.gzip.GzipHandler.
> doStart(GzipHandler.java:425)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:117)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.server.Server.start(Server.java:407)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.Server.doStart(Server.java:371)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.apache.cloudstack.ServerDaemon.start(ServerDaemon.java:188)
>         at org.apache.cloudstack.ServerDaemon.main(ServerDaemon.java:104)
> Caused by: java.sql.SQLSyntaxErrorException: Can't DROP
> 'fk_project_account__account_id'; check that column/key exists
>         at com.cloud.utils.db.ScriptRunner.runScript(
> ScriptRunner.java:185)
>         at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
> DatabaseUpgradeChecker.java:203)
>         ... 50 more
> 2021-01-17 01:42:47,498 DEBUG [c.c.u.d.T.Transaction] (main:null) (logid:)
> Rolling back the transaction: Time = 27 Name =  Upgrade; called by
> -TransactionLegacy.rollback:888-TransactionLegacy.removeUpTo:831-
> TransactionLegacy.close:655-DatabaseUpgradeChecker.upgrade:273-
> DatabaseUpgradeChecker.check:342-CloudStackExtendedLifeCycle.
> checkIntegrity:64-CloudStackExtendedLifeCycle.start:54-
> DefaultLifecycleProcessor.doStart:182-DefaultLifecycleProcessor.
> access$200:53-DefaultLifecycleProcessor$LifecycleGroup.start:360-
> DefaultLifecycleProcessor.startBeans:158-DefaultLifecycleProcessor.
> onRefresh:122
> ----------------------
>
> THank's
>

rohit.yadav@shapeblue.com 
www.shapeblue.com
3 London Bridge Street,  3rd floor, News Building, London  SE1 9SGUK
@shapeblue
  
 


Re: Update Problem from 4.14 to 4.15

Posted by Wei ZHOU <us...@gmail.com>.
Hi,

Is this the first time you try to upgrade cloudstack from 4.14 to 4.15?
Is there failed attempt prior to this upgrade?

-Wei


On Sunday, 17 January 2021, Info Manager <in...@activecloud.co.il> wrote:

> Hi all
>
> Have anyone such problems while updating?
>
> ----------------------
>
>  2021-01-17 01:42:47,466 DEBUG [c.c.u.d.ScriptRunner] (main:null) (logid:)
> ALTER TABLE `cloud`.`project_account`  ADD COLUMN `user_id` bigint unsigned
> COMMENT 'ID of user to be added to the project' AFTER `account_id`,  ADD
> CONSTRAINT `fk_project_account__user_id` FOREIGN KEY
> `fk_project_account__user_id`(`user_id`) REFERENCES `user`(`id`) ON DELETE
> CASCADE,  ADD COLUMN `project_role_id` bigint unsigned COMMENT 'Project
> role id' AFTER `project_account_id`,  ADD CONSTRAINT
> `fk_project_account__project_role_id` FOREIGN KEY (`project_role_id`)
> REFERENCES `project_role` (`id`) ON DELETE SET NULL,  DROP FOREIGN KEY
> `fk_project_account__account_id`,  DROP INDEX `account_id`
> 2021-01-17 01:42:47,480 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:)
> Error executing: ALTER TABLE `cloud`.`project_account`  ADD COLUMN
> `user_id` bigint unsigned COMMENT 'ID of user to be added to the project'
> AFTER `account_id`,  ADD CONSTRAINT `fk_project_account__user_id` FOREIGN
> KEY `fk_project_account__user_id`(`user_id`) REFERENCES `user`(`id`) ON
> DELETE CASCADE,  ADD COLUMN `project_role_id` bigint unsigned COMMENT
> 'Project role id' AFTER `project_account_id`,  ADD CONSTRAINT
> `fk_project_account__project_role_id` FOREIGN KEY (`project_role_id`)
> REFERENCES `project_role` (`id`) ON DELETE SET NULL,  DROP FOREIGN KEY
> `fk_project_account__account_id`,  DROP INDEX `account_id`
> 2021-01-17 01:42:47,480 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:)
> java.sql.SQLSyntaxErrorException: Can't DROP 'fk_project_account__account_
> id';
> check that column/key exists
> 2021-01-17 01:42:47,483 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null)
> (logid:) Unable to execute upgrade script
> java.sql.SQLSyntaxErrorException: Can't DROP 'fk_project_account__account_
> id';
> check that column/key exists
>         at com.cloud.utils.db.ScriptRunner.runScript(
> ScriptRunner.java:185)
>         at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
> DatabaseUpgradeChecker.java:203)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(
> DatabaseUpgradeChecker.java:258)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.check(
> DatabaseUpgradeChecker.java:342)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.
> java:64)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> doStart(DefaultLifecycleProcessor.java:182)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> access$200(DefaultLifecycleProcessor.java:53)
>         at org.springframework.context.support.DefaultLifecycleProcessor$
> LifecycleGroup.start(DefaultLifecycleProcessor.java:360)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> startBeans(DefaultLifecycleProcessor.java:158)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> onRefresh(DefaultLifecycleProcessor.java:122)
>         at org.springframework.context.support.AbstractApplicationContext.
> finishRefresh(AbstractApplicationContext.java:894)
>         at org.springframework.context.support.AbstractApplicationContext.
> refresh(AbstractApplicationContext.java:553)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.
> java:144)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.
> java:116)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
>         at org.apache.cloudstack.spring.module.factory.
> ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.init(CloudStackSpringContext.java:70)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:57)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:61)
>         at org.apache.cloudstack.spring.module.web.
> CloudStackContextLoaderListener.contextInitialized(
> CloudStackContextLoaderListener.java:51)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> callContextInitialized(ContextHandler.java:933)
>         at org.eclipse.jetty.servlet.ServletContextHandler.
> callContextInitialized(ServletContextHandler.java:553)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> startContext(ContextHandler.java:892)
>         at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
> ServletContextHandler.java:356)
>         at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
> WebAppContext.java:1445)
>         at org.eclipse.jetty.webapp.WebAppContext.startContext(
> WebAppContext.java:1409)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> doStart(ContextHandler.java:825)
>         at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
> ServletContextHandler.java:275)
>         at org.eclipse.jetty.webapp.WebAppContext.doStart(
> WebAppContext.java:524)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.handler.gzip.GzipHandler.
> doStart(GzipHandler.java:425)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:117)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.server.Server.start(Server.java:407)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.Server.doStart(Server.java:371)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.apache.cloudstack.ServerDaemon.start(ServerDaemon.java:188)
>         at org.apache.cloudstack.ServerDaemon.main(ServerDaemon.java:104)
> 2021-01-17 01:42:47,485 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null)
> (logid:) Unable to upgrade the database
> com.cloud.utils.exception.CloudRuntimeException: Unable to execute upgrade
> script
>         at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
> DatabaseUpgradeChecker.java:209)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(
> DatabaseUpgradeChecker.java:258)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.check(
> DatabaseUpgradeChecker.java:342)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.
> java:64)
>         at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> doStart(DefaultLifecycleProcessor.java:182)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> access$200(DefaultLifecycleProcessor.java:53)
>         at org.springframework.context.support.DefaultLifecycleProcessor$
> LifecycleGroup.start(DefaultLifecycleProcessor.java:360)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> startBeans(DefaultLifecycleProcessor.java:158)
>         at org.springframework.context.support.DefaultLifecycleProcessor.
> onRefresh(DefaultLifecycleProcessor.java:122)
>         at org.springframework.context.support.AbstractApplicationContext.
> finishRefresh(AbstractApplicationContext.java:894)
>         at org.springframework.context.support.AbstractApplicationContext.
> refresh(AbstractApplicationContext.java:553)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.
> java:144)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.
> java:116)
>         at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
>         at org.apache.cloudstack.spring.module.factory.
> ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.init(CloudStackSpringContext.java:70)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:57)
>         at org.apache.cloudstack.spring.module.factory.
> CloudStackSpringContext.<init>(CloudStackSpringContext.java:61)
>         at org.apache.cloudstack.spring.module.web.
> CloudStackContextLoaderListener.contextInitialized(
> CloudStackContextLoaderListener.java:51)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> callContextInitialized(ContextHandler.java:933)
>         at org.eclipse.jetty.servlet.ServletContextHandler.
> callContextInitialized(ServletContextHandler.java:553)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> startContext(ContextHandler.java:892)
>         at org.eclipse.jetty.servlet.ServletContextHandler.startContext(
> ServletContextHandler.java:356)
>         at org.eclipse.jetty.webapp.WebAppContext.startWebapp(
> WebAppContext.java:1445)
>         at org.eclipse.jetty.webapp.WebAppContext.startContext(
> WebAppContext.java:1409)
>         at org.eclipse.jetty.server.handler.ContextHandler.
> doStart(ContextHandler.java:825)
>         at org.eclipse.jetty.servlet.ServletContextHandler.doStart(
> ServletContextHandler.java:275)
>         at org.eclipse.jetty.webapp.WebAppContext.doStart(
> WebAppContext.java:524)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.handler.gzip.GzipHandler.
> doStart(GzipHandler.java:425)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:117)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> start(ContainerLifeCycle.java:169)
>         at org.eclipse.jetty.server.Server.start(Server.java:407)
>         at org.eclipse.jetty.util.component.ContainerLifeCycle.
> doStart(ContainerLifeCycle.java:110)
>         at org.eclipse.jetty.server.handler.AbstractHandler.
> doStart(AbstractHandler.java:97)
>         at org.eclipse.jetty.server.Server.doStart(Server.java:371)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.
> start(AbstractLifeCycle.java:72)
>         at org.apache.cloudstack.ServerDaemon.start(ServerDaemon.java:188)
>         at org.apache.cloudstack.ServerDaemon.main(ServerDaemon.java:104)
> Caused by: java.sql.SQLSyntaxErrorException: Can't DROP
> 'fk_project_account__account_id'; check that column/key exists
>         at com.cloud.utils.db.ScriptRunner.runScript(
> ScriptRunner.java:185)
>         at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
>         at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
> DatabaseUpgradeChecker.java:203)
>         ... 50 more
> 2021-01-17 01:42:47,498 DEBUG [c.c.u.d.T.Transaction] (main:null) (logid:)
> Rolling back the transaction: Time = 27 Name =  Upgrade; called by
> -TransactionLegacy.rollback:888-TransactionLegacy.removeUpTo:831-
> TransactionLegacy.close:655-DatabaseUpgradeChecker.upgrade:273-
> DatabaseUpgradeChecker.check:342-CloudStackExtendedLifeCycle.
> checkIntegrity:64-CloudStackExtendedLifeCycle.start:54-
> DefaultLifecycleProcessor.doStart:182-DefaultLifecycleProcessor.
> access$200:53-DefaultLifecycleProcessor$LifecycleGroup.start:360-
> DefaultLifecycleProcessor.startBeans:158-DefaultLifecycleProcessor.
> onRefresh:122
> ----------------------
>
> THank's
>