码迷,mamicode.com
首页 > 其他好文 > 详细

参数调优

时间:2020-05-15 00:39:32      阅读:79      评论:0      收藏:0      [点我收藏+]

标签:实例   rac   关闭   base   ike   immediate   style   cal   recovery   

--查询检测是否已设置
SQL>show parameter log_file_sync
SQL>show parameter parallel_force_local
SQL>select client_name,status from dba_autotask_client;
SQL>select status,filename from v$block_change_tracking;
SQL>select * from v$rman_backup_job_details;

--参数调整
---关闭自适应log file sync
SQL>alter system set "_use_adaptive_log_file_sync"=false sid=*;
---在11G版本中,为了降低集群间的数据交互,建议并行进程强制在本地实例分配。
SQL>alter system set parallel_force_local=TRUE sid=*;
---禁用auto space advisor
SQL>BEGIN
  DBMS_AUTO_TASK_ADMIN.disable(
    client_name => auto space advisor,
    operation   => NULL,
    window_name => NULL);
END;
/
SQL>commit;
--开启块跟踪
SQL>alter database enable block change tracking using file +DATA reuse;
--查询检测设置是否生效
SQL>show parameter log_file_sync
SQL>show parameter parallel_force_local
SQL>select client_name,status from dba_autotask_client;
SQL>select status,filename from v$block_change_tracking;
SQL>select * from v$rman_backup_job_details;

 

show parameter log_file_sync
show parameter parallel_force_local
select client_name,status from dba_autotask_client;
select status,filename from v$block_change_tracking;


alter system set "_use_adaptive_log_file_sync"=false sid=*;
alter system set parallel_force_local=TRUE sid=*;
BEGIN
  DBMS_AUTO_TASK_ADMIN.disable(
    client_name => auto space advisor,
    operation   => NULL,
    window_name => NULL);
END;
/
commit;
alter database enable block change tracking using file +DATA reuse;



SQL> select PROGRAM,sid,serial#,username,sql_id,event,BLOCKING_SESSION_STATUS,BLOCKING_INSTANCE,BLOCKING_SESSION from  v$session where username=SYS  ;

PROGRAM                                                 SID    SERIAL#
------------------------------------------------ ---------- ----------
USERNAME                       SQL_ID
------------------------------ -------------
EVENT                                                            BLOCKING_SE
---------------------------------------------------------------- -----------
BLOCKING_INSTANCE BLOCKING_SESSION
----------------- ----------------
sqlplus@dsapdb23 (TNS V1-V3)                            249      42993
SYS
enq: CT - state                                                  VALID
                2              443


SQL> select sql_id,sid,serial#,event,username,PROGRAM from gv$session where inst_id=2 and sid=443;

SQL_ID               SID    SERIAL#
------------- ---------- ----------
EVENT
----------------------------------------------------------------
USERNAME                       PROGRAM
------------------------------ ------------------------------------------------
                     443      18359
RMAN backup & recovery I/O
SYS                            rman@dsapdb24 (TNS V1-V3)


  1* select sid,serial#,username,event from gv$session where status=ACTIVE AND STATE !=WAITING

       SID    SERIAL# USERNAME                       EVENT
---------- ---------- ------------------------------ ----------------------------------------------------------------
       248      58713 SYS                            PX Deq: Execution Msg
      2019      14945 SYS                            PX Deq: Execution Msg



alter system kill session 249,42993 immediate;



select sid,serial#,username,event from gv$session where status=ACTIVE AND PROGRAM like rman%;

 

参数调优

标签:实例   rac   关闭   base   ike   immediate   style   cal   recovery   

原文地址:https://www.cnblogs.com/lvcha001/p/12891969.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!