목록Oracle (15)
HeeLee_DBA

특정 쿼리로 인한 library cache lock 및 cursor: pin S wait on X 이벤트가 발생함. -- 임시조치 -- shared memory 부족으로 인해 DB 접속 실패 날 경우(ORA-04031: unable to allocate nn bytes of shared memory) ps -ef | grep oracle kill -9 PID 로 PGA 공간 확보 필요 -- 전체 메모리 flush(권장하진 않음) : 기존 대용량 쿼리들이 메모리에서 지워지면서 새로 parsing 할때 부하가 옴alter system flush shared_pool; -- 메모리 점유율 높은 sql purgeselect sql_id, hash_value, round(sharable_mem/1024/1024)..

-- SQL Monitor Active Report 뽑기 1. SQL_ID 추출 후 2. 아래 실행(특정 쿼리 SQL Monitor Active Report) SPOOL /tmp/long_sql.htm SELECT DBMS_SQL_MONITOR.REPORT_SQL_MONITOR(sql_id => ' ' , report_level => 'ALL', TYPE => 'active') FROM DUAL; SPOOL OFF 추출완료 참조 : https://positivemh.tistory.com/431
ORA-12012: error on auto execute of job "SCHEMA"."TEST_JOB" ORA-12805: parallel query server died unexpectedly ORA-06512: at "SCHEMA.PROCEDURE", line 12 1. alert 로그 분석 ORA-12012: error on auto execute of job "SCHEMA"."TEST_JOB" 아래 쿼리로 조회시 JOB 실패가 많음 -- job 실패 조회 select * from DBA_SCHEDULER_JOB_LOG where OWNER = 'SCHEMA' and STATUS IN ('FAILED', 'STOPPED') order by log_date -- object last_ddl_tim..
증상 : error log 및 간헐적인 db connetion 실패 skgxpvfynet: mtype: 61 process 24645 failed because of a resource problem in the OS. The OS has most likely run out of buffers (rval: 4) opiodr aborting process unknown ospid (24645) as a result of ORA-603 임시 조치하여 해결 --sync 후 메모리 초기화 sync sysctl -w vm.drop_caches=1 ** vm.min_free_kbytes 값 조정 필요
ORA-00600 내부 오류코드 kdsgrp1 1. 증상 : where절에서 특정 컬럼 인덱스를 사용하는 쿼리가 실행이 안됨 --alert 로그 2022-11-15T13:52:23.749747+09:00 Errors in file /oracle/diag/rdbms/xxxx/xxxx/trace/xxxx_ora_66720.trc (incident=40961): ORA-00600: 내부 오류 코드, 인수: [kdsgrp1], [], [], [], [], [], [], [], [], [], [], [] Use ADRCI or Support Workbench to package the incident. See Note 411.1 at My Oracle Support for error and packaging de..
Oracle 슬로우 쿼리(Slow Query) 조회 쿼리 SELECT PARSING_SCHEMA_NAME 사용자이름 ,to_char(ELAPSED_TIME/(1000000 * decode(executions,null,1,0,1,executions)),999999.99 ) 평균실행시간 ,executions 실행횟수 ,SQL_TEXT 쿼리 ,SQL_FULLTEXT 전체쿼리 FROM V$SQL --실행한 쿼리를 담고있는 테이블 WHERE LAST_ACTIVE_TIME > SYSDATE-(1/24*2) AND ELAPSED_TIME >= 1 * 1000000 * decode(executions,null,1,0,1,executions) AND executions > 10 ORDER BY 평균실행시간 DESC, 실..

Lock은 데이터 무결성을 보장하기 위해서 존재하며, OLTP환경에서는 Lock구조를 잘 이해하고 컨트롤 해야한다. 1. Lock은 크게 DML Lock, DDL Lock, System Lock(latch, mutex 등...)이 있다. 2. DML Lock은 TX(Row Lock), TM(Table Lock) 두 종류가 있으며, TM Lock에는 1) RS - Row Share 2) RX - Row Exclusive Table Lock 3) S - Share Table Lock 4) SRX - Share Row Exclusive Table Lock, SSX(share-subexclusive table lock)라고도 함 5) X - Exclusive Table Lock 종류의 Lock이 있다. Null..
ORA-00603 증상 - DB가 간헐적으로 접속되었다 안되었다함체크 - crsctl status resource -t 클러스터 상태 체크, 세션 수 체크 해결 - WAS 재기동하여 해결, was에서 db메모리를 해지하지 않아서 생기는 현상 -DB connection error-java.sql.SQLRecoverableException: IO 오류: Got minus one from a read call, connect lapse 27864 ms., Authentication lapse 0 ms. -alert log-skgxpvfynet: mtype: 61 process 1145 failed because of a resource problem in the OS. The OS has most likel..