Background Image

FORUM

조회 수 27661 추천 수 0 댓글 2
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄




로그파일에 아래와 같이 찍히네요...

도대체 뭐가 문제일까요?



------------------------------------------------------------------------------------------------------------
2011.11.18 00:58:07.822 ERROR jeemin.home.bean.IndexBean.init:26 DB접속 실패
org.apache.commons.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory (Cannot communicate with the broker)
at org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:855)
at org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDataSource.java:540)
at jeemin.home.bean.IndexBean.init(IndexBean.java:16)
at org.apache.jsp.index_jsp._jspService(index_jsp.java:52)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:328)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:315)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:210)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:172)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:200)
at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:291)
at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:775)
at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:704)
at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:897)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:685)
at java.lang.Thread.run(Thread.java:636)
Caused by: cubrid.jdbc.driver.CUBRIDException: Cannot communicate with the broker
at cubrid.jdbc.jci.UConnection.<init>(UConnection.java:202)
at cubrid.jdbc.jci.UJCIManager.connect(UJCIManager.java:73)
at cubrid.jdbc.driver.CUBRIDDriver.connect(CUBRIDDriver.java:302)
at org.apache.commons.dbcp.DriverConnectionFactory.createConnection(DriverConnectionFactory.java:37)
at org.apache.commons.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:290)
at org.apache.commons.dbcp.BasicDataSource.validateConnectionFactory(BasicDataSource.java:877)
at org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:851)
... 24 more
------------------------------------------------------------------------------------------------------------
<Server port="8005" shutdown="SHUTDOWN">
  <Listener className="org.apache.catalina.core.AprLifecycleListener" />
  <Listener className="org.apache.catalina.mbeans.ServerLifecycleListener" />
  <Listener className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener" />
  <Listener className="org.apache.catalina.storeconfig.StoreConfigLifecycleListener"/>
  <GlobalNamingResources>
    <Environment name="simpleValue" type="java.lang.Integer" value="30"/>
    <Resource name="UserDatabase" auth="Container"
              type="org.apache.catalina.UserDatabase"
       description="User database that can be updated and saved"
           factory="org.apache.catalina.users.MemoryUserDatabaseFactory"
          pathname="conf/tomcat-users.xml" />
    <Resource name="jdbc/cubrid"
              auth="Container"
              type="javax.sql.DataSource"
              factory="org.apache.commons.dbcp.BasicDataSourceFactory"
              driverClassName="cubrid.jdbc.driver.CUBRIDDriver"
              url="jdbc:cubrid:localhost:33000:jeemin:::"
              username="jeemin"
              password="1234"
              initialSize="10"
              maxActive="20"
              maxIdle="10"
              maxWait="-1"
              poolPreparedStatements="true"
    />

  </GlobalNamingResources>

  <Service name="Catalina">

    <Connector port="8080" maxHttpHeaderSize="8192"
               maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
               enableLookups="false" redirectPort="8443" acceptCount="100"
               connectionTimeout="20000" disableUploadTimeout="true" />

    <Connector port="8009" 
               enableLookups="false" redirectPort="8443" protocol="AJP/1.3" />

    <Engine name="Catalina" defaultHost="localhost">
      <Realm className="org.apache.catalina.realm.UserDatabaseRealm"
             resourceName="UserDatabase"/>
      <Host name="localhost">
   <Context path="" docBase="/var/html/www" reloadable="true">
 <ResourceLink global="jdbc/cubrid" name="jdbc/cubrid" type="javax.sql.DataSource" />
   </Context>
      </Host>
    </Engine>
  </Service>
</Server>
------------------------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" id="WebApp_ID" version="2.5">
    <resource-ref>
        <res-ref-name>jdbc/cubrid</res-ref-name>
        <res-type>javax.sql.DataSource</res-type>
        <res-auth>Container</res-auth>
    </resource-ref>
</web-app>
------------------------------------------------------------------------------------------------------------
package jeemin.home.bean;

import java.sql.*;

import javax.sql.*;
import javax.naming.*;

public class IndexBean {

    private static org.apache.log4j.Logger LOG = org.apache.log4j.Logger.getLogger(IndexBean.class);

