본문 바로가기
반응형

JDBC 관련 Error 몇가지

1) 문제 발생 형태
    i. JDBC 구성 실수
    ii. Connection Pool 부족
    iii. Database resource issues
    iv. Connection Leak
    v. 방화벽 문제
    vi. Slow Server Startup
    vii. Wait for IO response

 

2) 로그 형태
     i. <YYYY.MM.DD TIME > [<Warning>|<Error> <JDBC> 형태의 로그 발생]
     ii. Connection 자원 부족 로그 현상

<YYYY.MM.DD TIME> <Info> <Common> <BEA-00627> <Reached maximum capacity of pool "JDBC1", making "0" new resource instances instead of "1".>

 

3) 문제 분석 및 확인 방법
     i. 로그 특이 사항 여부 먼저 확인
     ii. AdminConsole을 이용한 각 DataSource 의 자원 사용 상태 모니터링

 

JDBC Connection Not Closed 현상

 

1) 문제 발생 형태
     i. Application 이 Connection 을 사용 후 Connection Pool 에 connection 을 반환하지 않아 Leak을 발생시키는 경우

 

2) 로그 확인
     i. Active Connection current Count 값이 점점 증가하여 Max Capacity 에 도달하면서 아래와 같은 로그가 빈번이 발생

<YYYY.MM.DD TIME><Info> <Common> <BEA-00627> <Reached maximum capacity of pool "JDBC1", making "0" new resource instances instead of "1".>

 

3) 문제 분석 방법
     i. ThreadDump 및 DataSource 모니터링을 통해 Leak 여부 현상 확인
     ii. AdminConsole > 일반 > ConnectionPool > Advanced > Inactive Connection Time Out 파라미터에 600초(기본) 설정       후 로그 확인


• Inactinve Connection Time Out 설정 후 강제 반환 시 로그 발생 형태

<2012. 2. 5 오후 5시 56분 16초 KST> <Warning> <JDBC> <BEA-01153> <Forcibly releasing inactive connection "weblogic.jdbc.wrapper.PoolConnection_oracle_jdbc_driver_T4CConnection@9" back into the connection pool "DS2", currently reserved by: java.lang.Exception
at weblogic.jdbc.common.internal.ConnectionEnv.setup(ConnectionEnv.java:325)
at weblogic.common.resourcepool.ResourcePoolImpl.reserveResource(ResourcePoolImpl.java:363)
at weblogic.common.resourcepool.ResourcePoolImpl.reserveResource(ResourcePoolImpl.java:329)
at weblogic.jdbc.common.internal.ConnectionPool.reserve(ConnectionPool.java:417)
at weblogic.jdbc.common.internal.ConnectionPool.reserve(ConnectionPool.java:324)
at weblogic.jdbc.common.internal.MultiPool.searchHighAvail(MultiPool.java:408)
at weblogic.jdbc.common.internal.MultiPool.findPool(MultiPool.java:178)
at weblogic.jdbc.common.internal.ConnectionPoolManager.reserve(ConnectionPoolManager.java:89)
at weblogic.jdbc.common.internal.ConnectionPoolManager.reserve(ConnectionPoolManager.java:115)
at weblogic.jdbc.pool.Driver.connect(Driver.java:150)
at weblogic.jdbc.jts.Driver.getNonTxConnection(Driver.java:651)
at weblogic.jdbc.jts.Driver.connect(Driver.java:127)
at weblogic.jdbc.common.internal.RmiDataSource.getConnection(RmiDataSource.java:364)
at jsp_servlet.__testjsp._jspService(__testjsp.java:113)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:34)
at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:183)
728x90
반응형

한걸음 한걸음

개인적인 기록