oracle-排查dg环境文件不开Auto同步导致的错误

简介:

故障:

主库表空间添加文件,备库同步挂了。

排查

主库alert log:

ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move276.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Tue Jul 26 12:04:44 2022
Thread 1 cannot allocate new log, sequence 248280
Private strand flush not complete
  Current log# 4 seq# 248279 mem# 0: /oradata01/orcl/redo04.log
Thread 1 advanced to log sequence 248280 (LGWR switch)
  Current log# 1 seq# 248280 mem# 0: /oradata01/orcl/redo01.log
Tue Jul 26 12:04:48 2022
LNS: Standby redo logfile selected for thread 1 sequence 248280 for destination LOG_ARCHIVE_DEST_2
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move276.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move277.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Tue Jul 26 12:04:55 2022
Archived Log entry 316646 added for thread 1 sequence 248279 ID 0xfffffffff4ad5d16 dest 1:
Tue Jul 26 12:04:57 2022
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move277.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move278.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move278.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move279.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Tue Jul 26 12:05:09 2022
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move279.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move280.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move280.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Tue Jul 26 12:07:13 2022
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move281.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move281.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move282.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Tue Jul 26 12:07:24 2022
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move282.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move283.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move283.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move284.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move284.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move285.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Tue Jul 26 12:07:38 2022
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move285.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Tue Jul 26 12:09:58 2022
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move286.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move286.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move287.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move287.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move288.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Tue Jul 26 12:10:12 2022
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move288.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move289.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move289.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move290.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Tue Jul 26 12:10:23 2022
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move290.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Tue Jul 26 12:11:44 2022
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move291.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move291.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move292.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Tue Jul 26 12:11:54 2022
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move292.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move293.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move293.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move294.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Tue Jul 26 12:12:05 2022
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move294.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move295.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Completed: ALTER TABLESPACE orcl_move ADD DATAFILE '/datalv4/db/oradata/orcl/orcl_move295.dbf' SIZE 1G AUTOEXTEND ON NEXT 100M MAXSIZE 30G
Tue Jul 26 12:13:35 2022

备库

alert log

Media Recovery Waiting for thread 1 sequence 248280 (in transit)
Recovery of Online Redo Log: Thread 1 Group 5 Seq 248280 Reading mem 0
  Mem# 0: /data01/redo_log/orcl/stdredo01.log
Tue Jul 26 12:04:58 2022
Archived Log entry 498722 added for thread 1 sequence 248279 ID 0xfffffffff4ad5d16 dest 1:
File #321 added to control file as 'UNNAMED00321' because
the parameter STANDBY_FILE_MANAGEMENT is set to MANUAL
The file should be manually created to continue.
MRP0: Background Media Recovery terminated with error 1274
Errors in file /data01/u01/app/oracle/diag/rdbms/orclp/orcl/trace/orcl_pr00_10158200.trc:
ORA-01274: cannot add datafile '/datalv4/db/oradata/orcl/orcl_move276.dbf' - file could not be created
Managed Standby Recovery not using Real Time Apply
Recovery interrupted!
Recovered data files to a consistent state at change 12258879621859
Tue Jul 26 12:05:02 2022
MRP0: Background Media Recovery process shutdown (orcl)
Tue Jul 26 12:13:48 2022

原来是STANDBY_FILE_MANAGEMENT设成了manual导致路径不对

查看数据文件,发现有个文件路径不对

SQL>  select name from v$datafile;

NAME
--------------------------------------------------------------------------------
/data01/oradata01/orcl/orcl_move264.dbf
/data01/oradata01/orcl/orcl_move265.dbf
/data01/oradata01/orcl/orcl_move266.dbf
/data01/oradata01/orcl/orcl_move267.dbf
/data01/oradata01/orcl/orcl_move268.dbf
/data01/oradata01/orcl/orcl_move269.dbf
/data01/oradata01/orcl/orcl_move270.dbf
/data01/oradata01/orcl/orcl_move271.dbf
/data01/oradata01/orcl/orcl_move272.dbf
/data01/oradata01/orcl/orcl_move273.dbf
/data01/oradata01/orcl/orcl_move274.dbf

NAME
--------------------------------------------------------------------------------
/data01/oradata01/orcl/orcl_move275.dbf
/data01/u01/app/oracle/product/11.2.0/dbhome_1/dbs/UNNAMED00321

321 rows selected.

查看dg参数设置

SQL> show parameter conver;

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
db_file_name_convert                 string      /oradata01/orcl/, /data01/
                                                 oradata01/orcl/, /datalv3/
                                                 db/oradata/orcl/, /data01/
                                                 oradata01/orcl/, /datalv4/
                                                 db/oradata/orcl/, /data01/
                                                 oradata01/orcl/
log_file_name_convert                string      /oradata01/orcl/, /data01/
                                                 redo_log/orcl/
