[ https://issues.apache.org/jira/browse/RANGER-3692?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Pradeep Agrawal resolved RANGER-3692. ------------------------------------- Fix Version/s: 3.0.0 2.3.0 Resolution: Fixed commit link master branch : [https://github.com/apache/ranger/commit/a93571daedaa45ffc98869410148cf1c55a90eaf] 2.3 branch : https://github.com/apache/ranger/commit/d9d080dea207319147190f2a8875effca95d4d73 > Ranger cannot connect to the DB when the DB is outaged for a long time > ---------------------------------------------------------------------- > > Key: RANGER-3692 > URL: https://issues.apache.org/jira/browse/RANGER-3692 > Project: Ranger > Issue Type: Bug > Components: admin > Affects Versions: 2.1.0 > Reporter: Zilong Zhu > Assignee: Zilong Zhu > Priority: Major > Fix For: 3.0.0, 2.3.0 > > Attachments: > 0001-RANGER-3692-Ranger-cannot-connect-to-the-DB-when-the.patch, > 0002-RANGER-3692-Ranger-cannot-connect-to-the-DB-when-the.patch > > > We had a database problem where the database was offline for more than a > week. However ranger connot connect to the DB. > {code:java} > Internal Exception: java.sql.SQLException: Connections could not be acquired > from the underlying database! > [C3P0PooledConnectionPoolManager[identityToken->1hgf80qaljdycrokead8h|73c6299]-HelperThread-#0] > WARN com.mchange.v2.log.slf4j.Slf4jMLog$Slf4jMLogger$WarnLogger > (Slf4jMLog.java:223) - > com.mchange.v2.resourcepool.BasicResourcePool$ScatteredAcquireTask@7179549 -- > Acquisition Attempt Failed!!! Clearing pending acquires. While trying to > acquire a needed new resource, we failed to succeed more than the maximum > number of allowed acquisition attempts (30). Last acquisition attempt > exception: > com.mysql.cj.jdbc.exceptions.CommunicationsException: Communications link > failure > [C3P0PooledConnectionPoolManager[identityToken->1hgf80qaljdycrokead8h|73c6299]-HelperThread-#0] > WARN com.mchange.v2.log.slf4j.Slf4jMLog$Slf4jMLogger$WarnLogger > (Slf4jMLog.java:220) - Having failed to acquire a resource, > com.mchange.v2.resourcepool.BasicResourcePool@5efb2b9 is interrupting all > Threads waiting on a resource to check out. Will try again in response to new > client requests. {code} > {code:java} > Internal Exception: java.sql.SQLException: An SQLException was provoked by > the following failure: com.mchange.v2.resourcepool.ResourcePoolException: A > ResourcePool cannot acquire a new resource -- the factory or source appears > to be down. > {code} > I found out that this is a bug in c3p0 0.9.5.3. This bug was resolved in > 0.9.5.4. So I suggest to upgrade the version of c3p0 to 0.9.5.4. > [Force kill acquires by rscadrde · Pull Request #91 · swaldman/c3p0 · > GitHub|https://github.com/swaldman/c3p0/pull/91] -- This message was sent by Atlassian Jira (v8.20.1#820001)