Thứ Hai, 6 tháng 7, 2015

[Oracle Tunning]

1/ Parameters:

plsql_code_type=NATIVE;
plsql_optimize_level=2;


updating ....



[Oracle Datapump] export from 11g import into 10g

1/Export from 11g: using version=10.2 option in export command.

export xxxx/xxxx@db version=10.2;

2/ Import into 10g: it is import as normally.




KILL DDL_LOCK ON ORACLE DATABASE



1/ To Determine sid,spid of session that is cause of DDL lock.

SELECT s.inst_id,
       s.sid,
       s.serial#,
       p.spid,
       s.username,
       D.NAME,
       D.TYPE,
       s.program
FROM   gv$session s, gv$process p, DBA_DDL_LOCKS d where p.addr = s.paddr AND p.inst_id = s.inst_id and s.type != 'BACKGROUND' and s.sid=D.SESSION_ID;

2/ Kill the session:

- Windows: orakill oracle_sid spid
- Linux: kill -9 spid