SQL> 
/oradata01/orcl/, /data01/oradata01/orcl/, 
/datalv3/db/oradata/orcl/, /data01/oradata01/orcl/, 
/datalv4/db/oradata/orcl/, /data01/oradata01/orcl/

SQL> show parameter standby_file_management

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
standby_file_management              string      MANUAL
SQL> 

于是修改路径有问题的这个文件

alter database create datafile '/data01/u01/app/oracle/product/11.2.0/dbhome_1/dbs/UNNAMED00321' as '/data01/oradata01/orcl/orcl_move276.dbf';
alert log
Tue Jul 26 12:39:05 2022
alter database create datafile '/data01/u01/app/oracle/product/11.2.0/dbhome_1/dbs/UNNAMED00321' as '/data01/oradata01/orcl/orcl_move276.dbf'
Completed: alter database create datafile '/data01/u01/app/oracle/product/11.2.0/dbhome_1/dbs/UNNAMED00321' as '/data01/oradata01/orcl/orcl_move276.dbf'
查看文件
$ ls -ltr /data01/oradata01/orcl/orcl_move276.dbf
-rw-r-----    1 oracle   oinstall 1073750016 Jul 26 12:39 /data01/oradata01/orcl/orcl_move276.dbf
$ ls -ltr /data01/u01/app/oracle/product/11.2.0/dbhome_1/dbs/UNNAMED00321
ls: 0653-341 The file /data01/u01/app/oracle/product/11.2.0/dbhome_1/dbs/UNNAMED00321 does not exist.
$ 


select name from v$datafile ;
NAME
------------------------------------------------------------
/data01/oradata01/orcl/orcl_move272.dbf
/data01/oradata01/orcl/orcl_move273.dbf
/data01/oradata01/orcl/orcl_move274.dbf
/data01/oradata01/orcl/orcl_move275.dbf
/data01/oradata01/orcl/orcl_move276.dbf

269 rows selected.

SQL>

修改文件同步参数,开启同步

SQL> alter system set standby_file_management=auto scope=both;

System altered.

SQL> show parameter standby_file_management

NAME                                 TYPE       VALUE
------------------------------------ ---------- ------------------------------
standby_file_management              string     AUTO
SQL> 

SQL> alter database recover managed standby database using current logfile disconnect from session;

Database altered.

SQL> select open_mode from v$database;

OPEN_MODE
--------------------
READ ONLY WITH APPLY

SQL> 

dg正常了,文件是同步过来了,但发现新问题:文件前都带了空格

select name from v$datafile ;
/data01/oradata01/orcl/orcl_move273.dbf
/data01/oradata01/orcl/orcl_move274.dbf
/data01/oradata01/orcl/orcl_move275.dbf
/data01/oradata01/orcl/orcl_move276.dbf
/data01/oradata01/orcl/ orcl_move277.dbf
/data01/oradata01/orcl/ orcl_move278.dbf
/data01/oradata01/orcl/ orcl_move279.dbf
/data01/oradata01/orcl/ orcl_move280.dbf
/data01/oradata01/orcl/ orcl_move281.dbf
/data01/oradata01/orcl/ orcl_move282.dbf
/data01/oradata01/orcl/ orcl_move283.dbf
/data01/oradata01/orcl/ orcl_move284.dbf
/data01/oradata01/orcl/ orcl_move285.dbf
/data01/oradata01/orcl/ orcl_move286.dbf
/data01/oradata01/orcl/ orcl_move287.dbf
/data01/oradata01/orcl/ orcl_move288.dbf
/data01/oradata01/orcl/ orcl_move289.dbf
/data01/oradata01/orcl/ orcl_move290.dbf
/data01/oradata01/orcl/ orcl_move291.dbf
/data01/oradata01/orcl/ orcl_move292.dbf
/data01/oradata01/orcl/ orcl_move293.dbf
/data01/oradata01/orcl/ orcl_move294.dbf
/data01/oradata01/orcl/ orcl_move295.dbf
应该是db_file_name_convert配置有问题,但show parameter db_file_name_convert看不出有空格,于是生成pfile查看,果然是有空间
db_file_name_convert='/oradata01/orcl/','/data01/oradata01/orcl/','/datalv3/db/oradata/orcl/','/data01/oradata01/orcl/','/datalv4/db/oradata/orcl/','/data01/oradata01/orcl/ '

于是,修改文件路径。。。

先把同步停了,文件同步参数改成manual

alter database recover managed standby database cancel;
 alter system set standby_file_management=MANUAL scope=both;
 
 SQL> select open_mode from v$database;

OPEN_MODE
--------------------
READ ONLY

SQL>  show parameter standby_file_management

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
standby_file_management              string      MANUAL
SQL> 

修改db_file_name_convert参数,需要重启生效。

