Whats the output of these two commands? # rpm -qa mysql-connector-java
# ls -la ls /usr/share/java/mysql-connector-java.jar > On May 25, 2016, at 2:23 PM, Anandha L Ranganathan <analog.s...@gmail.com> > wrote: > > I am trying to upgrade ambari-server with 2.2.1.1 version from 2.1.0 > > 1) First upgraded ambari-server with "yum upgrade ambari-server" > > Here is the message received. > Updated: > ambari-server.x86_64 0:2.2.1.1-70 > > Complete! > > 2) Upgrade ambari-database with "ambari-server upgrade" > > This is the response I received. > > [root@usw2stdpmn02 yum.repos.d]# ambari-server upgrade > Using python /usr/bin/python > Upgrading ambari-server > Updating properties in ambari.properties ... > WARNING: Can not find ambari-env.sh.rpmsave file from previous version, > skipping restore of environment settings > Fixing database objects owner > Ambari Server configured for MySQL. Confirm you have made a backup of the > Ambari Server database [y/n] (y)? y > Upgrading database schema > Error output from schema upgrade command: > Exception in thread "main" java.lang.Exception: Unexpected error, upgrade > failed > at > org.apache.ambari.server.upgrade.SchemaUpgradeHelper.main(SchemaUpgradeHelper.java:319) > Caused by: com.google.inject.CreationException: Guice creation errors: > > 1) Error injecting constructor, java.lang.RuntimeException: > java.lang.ClassNotFoundException: com.mysql.jdbc.Driver > at > org.apache.ambari.server.orm.DBAccessorImpl.<init>(DBAccessorImpl.java:77) > while locating org.apache.ambari.server.orm.DBAccessorImpl > while locating org.apache.ambari.server.orm.DBAccessor > for field at > org.apache.ambari.server.orm.dao.DaoUtils.dbAccessor(DaoUtils.java:36) > at org.apache.ambari.server.orm.dao.DaoUtils.class(DaoUtils.java:36) > while locating org.apache.ambari.server.orm.dao.DaoUtils > for field at > org.apache.ambari.server.orm.dao.HostComponentStateDAO.daoUtils(HostComponentStateDAO.java:39) > at > org.apache.ambari.server.orm.dao.HostComponentStateDAO.class(HostComponentStateDAO.java:39) > while locating org.apache.ambari.server.orm.dao.HostComponentStateDAO > for field at > org.apache.ambari.server.orm.models.HostComponentSummary.hostComponentStateDao(HostComponentSummary.java:52) > Caused by: java.lang.RuntimeException: java.lang.ClassNotFoundException: > com.mysql.jdbc.Driver > at > org.apache.ambari.server.orm.DBAccessorImpl.<init>(DBAccessorImpl.java:103) > at > org.apache.ambari.server.orm.DBAccessorImpl$$FastClassByGuice$$86dbc63e.newInstance(<generated>) > at > com.google.inject.internal.cglib.reflect.$FastConstructor.newInstance(FastConstructor.java:40) > at > com.google.inject.internal.DefaultConstructionProxyFactory$1.newInstance(DefaultConstructionProxyFactory.java:60) > at > com.google.inject.internal.ConstructorInjector.construct(ConstructorInjector.java:85) > at > com.google.inject.internal.ConstructorBindingImpl$Factory.get(ConstructorBindingImpl.java:254) > at com.google.inject.internal.FactoryProxy.get(FactoryProxy.java:54) > at > com.google.inject.internal.SingleFieldInjector.inject(SingleFieldInjector.java:53) > at > com.google.inject.internal.MembersInjectorImpl.injectMembers(MembersInjectorImpl.java:110) > at > com.google.inject.internal.ConstructorInjector.construct(ConstructorInjector.java:94) > at > com.google.inject.internal.ConstructorBindingImpl$Factory.get(ConstructorBindingImpl.java:254) > at > com.google.inject.internal.ProviderToInternalFactoryAdapter$1.call(ProviderToInternalFactoryAdapter.java:46) > at > com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1031) > at > com.google.inject.internal.ProviderToInternalFactoryAdapter.get(ProviderToInternalFactoryAdapter.java:40) > at com.google.inject.Scopes$1$1.get(Scopes.java:65) > at > com.google.inject.internal.InternalFactoryToProviderAdapter.get(InternalFactoryToProviderAdapter.java:40) > at > com.google.inject.internal.SingleFieldInjector.inject(SingleFieldInjector.java:53) > at > com.google.inject.internal.MembersInjectorImpl.injectMembers(MembersInjectorImpl.java:110) > at > com.google.inject.internal.ConstructorInjector.construct(ConstructorInjector.java:94) > at > com.google.inject.internal.ConstructorBindingImpl$Factory.get(ConstructorBindingImpl.java:254) > at > com.google.inject.internal.ProviderToInternalFactoryAdapter$1.call(ProviderToInternalFactoryAdapter.java:46) > at > com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1031) > at > com.google.inject.internal.ProviderToInternalFactoryAdapter.get(ProviderToInternalFactoryAdapter.java:40) > at com.google.inject.Scopes$1$1.get(Scopes.java:65) > at > com.google.inject.internal.InternalFactoryToProviderAdapter.get(InternalFactoryToProviderAdapter.java:40) > at > com.google.inject.internal.SingleFieldInjector.inject(SingleFieldInjector.java:53) > at > com.google.inject.internal.InjectionRequestProcessor$StaticInjection$1.call(InjectionRequestProcessor.java:116) > at > com.google.inject.internal.InjectionRequestProcessor$StaticInjection$1.call(InjectionRequestProcessor.java:110) > at > com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1024) > at > com.google.inject.internal.InjectionRequestProcessor$StaticInjection.injectMembers(InjectionRequestProcessor.java:110) > at > com.google.inject.internal.InjectionRequestProcessor.injectMembers(InjectionRequestProcessor.java:78) > at > com.google.inject.internal.InternalInjectorCreator.injectDynamically(InternalInjectorCreator.java:170) > at > com.google.inject.internal.InternalInjectorCreator.build(InternalInjectorCreator.java:109) > at com.google.inject.Guice.createInjector(Guice.java:95) > at com.google.inject.Guice.createInjector(Guice.java:72) > at com.google.inject.Guice.createInjector(Guice.java:62) > at > org.apache.ambari.server.upgrade.SchemaUpgradeHelper.main(SchemaUpgradeHelper.java:280) > > > > I verified that my mysql jdbc drives exists in the following path. > > > [root@usw2stdpmn02 resources]# ls -lrt > /var/lib/ambari-server/resources/mysql-connector-java-5.1.36-bin.jar > -rw-r--r--. 1 root root 972009 Sep 3 2015 > /var/lib/ambari-server/resources/mysql-connector-java-5.1.36-bin.jar > > > > What is the workaround and how would I fix this problem ? > > >