    public boolean init(){
        try{
            Connection conn = ((DataSource)((Context)(new InitialContext()).lookup("java:/comp/env")).lookup("jdbc/cubrid")).getConnection();
            LOG.debug(conn.toString());

            try{
                conn.close();
            }catch(Exception e){
                LOG.error("DB작업중 오류");
            }

        }catch(Exception e){
            LOG.error("DB접속 실패", e);
        }
        return false;
    }
}
------------------------------------------------------------------------------------------------------------
CentOS release 5.4 (Final)
Kernel r on an m
Linux jeemin 2.6.18-164.el5xen #1 SMP Thu Sep 3 04:03:03 EDT 2009 x86_64 x86_64 x86_64 GNU/Linux
java-1.6.0-openjdk-1.6.0.0-1.16.b17.el5
httpd-2.2.3-53.el5.centos.3
tomcat5-5.5.23-0jpp.19.el5_6
------------------------------------------------------------------------------------------------------------
@ cubrid master status
++ cubrid master (이)가 수행되고 있습니다.
@ cubrid server status
 Server jeemin (rel 8.3, pid 6921)
@ cubrid broker status
  NAME           PID  PORT  AS  JQ      REQ  TPS  QPS    LONG-T    LONG-Q  ERR-Q
================================================================================
* query_editor  6858 30000   5   0        0    0    0    0/60.0    0/60.0      0
* broker1       6868 33000   5   0        0    0    0    0/60.0    0/60.0      0
------------------------------------------------------------------------------------------------------------
@ cubrid server status
 Server jeemin (rel 8.3, pid 6921)
------------------------------------------------------------------------------------------------------------
[root@jeemin WEB-INF]# ps aux | grep "(cub_|java|http|tomcat|apache)"
root      2844  0.0  0.3 174420  3264 ?        Ss   Nov16   0:00 /usr/sbin/httpd
apache    2845  0.0  0.2 174556  3108 ?        S    Nov16   0:00 /usr/sbin/httpd
apache    2846  0.0  0.2 174552  3108 ?        S    Nov16   0:00 /usr/sbin/httpd
apache    2847  0.0  0.2 174556  3108 ?        S    Nov16   0:00 /usr/sbin/httpd
apache    2848  0.0  0.2 174552  3108 ?        S    Nov16   0:00 /usr/sbin/httpd
apache    2850  0.0  0.2 174556  3108 ?        S    Nov16   0:00 /usr/sbin/httpd
apache    2851  0.0  0.2 174552  3136 ?        S    Nov16   0:00 /usr/sbin/httpd
apache    2852  0.0  0.2 174556  3108 ?        S    Nov16   0:00 /usr/sbin/httpd
apache    2853  0.0  0.2 174552  3104 ?        S    Nov16   0:00 /usr/sbin/httpd
root      6855  0.0  0.2  48468  2320 ?        Ss   00:56   0:00 cub_master
root      6858  0.0  0.1  86940  1932 ?        Sl   00:56   0:00 cub_broker
root      6859  0.0  0.1  46112  2004 ?        S    00:56   0:00 query_editor_cub_cas_1
root      6860  0.0  0.1  46112  2004 ?        S    00:56   0:00 query_editor_cub_cas_2
root      6861  0.0  0.1  46112  2008 ?        S    00:56   0:00 query_editor_cub_cas_3
root      6862  0.0  0.1  46112  2008 ?        S    00:56   0:00 query_editor_cub_cas_4
root      6863  0.0  0.1  46112  2004 ?        S    00:56   0:00 query_editor_cub_cas_5
root      6868  0.0  0.1  86940  1928 ?        Sl   00:56   0:00 cub_broker
root      6869  0.0  0.1  46112  2004 ?        S    00:56   0:00 broker1_cub_cas_1
root      6870  0.0  0.1  46112  2004 ?        S    00:56   0:00 broker1_cub_cas_2
root      6871  0.0  0.1  46112  2008 ?        S    00:56   0:00 broker1_cub_cas_3
root      6872  0.0  0.1  46112  2004 ?        S    00:56   0:00 broker1_cub_cas_4
root      6873  0.0  0.1  46112  2004 ?        S    00:56   0:00 broker1_cub_cas_5
root      6880  0.0  0.1  72832  1176 ?        Sl   00:56   0:00 cub_auto start
root      6884  0.0  0.0  48036   916 ?        S    00:56   0:00 cub_js start
root      6921  0.0 12.9 1255556 135748 ?      Ssl  00:57   0:00 cub_server jeemin
tomcat    9977  0.4  5.2 1132032 54896 ?       Sl   01:36   0:02 /usr/lib/jvm/java/bin/java -Dcatalina.ext.dirs=/usr/share/tomcat5/shared/lib:/usr/share/tomcat5/common/lib -Djavax.sql.DataSource.Factory=org.apache.commons.dbcp.BasicDataSourceFactory -Dcatalina.ext.dirs=/usr/share/tomcat5/shared/lib:/usr/share/tomcat5/common/lib -Djavax.sql.DataSource.Factory=org.apache.commons.dbcp.BasicDataSourceFactory -Djava.endorsed.dirs=/usr/share/tomcat5/common/endorsed -classpath /usr/lib/jvm/java/lib/tools.jar:/usr/share/tomcat5/bin/bootstrap.jar:/usr/share/tomcat5/bin/commons-logging-api.jar:/usr/share/java/mx4j/mx4j-impl.jar:/usr/share/java/mx4j/mx4j-jmx.jar -Dcatalina.base=/usr/share/tomcat5 -Dcatalina.home=/usr/share/tomcat5 -Djava.io.tmpdir=/usr/share/tomcat5/temp org.apache.catalina.startup.Bootstrap start
root     10494  0.0  0.0  61200   724 pts/1    R+   01:46   0:00 grep (cub_|java|http|tomcat|apache)
[root@jeemin WEB-INF]#
------------------------------------------------------------------------------------------------------------
[root@jeemin WEB-INF]# csql -ujeemin -p1234 jeemin -e