SQL> alter system  set db_file_name_convert='/oradata01/orcl/','/data01/oradata01/orcl/','/datalv3/db/oradata/orcl/','/data01/oradata01/orcl/','/datalv4/db/oradata/orcl/','/data01/oradata01/orcl/' scope=spfile;
System altered.

rename数据文件也需要重启到mount状态才行,于是重启数据库。

SQL> startup mount force;
ORACLE instance started.

Total System Global Area 1.4965E+11 bytes
Fixed Size                  2254176 bytes
Variable Size            2.2549E+10 bytes
Database Buffers         1.2670E+11 bytes
Redo Buffers              400384000 bytes
Database mounted.
SQL> select open_mode from v$database;

OPEN_MODE
--------------------
MOUNTED

rename 数据文件

alter database rename file '/data01/oradata01/orcl/ orcl_move277.dbf' to '/data01/oradata01/orcl/orcl_move277.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move278.dbf' to '/data01/oradata01/orcl/orcl_move278.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move279.dbf' to '/data01/oradata01/orcl/orcl_move279.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move280.dbf' to '/data01/oradata01/orcl/orcl_move280.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move281.dbf' to '/data01/oradata01/orcl/orcl_move281.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move282.dbf' to '/data01/oradata01/orcl/orcl_move282.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move283.dbf' to '/data01/oradata01/orcl/orcl_move283.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move284.dbf' to '/data01/oradata01/orcl/orcl_move284.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move285.dbf' to '/data01/oradata01/orcl/orcl_move285.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move286.dbf' to '/data01/oradata01/orcl/orcl_move286.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move287.dbf' to '/data01/oradata01/orcl/orcl_move287.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move288.dbf' to '/data01/oradata01/orcl/orcl_move288.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move289.dbf' to '/data01/oradata01/orcl/orcl_move289.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move290.dbf' to '/data01/oradata01/orcl/orcl_move290.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move291.dbf' to '/data01/oradata01/orcl/orcl_move291.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move292.dbf' to '/data01/oradata01/orcl/orcl_move292.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move293.dbf' to '/data01/oradata01/orcl/orcl_move293.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move294.dbf' to '/data01/oradata01/orcl/orcl_move294.dbf';
alter database rename file '/data01/oradata01/orcl/ orcl_move295.dbf' to '/data01/oradata01/orcl/orcl_move295.dbf';

查看Rename成功

select name from v$datafile;

/data01/oradata01/orcl/orcl_move277.dbf
/data01/oradata01/orcl/orcl_move278.dbf
/data01/oradata01/orcl/orcl_move279.dbf
/data01/oradata01/orcl/orcl_move280.dbf
/data01/oradata01/orcl/orcl_move281.dbf
/data01/oradata01/orcl/orcl_move282.dbf
/data01/oradata01/orcl/orcl_move283.dbf
/data01/oradata01/orcl/orcl_move284.dbf
/data01/oradata01/orcl/orcl_move285.dbf

NAME
--------------------------------------------------------------------------------
/data01/oradata01/orcl/orcl_move286.dbf
/data01/oradata01/orcl/orcl_move287.dbf
/data01/oradata01/orcl/orcl_move288.dbf
/data01/oradata01/orcl/orcl_move289.dbf
/data01/oradata01/orcl/orcl_move290.dbf
/data01/oradata01/orcl/orcl_move291.dbf
/data01/oradata01/orcl/orcl_move292.dbf
/data01/oradata01/orcl/orcl_move293.dbf
/data01/oradata01/orcl/orcl_move294.dbf
/data01/oradata01/orcl/orcl_move295.dbf

到os数据文件所在目录下,mv一下带空格的数据文件

mv " orcl_move277.dbf"  "orcl_move277.dbf"
mv " orcl_move278.dbf"  "orcl_move278.dbf"
mv " orcl_move279.dbf"  "orcl_move279.dbf"
mv " orcl_move280.dbf"  "orcl_move280.dbf"
mv " orcl_move281.dbf"  "orcl_move281.dbf"
mv " orcl_move282.dbf"  "orcl_move282.dbf"
mv " orcl_move283.dbf"  "orcl_move283.dbf"
mv " orcl_move284.dbf"  "orcl_move284.dbf"
mv " orcl_move285.dbf"  "orcl_move285.dbf"
mv " orcl_move286.dbf"  "orcl_move286.dbf"
mv " orcl_move287.dbf"  "orcl_move287.dbf"
mv " orcl_move288.dbf"  "orcl_move288.dbf"
mv " orcl_move289.dbf"  "orcl_move289.dbf"
mv " orcl_move290.dbf"  "orcl_move290.dbf"
mv " orcl_move291.dbf"  "orcl_move291.dbf"
mv " orcl_move292.dbf"  "orcl_move292.dbf"
mv " orcl_move293.dbf"  "orcl_move293.dbf"
mv " orcl_move294.dbf"  "orcl_move294.dbf"
mv " orcl_move295.dbf"  "orcl_move295.dbf"

