cloudstack-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Simon Weller (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CLOUDSTACK-9209) Database HA not working on a fresh install on Ubuntu 12.04
Date Tue, 22 Mar 2016 16:19:25 GMT

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

Simon Weller commented on CLOUDSTACK-9209:
------------------------------------------

Please see my PR tested on Centos 7 that addresses this. I expect the Ubuntu issue is the
same, but I have no way of testing it.
https://github.com/apache/cloudstack/pull/1428
Usage server issue is address here: https://github.com/apache/cloudstack/pull/1433

> Database HA not working on a fresh install on Ubuntu 12.04
> ----------------------------------------------------------
>
>                 Key: CLOUDSTACK-9209
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-9209
>             Project: CloudStack
>          Issue Type: Bug
>      Security Level: Public(Anyone can view this level - this is the default.) 
>          Components: Install and Setup
>    Affects Versions: 4.7.0
>         Environment: Two Ubuntu 12.04 Management Servers, Mysql Master Master Replication,
Official community repository: http://cloudstack.apt-get.eu/ubuntu/dists/precise/4.7/
>            Reporter: Thomas
>            Priority: Blocker
>
> The cloudstack-management service will not come up because of this error:
> 2016-01-05 16:15:00,899 INFO  [c.c.u.d.T.Transaction] (main:null) (logid:) Is Data Base
High Availiability enabled? Ans : true
> 2016-01-05 16:15:00,924 INFO  [c.c.u.d.T.Transaction] (main:null) (logid:) The slaves
configured for Cloud Data base is/are : 192.168.0.90
> 2016-01-05 16:15:00,974 ERROR [c.c.u.d.Merovingian2] (main:null) (logid:) Unable to get
a new db connection
> java.sql.SQLException: Invalid load balancing strategy 'com.cloud.utils.db.StaticStrategy'.
>         at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:934)
>         at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:931)
>         at com.mysql.jdbc.Util.loadExtensions(Util.java:588)
>         at com.mysql.jdbc.LoadBalancingConnectionProxy.<init>(LoadBalancingConnectionProxy.java:279)
>         at com.mysql.jdbc.FailoverConnectionProxy.<init>(FailoverConnectionProxy.java:66)
>         at com.mysql.jdbc.NonRegisteringDriver.connectFailover(NonRegisteringDriver.java:382)
>         at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:301)
>         at java.sql.DriverManager.getConnection(DriverManager.java:571)
>         at java.sql.DriverManager.getConnection(DriverManager.java:215)
>         at org.apache.commons.dbcp.DriverManagerConnectionFactory.createConnection(DriverManagerConnectionFactory.java:75)
>         at org.apache.commons.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:582)
>         at org.apache.commons.pool.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:1188)
>         at org.apache.commons.dbcp.PoolingDataSource.getConnection(PoolingDataSource.java:106)
>         at com.cloud.utils.db.TransactionLegacy.getStandaloneConnectionWithException(TransactionLegacy.java:202)
>         at com.cloud.utils.db.Merovingian2.<init>(Merovingian2.java:68)
>         at com.cloud.utils.db.Merovingian2.createLockMaster(Merovingian2.java:88)
>         at com.cloud.server.LockMasterListener.<init>(LockMasterListener.java:33)
>         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
>         at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
>         at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
>         at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
>         at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:148)
>         at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:121)
>         at org.springframework.beans.factory.support.ConstructorResolver.autowireConstructor(ConstructorResolver.java:277)
>         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireConstructor(AbstractAutowireCapableBeanFactory.java:1077)
>         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:981)
>         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:487)
>         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:458)
>         at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:293)
>         at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:223)
>         at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:290)
>         at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:191)
>         at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:636)
>         at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:934)
>         at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:479)
>         at org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.java:145)
>         at org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:122)
>         at org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:245)
>         at org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:250)
>         at org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:233)
>         at org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.java:117)
>         at org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:79)
>         at org.apache.cloudstack.spring.module.factory.ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
>         at org.apache.cloudstack.spring.module.factory.CloudStackSpringContext.init(CloudStackSpringContext.java:71)
>         at org.apache.cloudstack.spring.module.factory.CloudStackSpringContext.<init>(CloudStackSpringContext.java:58)
>         at org.apache.cloudstack.spring.module.factory.CloudStackSpringContext.<init>(CloudStackSpringContext.java:62)
>         at org.apache.cloudstack.spring.module.web.CloudStackContextLoaderListener.contextInitialized(CloudStackContextLoaderListener.java:52)
>         at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4206)
>         at org.apache.catalina.core.StandardContext.start(StandardContext.java:4705)
>         at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:799)
>         at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:779)
>         at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:601)
>         at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1079)
>         at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:1002)
>         at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:506)
>         at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1317)
>         at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:324)
>         at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:142)
>         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1065)
>         at org.apache.catalina.core.StandardHost.start(StandardHost.java:840)
>         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1057)
>         at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:463)
>         at org.apache.catalina.core.StandardService.start(StandardService.java:525)
>         at org.apache.catalina.core.StandardServer.start(StandardServer.java:754)
>         at org.apache.catalina.startup.Catalina.start(Catalina.java:595)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>         at java.lang.reflect.Method.invoke(Method.java:606)
>         at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:289)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>         at java.lang.reflect.Method.invoke(Method.java:606)
>         at org.apache.commons.daemon.support.DaemonLoader.start(DaemonLoader.java:243)
> Caused by: java.lang.NoClassDefFoundError: org/apache/log4j/Logger
>         at com.cloud.utils.db.StaticStrategy.<clinit>(StaticStrategy.java:35)
>         at java.lang.Class.forName0(Native Method)
>         at java.lang.Class.forName(Class.java:195)
>         ... 73 more
> Caused by: java.lang.ClassNotFoundException: org.apache.log4j.Logger
>         at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
>         at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
>         at java.security.AccessController.doPrivileged(Native Method)
>         ... 79 more
> --
> I already hit this error in some earlier releases of Cloudstack and used always this
workaround:
> --
> /usr/share/cloudstack-management/webapps/client/WEB-INF/lib/cloud-plugin-database-mysqlha-4.3.0.jar
> ..onto the end of a line in..
> /etc/cloudstack/management/catalina.properties
> ..that started as...
> common.loader=${catalina.base}/lib,${catalina.base}/lib...
> .. and after a restart of the management server it worked!
> --
> But unfortunately the jar file is missing this time so it tried to be smart and extracted
it from the mysqlha RPM package and copied it to the ubuntu server. 
> Also no luck, the failure remains.
> For Ubuntu there is also no extra .deb package available for the mysqlha plugin.
> We can`t proceed now because of this bug with our project.
> A fast fix would be welcome.
> Thanks in advance.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message