CUBRID SQL 수행기


도움말 메시지를 보려면 ';help' 명령어를 입력하세요.

csql> create class t1(a1 int);
csql> insert into t1(a1) values(123);
csql> select * from t1;
csql> drop class t1;
csql> ;ru

진행 중인 트랜잭션이 커밋 되었습니다.

1 개의 열이 affected.

진행 중인 트랜잭션이 커밋 되었습니다.

=== <SELECT의 결과, 명령어 라인 3> ===

           a1
=============
          123


1 개의 열이 selected.

진행 중인 트랜잭션이 커밋 되었습니다.

진행 중인 트랜잭션이 커밋 되었습니다.

4 개의 명령어가 실행되었습니다.
csql> ;exit
[root@jeemin WEB-INF]# cat csql.err 
[root@jeemin WEB-INF]# 
------------------------------------------------------------------------------------------------------------


일단 톰캣재구동, cubrid재시작 (server와 service모두), 시스템 리부트 까진 해봤습니다.

뭐가 문젠지를 모르겠네요...


여기서 뭘 더 어떻게 해야 하나요?
  • ?
    seongjoon 2011.11.18 19:57

    에러 로그를 보았을 때는 broker와 connection을 만들지 못하는 것 같습니다.

    방화벽 설정이 되어 있는지 확인을 하셔야 되며, DB엔진의 버젼과 jdbc 버젼이 일치하는지도 확인을 해보셔야 될 것 같습니다.


  • ?
    안지민 2011.11.18 20:36

    빠르고 정확한 답변 감사드립니다. JDBC드라이버 버전이 다르네요... 이제 잘 되네요


  1. No Image notice by admin 2024/04/23 by admin
    Views 49 

    CUBRID 사용자를 위한 DBeaver 도구 출시 안내

  2. SQLGate for CUBRID 영구 무료 라이선스 제공

  3. R1.4 -> R2.2 마이그레이션 중 스키마 로드 에러

  4. double 표시형식 문의

  5. DLL WS2_32.dll에서 찾을 수 없습니다.

  6. 호스트 추가

  7. No Image 15Dec
    by 깨진질그릇조각인형
    2011/12/15 by 깨진질그릇조각인형
    Views 12  Replies 2

    cubrid 성능비교

  8. No Image 15Dec
    by 깨진질그릇조각인형
    2011/12/15 by 깨진질그릇조각인형
    Views 15590  Replies 5

    autocommit 관련

  9. cubrid 매니저 아이디 잊어 버렸는데..

  10. HTML 게시판 작성후 데이타베이스 연결 방법?

  11. 분석용 함수 지원여부..

  12. 계정별 접근 권한에 대한 질문입니다.

  13. 매니저가 실행이 되지 않습니다.

  14. 컬럼 데이터타입 수정 문의

  15. [초보질문] 텍스트파일을 하나의 TABLE로 입력하고 싶습니다.

  16. 질의자동화 다시한번 여쭤봅니다.

  17. 테이블 생성시 PRIMARY KEY 2개일때 오류

  18. 리눅스 버젼 설치시 demodb 생성이 안됩니다.

  19. 암호/복호화 함수

  20. like 검색

  21. CUBRID 공간데이터 타입 기대해도 되나요?

  22. 말도 안되는 Exception이 발생하는데 대체 뭘까요;;

Board Pagination Prev 1 ... 139 140 141 142 143 144 145 146 147 148 ... 200 Next
/ 200

Contact Cubrid

대표전화 070-4077-2110 / 기술문의 070-4077-2113 / 영업문의 070-4077-2112 / Email. contact_at_cubrid.com
Contact Sales