修改文件同步参数,启动数据库到readonly,打开实时同步

SQL> alter system set standby_file_management=auto scope=both;

System altered.

SQL> show parameter standby_file_management

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
standby_file_management              string      AUTO
SQL> alter database open;

Database altered.

SQL> select open_mode from v$database; 

OPEN_MODE
--------------------
READ ONLY

SQL> alter database recover managed standby database using current logfile disconnect from session;

Database altered.

SQL> select open_mode from v$database; 

OPEN_MODE
--------------------
READ ONLY WITH APPLY

SQL> 

检查同步是否正常

主库查,no gap
SQL> set line 300
SQL> col DB_UNIQUE_NAME for a20
SQL> col DEST_NAME for a20
col DESTINATION for a20
col DATABASE_MODE for a20
col recovery_mode for a25
col destination for a25
col gap_status for a10
SQL> SQL> SQL> SQL> SQL> SQL> col type for a10
SQL> col status for a10
select dest_id,dest_name,status,type,database_mode,recovery_mode,destination,db_unique_name,gap_status from v$archive_dest_status where status='VALID';
SQL> 
   DEST_ID DEST_NAME            STATUS     TYPE       DATABASE_MODE        RECOVERY_MODE             DESTINATION               DB_UNIQUE_NAME       GAP_STATUS
---------- -------------------- ---------- ---------- -------------------- ------------------------- ------------------------- -------------------- ----------
         1 LOG_ARCHIVE_DEST_1   VALID      LOCAL      OPEN                 IDLE                      /arch01/orcl/         NONE
         2 LOG_ARCHIVE_DEST_2   VALID      PHYSICAL   OPEN_READ-ONLY       MANAGED REAL TIME APPLY   orclp                 orclp            NO GAP

SQL> 
SQL> select thread#, sequence# from v$thread;

   THREAD#  SEQUENCE#
---------- ----------
         1     248290

SQL> 
备库:
SQL> select process, status, thread#, sequence# from v$managed_standby where process='MRP0';

PROCESS   STATUS          THREAD#  SEQUENCE#
--------- ------------ ---------- ----------
MRP0      APPLYING_LOG          1     248290

SQL> 
目录
相关文章
|
3月前
|
Oracle 关系型数据库 数据库连接
初步了解Oracle DG
初步了解Oracle DG
104 0
|
4月前
|
存储 Oracle 关系型数据库
|
4月前
|
SQL Oracle 关系型数据库
关系型数据库Oracle设置 RMAN 环境:
【7月更文挑战第25天】
69 2
|
5月前
|
Oracle 关系型数据库 数据处理
实时计算 Flink版产品使用问题之如何进行Oracle到HBase的同步
实时计算Flink版作为一种强大的流处理和批处理统一的计算框架,广泛应用于各种需要实时数据处理和分析的场景。实时计算Flink版通常结合SQL接口、DataStream API、以及与上下游数据源和存储系统的丰富连接器,提供了一套全面的解决方案,以应对各种实时计算需求。其低延迟、高吞吐、容错性强的特点,使其成为众多企业和组织实时数据处理首选的技术平台。以下是实时计算Flink版的一些典型使用合集。
|
5月前
|
SQL Oracle 关系型数据库
实时计算 Flink版产品使用问题之在进行Oracle数据库的全量同步时,只同步了一条数据而源表实际上包含多条数据,是什么原因
实时计算Flink版作为一种强大的流处理和批处理统一的计算框架,广泛应用于各种需要实时数据处理和分析的场景。实时计算Flink版通常结合SQL接口、DataStream API、以及与上下游数据源和存储系统的丰富连接器,提供了一套全面的解决方案,以应对各种实时计算需求。其低延迟、高吞吐、容错性强的特点,使其成为众多企业和组织实时数据处理首选的技术平台。以下是实时计算Flink版的一些典型使用合集。
|
5月前
|
SQL Oracle 关系型数据库
实时计算 Flink版产品使用问题之同步oracle表时,数据量约800万,检查点异常,该如何排查
实时计算Flink版作为一种强大的流处理和批处理统一的计算框架,广泛应用于各种需要实时数据处理和分析的场景。实时计算Flink版通常结合SQL接口、DataStream API、以及与上下游数据源和存储系统的丰富连接器,提供了一套全面的解决方案,以应对各种实时计算需求。其低延迟、高吞吐、容错性强的特点,使其成为众多企业和组织实时数据处理首选的技术平台。以下是实时计算Flink版的一些典型使用合集。
|
SQL Oracle 关系型数据库
|
SQL Oracle 关系型数据库