|
疑问解答
一.忘记说环境了我们生产环境是oracle 9205RAC三个节点。没有使用stream来做复制。关于延迟事务存储的表空间,之前在网上查过一些资料,默认的存在系统表空间,如果要修改就需要在建库时候修改脚本或者重新建库才可以。关于表只读的错误类似这样的,就是在复制中不使用oracle复制提供的包直接修改表结构的错误一样,但是真的没有修改过表结构,然后表结构变化oracle要你重新生成复制支持才可以继续操作那表。这样情况下生产没办法用了,因为一些表都成只读了,找顾问得到临时解决办法是:
使用DBMS_DEFER_SYS.SET_DISABLED来先停止复制。然后表就变成可以写了。然后顾问建议我们先将高级复制撤下来。
二.真正停止复制的步骤是没错了都是文档上写的步骤,
a.停复制组
b.删除复制对象
c.删除复制组
主要问题是累计了太多的延迟事务没有传递(100w以上延迟事务),在这种情况下又想撤下高级复制的做法。
停止复制组将会把未传递的事务先传递完毕,那么就只有将累及的延迟事务直接删除掉了,想法是这样,其实也很简单了,就是我们不知道是那些相关的内部表。下边是向oracle开sr之后得到的回复。还算比较及时,要不然我就挂了,生产系统表空间已经没得加了。
SOLUTION / ACTION PLAN
=======================
To implement the solution, please execute the following steps:
For each of the 5 groups,just do the actions one by one.
1. if posible,please stop the application for a while. But do not stop the resouce oracle using(including network,listener,etc)
2. Stop all the replication push and purge job. Stop current running push&purge job first.
note: 1)in 2 sites,run the whole step 2
2)no special comments, all user please use 'repadmin'
2.1 Check if the push job is currently running
select /*+ ORDERED */ j.job, j.sid, d.dblink,
SUBSTR(TO_CHAR(J.THIS_DATE,'MM/DD/RRRR HH24:MI:SS'),1,20) START_DATE
from defschedule d, dba_jobs_running j
where j.job in (select job from dba_jobs
where upper(what) like '%DBMS_DEFER_SYS.PUSH%')
and j.job = d.job;
JOB SID DBLINK START_DATE
---------- ---------- ------------------------------ -------------------
44 9 DB2.WORLD 05/16/2002 12:14:47
- if exist,then note the sid
- Kill the Job Queue Process from the Operating System. To do this use
the sid to identify the process in v$session, v$process
and v$bgprocess. The process will generally be named SNPx or Jxxx.
- After killing the process, wait approximately 1 minute, to ensure the
job is removed from dba_jobs_running.
You can kill the corresponding session after finding its serial# from
v$session:
select serial# from v$session where sid=9;
SERIAL#
----------
24909
alter system kill session '8,24909';
2.2 stop all push&purge job in 2 sites.
select job, what,broken from dba_jobs where upper(what) like '%DBMS_DEFER_SYS%';
JOB WHAT BROKEN
-------- ----------------------------------------------------------------------------------------
43 declare rc binary_integer; begin rc := sys.dbms_defer_sys.purge( N
delay_seconds=>0); end;
44 declare rc binary_integer; begin rc := sys.dbms_defer_sys.push(d N
estination=>'DB2.WORLD', stop_on_error=>FALSE, delay_seconds=>0,
parallelism=>2); end;
- Break the job with :
execute dbms_job.broken(<jobno>, true);--<jobno>need be changed from the previous query resu
lt.
commit;
Query again to confirm the push & purge job has all been stopped
3. remove the deferred queue
select constraint_name, table_name
from sys.dba_constraints where table_name = 'DEF$_CALLDEST';
CONSTRAINT_NAME TABLE_NAME
------------------------------ ------------------
DEF$_CALLDEST_PRIMARY DEF$_CALLDEST
DEF$_CALL_DESTINATION DEF$_CALLDEST
Note: As of Oracle8, system.DEF$_CALLDEST_CALL in not being used and
system.DEF$_CALL has been changed to system.DEF$_AQCALL (this
is due to the advanced queueing features in Oracle8)
truncate table system.DEF$_AQCALL;
truncate table system.DEF$_CALLDEST;
truncate table system.DEF$_ERROR;
truncate table system.DEF$_AQERROR;
truncate table system.DEF$_LOB; -- if there are LOBs replicated.
select * from DEFCALL;
no rows
select * from DEFTRAN;
no rows
select * from DEFERROR;
no rows
4. When All the steps are implemented on 2 sites,we can try to suspend the master group from the master definition site.
It wont take a lot of time. Then,you can remove the replcation object and the w
hole replication enviroment.
三.还是对高级复制了解太少,所以才会这样。只是高级复制的资料真的很少。版主能不能提供一些来研究,谢谢。
关键是对高级复制能够承载的数据量不清楚,和可以调节的参数不了解。 |
|