설문조사
PostgreSQL/PPAS 관련 듣고 싶은 교육은


총 게시물 162건, 최근 0 건
   

홍이-7) dblink 사용시, 상황별 Error 케이스 정리

글쓴이 : 홍이 날짜 : 2014-12-18 (목) 13:38 조회 : 6342
dblink_ora 설정 후, 서버 상태별로 나타난 Error 를 정리해봤습니다.
=================================================================


1. Target 테이블명이 대문자일때,
edb=# select dblink_ora_copy('dblink_test','select * from  EMP','enterprisedb','EMP_ORA',true,10);
ERROR:  relation "enterprisedb.EMP_ORA" does not exist


2. oracle DBMS 가 shutdown 중이고, listner 가 떠 있는 상태 

edb=# select dblink_ora_connect('dblink_test','192.168.227.138','orcl','scott','daou2014','1521',false);
ERROR:  OCI call failed
DETAIL:  ORA-12528: TNS:listener: all appropriate instances are blocking new connections


3. oracle DBMS 가 offline 상태이고, listner 가 떠 있는 상태
edb=# select dblink_ora_connect('dblink_test','192.168.227.138','orcl','scott','daou2014','1521',false);
ERROR:  OCI call failed
DETAIL:  ORA-12514: TNS:listener does not currently know of service requested in connect descriptor


4. listner가 stop 일때,
edb=# select dblink_ora_connect('dblink_test','192.168.227.138','orcl','scott','daou2014','1521',false);
ERROR:  OCI call failed
DETAIL:  ORA-12541: TNS:no listener


5. oracle DBMS 가 startup 된 상태이고, listner가 stop 상태일때,
edb=# select dblink_ora_connect('dblink_test','192.168.227.138','orcl','scott','daou2014','1521',false);
ERROR:  OCI call failed
DETAIL:  ORA-12541: TNS:no listener


6. oracle DBMS 가 startup 된 상태이고, listner가 start 상태일때,

edb=# select dblink_ora_connect('dblink_test','192.168.227.138','orcl','scott','daou2014','1521',false);
ERROR:  OCI call failed
DETAIL:  ORA-12514: TNS:listener does not currently know of service requested in connect descriptor


>> sqlplus  로 접속 후, emp 테이블 조회를 한 상태에서 다시 ppas 쪽 수행

edb=# select dblink_ora_connect('dblink_test','192.168.227.138','orcl','scott','daou2014','1521',false);
 dblink_ora_connect 
--------------------
 OK
(1 row)

정상 수행됨.


   

postgresdba.com