cloudera-scm-server啟動時出現Caused by: javax.persistence.PersistenceException: org.hibernate.exception.GenericJDBCException: Could n
問題現象
檢視
[[email protected] cloudera-scm-server]# pwd /var/log/cloudera-scm-server [[email protected] cloudera-scm-server]# cat cloudera-scm-server.log
是如下的問題:
Caused by: javax.persistence.PersistenceException: org.hibernate.exception.GenericJDBCException: Could not open connection at org.hibernate.ejb.AbstractEntityManagerImpl.convert(AbstractEntityManagerImpl.java:1387) at org.hibernate.ejb.AbstractEntityManagerImpl.convert(AbstractEntityManagerImpl.java:1310) at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:1397) at org.hibernate.ejb.TransactionImpl.begin(TransactionImpl.java:62) at com.cloudera.enterprise.AbstractWrappedEntityManager.beginForRollbackAndReadonly(AbstractWrappedEntityManager.java:89) at com.cloudera.enterprise.dbutil.DbUtil.isInnoDbEnabled(DbUtil.java:549) at com.cloudera.server.cmf.bootstrap.EntityManagerFactoryBean.checkMysqlTableEngineType(EntityManagerFactoryBean.java:139) at com.cloudera.server.cmf.bootstrap.EntityManagerFactoryBean.getObject(EntityManagerFactoryBean.java:122) at com.cloudera.server.cmf.bootstrap.EntityManagerFactoryBean.getObject(EntityManagerFactoryBean.java:65) at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.doGetObjectFromFactoryBean(FactoryBeanRegistrySupport.java:142) ... 22 more Caused by: org.hibernate.exception.GenericJDBCException: Could not open connection at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:54) at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:125) at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:110) at org.hibernate.engine.jdbc.internal.LogicalConnectionImpl.obtainConnection(LogicalConnectionImpl.java:221) at org.hibernate.engine.jdbc.internal.LogicalConnectionImpl.getConnection(LogicalConnectionImpl.java:157) at org.hibernate.engine.transaction.internal.jdbc.JdbcTransaction.doBegin(JdbcTransaction.java:67) at org.hibernate.engine.transaction.spi.AbstractTransactionImpl.begin(AbstractTransactionImpl.java:160) at org.hibernate.internal.SessionImpl.beginTransaction(SessionImpl.java:1426) at org.hibernate.ejb.TransactionImpl.begin(TransactionImpl.java:59) ... 28 more Caused by: java.sql.SQLException: Connections could not be acquired from the underlying database! at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:106) at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:529) at com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource.getConnection(AbstractPoolBackedDataSource.java:128) at org.hibernate.service.jdbc.connections.internal.C3P0ConnectionProvider.getConnection(C3P0ConnectionProvider.java:84) at org.hibernate.internal.AbstractSessionImpl$NonContextualJdbcConnectionAccess.obtainConnection(AbstractSessionImpl.java:292) at org.hibernate.engine.jdbc.internal.LogicalConnectionImpl.obtainConnection(LogicalConnectionImpl.java:214) ... 33 more Caused by: com.mchange.v2.resourcepool.CannotAcquireResourceException: A ResourcePool could not acquire a resource from its primary factory or source. at com.mchange.v2.resourcepool.BasicResourcePool.awaitAvailable(BasicResourcePool.java:1319) at com.mchange.v2.resourcepool.BasicResourcePool.prelimCheckoutResource(BasicResourcePool.java:557) at com.mchange.v2.resourcepool.BasicResourcePool.checkoutResource(BasicResourcePool.java:477) at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:525) ... 37 more 2017-12-02 19:59:55,633 INFO main:com.cloudera.server.cmf.Main: Starting SCM Server. JVM Args: [-Dlog4j.configuration=file:/etc/cloudera-scm-server/log4j.properties, -Dfile.encoding=UTF-8, -Dcmf.root.logger=INFO,LOGFILE, -Dcmf.log.dir=/var/log/cloudera-scm-server, -Dcmf.log.file=cloudera-scm-server.log, -Dcmf.jetty.threshhold=WARN, -Dcmf.schema.dir=/usr/share/cmf/schema, -Djava.awt.headless=true, -Djava.net.preferI
[[email protected] lib]# netstat -nltp Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN 1262/rpcbind tcp 0 0 0.0.0.0:4433 0.0.0.0:* LISTEN 1976/python2.6 tcp 0 0 0.0.0.0:52338 0.0.0.0:* LISTEN 1390/rpc.statd tcp 0 0 127.0.0.1:7190 0.0.0.0:* LISTEN 1976/python2.6 tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 1579/sshd tcp 0 0 0.0.0.0:7191 0.0.0.0:* LISTEN 1976/python2.6 tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN 1417/cupsd tcp 0 0 127.0.0.1:19001 0.0.0.0:* LISTEN 1894/python tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 1683/master tcp 0 0 127.0.0.1:6010 0.0.0.0:* LISTEN 2263/sshd tcp 0 0 127.0.0.1:6011 0.0.0.0:* LISTEN 2689/sshd tcp 0 0 192.168.80.31:9000 0.0.0.0:* LISTEN 1739/python2.6 tcp 0 0 0.0.0.0:3306 0.0.0.0:* LISTEN 3183/mysqld tcp 0 0 :::111 :::* LISTEN 1262/rpcbind tcp 0 0 :::4434 :::* LISTEN 1976/python2.6 tcp 0 0 :::22 :::* LISTEN 1579/sshd tcp 0 0 :::7191 :::* LISTEN 1976/python2.6 tcp 0 0 ::1:631 :::* LISTEN 1417/cupsd tcp 0 0 ::1:25 :::* LISTEN 1683/master tcp 0 0 :::59833 :::* LISTEN 1390/rpc.statd tcp 0 0 ::1:6010 :::* LISTEN 2263/sshd tcp 0 0 ::1:6011 :::* LISTEN 2689/sshd
解決辦法
[[email protected] lib]# service mysqld start
Starting mysqld: [ OK ]
[[email protected] lib]#
[[email protected] lib]# netstat -nltp Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 0.0.0.0:7180 0.0.0.0:* LISTEN 3309/java tcp 0 0 0.0.0.0:7182 0.0.0.0:* LISTEN 3309/java tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN 1262/rpcbind tcp 0 0 0.0.0.0:4433 0.0.0.0:* LISTEN 1976/python2.6 tcp 0 0 0.0.0.0:52338 0.0.0.0:* LISTEN 1390/rpc.statd tcp 0 0 127.0.0.1:7190 0.0.0.0:* LISTEN 1976/python2.6 tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 1579/sshd tcp 0 0 0.0.0.0:7191 0.0.0.0:* LISTEN 1976/python2.6 tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN 1417/cupsd tcp 0 0 127.0.0.1:19001 0.0.0.0:* LISTEN 1894/python tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 1683/master tcp 0 0 127.0.0.1:6010 0.0.0.0:* LISTEN 2263/sshd tcp 0 0 127.0.0.1:6011 0.0.0.0:* LISTEN 2689/sshd tcp 0 0 192.168.80.31:9000 0.0.0.0:* LISTEN 1739/python2.6 tcp 0 0 0.0.0.0:3306 0.0.0.0:* LISTEN 3183/mysqld tcp 0 0 :::111 :::* LISTEN 1262/rpcbind tcp 0 0 :::4434 :::* LISTEN 1976/python2.6 tcp 0 0 :::22 :::* LISTEN 1579/sshd tcp 0 0 :::7191 :::* LISTEN 1976/python2.6 tcp 0 0 ::1:631 :::* LISTEN 1417/cupsd tcp 0 0 ::1:25 :::* LISTEN 1683/master tcp 0 0 :::59833 :::* LISTEN 1390/rpc.statd tcp 0 0 ::1:6010 :::* LISTEN 2263/sshd tcp 0 0 ::1:6011 :::* LISTEN 2689/sshd [[email protected] lib]#
其實,這個問題很簡單,是mysql方面的問題,要麼是mysql服務沒啟動,要麼就是你的驅動jar包沒安裝好。
[[email protected] lib]# pwd /usr/share/cmf/lib [[email protected] lib]#
建議
要將mysqld設定為開機自動啟動:
chkconfig mysqld on 可能還會出現情況,就是JDBC driver cannot be found,這時把jar包復現到 /usr/share/cmf/lib 下就行了。
重啟cloudera-scm-server服務。
等待1分鐘,訪問7180埠,應該就不會出問題了。
相關推薦
cloudera-scm-server啟動時出現Caused by: javax.persistence.PersistenceException: org.hibernate.exception.GenericJDBCException: Could n
問題現象 檢視 [[email protected] cloudera-scm-server]# pwd /var/log/cloudera-scm-server [[email protected] cloudera-scm-server]#
IDEA裡執行程式碼時出現Caused by: java.lang.ClassNotFoundException: org.apache.log4j.Logger的解決辦法(圖文詳解)
不多說,直接上乾貨! 問題詳情 執行出現log4j的問題 "C:\Program Files\Java\jdk1.8.0_66\bin\java" -Didea.launcher.port=7533 "-Didea.launcher.bin.path=D:\Soft
解決Caused by: javax.persistence.PersistenceException: [PersistenceUnit: default] Unable to build Hibe
Caused by: javax.persistence.PersistenceException: [PersistenceUnit: default] Unable to build Hibernate SessionFactory 日誌提示@Column(name)的註解
Oozie時出現Caused by: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure?
不多說,直接上乾貨! 問題詳情 [[email protected] oozie-4.1.0-cdh5.5.4]$ bin/ooziedb.sh create -sqlfile oozie.sql -run DB Connection [[email
Caused by: java.lang.NoClassDefFoundError: org/hibernate/validator/internal/engine/DefaultParameterN
Caused by: java.lang.NoClassDefFoundError: org/hibernate/validator/internal/engine/DefaultParameterNameProvider at org.hibernate.validator.inter
Caused by: javax.persistence.TransactionRequiredException: Executing an update/delete query
org.springframework.dao.InvalidDataAccessApiUsageException: Executing an update/delete query; nested exception is javax.persistence.TransactionRequiredEx
Caused by: org.hibernate.exception.SQLGrammarException: could not extract ResultSet 報錯原因
jpa執行分頁操作時,可能報錯Caused by: org.hibernate.exception.SQLGrammarException: could not extract ResultSet 原
Caused by: java.lang.ClassNotFoundException: org.hibernate.cache.CacheProvider
出現這個問題主要是hibernate4裡不在有cacheprovider類,cacheprovider在hibernate3中才有,用hibernate4就應該用hibernate4的SessionFactory。具體的sessionfactory配置:<bean i
啟動cloudera-scm-server時,報Unable to retrieve non-local address
Unable to retrieve non-local address “ScmActive-0:com.cloudera.server.cmf.components.ScmActive: ScmActive: Unable to retrieve non-local non-loopback
ambari-server啟動出現Caused by: java.lang.RuntimeException:java.lang.ClassNotFoundEception:com.mysql.jdbc.Driver問題解決辦法(圖文詳解)
不多說,直接上乾貨! 問題詳解 啟動ambari-server出現 Caused by: java.lang.RuntimeException:java.lang.ClassNotFoundEception:com.mysql.jdbc.Driver
Clouder Manager安裝時出現please remove the following file: /etc/cloudera-scm-server/db.properties問題解決(圖文詳解)
歡迎您的加入! 微信公眾號平臺: 大資料躺過的坑 微信公眾號平臺: 人工智慧躺過的坑 大資料和人工智慧躺過的坑(總群): 161156071 更多QQ技術分群,詳情請見:http://www.cnblogs.com/zls
CDH啟動出現cloudera-scm-server一直掛掉
公司伺服器停電 ,在啟動CDH服務過程中cloudera-scm-server啟動一會就會掛掉 ,檢視日誌出現這樣的錯誤 Exception in thread "main" org.springframework.beans.factory.BeanCreationE
Hive執行過程中出現Caused by : java.lang.ClassNotFoundException: org.cloudera.htrace.Trace的錯誤解決辦法(圖文詳解)
pre wid logs In 實用 過程 ase edit 微信 不多說,直接上幹貨! 問題詳情 如下 這個錯誤的意思是缺少 htrace-core-2.04.jar。 解決辦法:
tomcat部署新的項目啟動時出現報錯信息: Invalid byte tag in constant pool: 15
tomcat 啟動報錯 invalid byte tag in constant pool ......org.apache.tomcat.util.bcel.classfile.ClassFormatException: Invalid byte tag in constant pool: 15
[轉]Android Studio啟動時出現unable to access android sdk add-on list
上大 ras server tails dea tar ext ida 錯誤信息 轉載請標明出處:http://blog.csdn.net/xx326664162/article/details/50563122 文章出自:薛瑄的博客 你也可以查看我的其他同類文章,也會讓你
如何去掉myeclipse的web項目啟動時出現的 CodeLive Panel
如何 str 瀏覽器 eclips web項目 安裝 項目 clip 不顯示 問題描述: 最近安裝了Myeclipse 2017 CI ,寫了一個web項目,在瀏覽器打開網頁時右上角出現了 CodeLive面板,有時顯示會遮擋頁面效果,看著也礙眼,去掉它,將CodeL
Caused by: java.lang.ClassNotFoundException: org.springframework.web.socket.server.standard.ServerEndpointExporter
為我 sock rmi gap context handle util red ati Exception in thread "main" java.lang.NoClassDefFoundError: org/springframework/web/socket/ser
當mysq啟動時出現錯誤1067時應如何解決
解決 如何 網上 控制面板 gedit 啟動 bsp mys 就是 在網上也看了很多教程,也查了很多方法,但是試過都沒有要用,最後經過本人親測 最好的方法,也是最簡單的方法,就是刪掉重裝。 第一 進入控制面板卸載程序,這樣是卸載不幹凈的。 第二進入註冊表windos+r
SSH整合CXF專案啟動時出現告警日誌
spring 4.1.3.RELEASE + cxf 2.5.0框架,在專案啟動時出現一大堆告警日誌,雖然不影響專案正常執行,但看著很刺眼,所以要想辦法清除掉。 告警1:Import of META-INF/cxf/cxf-extension-soap.xml has been de
tomcat啟動時出現:Failed to start component [StandardEngine[Catalina].StandardHost[localhost].錯誤 的原因:
tomcat執行專案出現:Failed to start component [StandardEngine[Catalina].StandardHost[localhost]. 並且出現cause by : java.lang.ClassFormatError: Absent Code att