Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

RMAN configuration DataGuard from active database with filesystem

2025-04-05 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

I. Environment

Hostnam

Database version

Dbname

Db_unique_name

IP address

System version

Jason1 (Master)

Oracle11204

Jason

Jason1

192.168.1.99

Rhel6.6_x86_64

Jason2 (standby)

Jason2

192.168.1.10

Second, the main library configuration 1. Make sure that the master database turns on the mandatory LOGGING mode

[oracle@jason1 ~] $sqlplus / nolog

SQL*Plus: Release 11.2.0.4.0 Production on Thu Jul 14 20:45:33 2016

Copyright (c) 1982, 2013, Oracle. All rights reserved.

SQL > conn / as sysdba

Connected.

SQL > ALTER DATABASE FORCE LOGGING

Database altered.

SQL > select force_logging from v$database

FOR

-

YES

two。 Open archiving

SQL > archive log list

Database log mode Archive Mode

Automatic archival Enabled

Archive destination USE_DB_RECOVERY_FILE_DEST

Oldest online log sequence 3

Next log sequence to archive 5

Current log sequence 5

SQL > select group#,bytes/1024/1024 from v$log

GROUP# BYTES/1024/1024

--

1 50

3 50

2 50

3. Create a standby log group

1). The file size of standby redo log is the same as the online redo log file size of primary database

2). The number of standby redo log log filegroups is calculated according to the following principles

Standby redo log group number formula > = (number of instance log groups + 1) * number of instance

For example, in my environment, there is only one node, and this node has three sets of redo, so

Standby redo log group number formula > = (3x 1) * 1 = = 4

So you need to create 4 groups of Standby redo log

3)。 For security reasons, each log group can contain multiple member files.

Check the number and size of log groups in the master database, and create standy log groups, which cannot be smaller than the online log size.

SQL > select member from v$logfile

MEMBER

/ u01/app/oracle/oradata/JASON/redo03.log

/ u01/app/oracle/oradata/JASON/redo02.log

/ u01/app/oracle/oradata/JASON/redo01.log

Create a standby log group in the primary database in the same path as the original log group.

SQL > ALTER DATABASE ADD STANDBY LOGFILE ('/ u01ax SIZE SIZE 50m)

Database altered.

SQL > ALTER DATABASE ADD STANDBY LOGFILE ('/ u01ax SIZE SIZE 50m)

Database altered.

SQL > ALTER DATABASE ADD STANDBY LOGFILE ('/ u01ax SIZE SIZE 50m)

Database altered.

SQL > ALTER DATABASE ADD STANDBY LOGFILE ('/ u01ax SIZE SIZE 50m)

Database altered.

SQL > select group#,status,type,member from v$logfile

GROUP# STATUS TYPE MEMBER

-

3 ONLINE / u01/app/oracle/oradata/JASON/redo03.log

2 ONLINE / u01/app/oracle/oradata/JASON/redo02.log

1 ONLINE / u01/app/oracle/oradata/JASON/redo01.log

4 STANDBY/u01/app/oracle/oradata/JASON/standby01.log

5 STANDBY/u01/app/oracle/oradata/JASON/standby02.log

6 STANDBY / u01/app/oracle/oradata/JASON/standby03.log

7 STANDBY/u01/app/oracle/oradata/JASON/standby04.log

7 rows selected.

4. Main library parameter file configuration

Modify the parameters related to the dataguard configuration on the main library. The specific meaning of each parameter can be found in the oracle online documentation.

SQL > alter system set LOG_ARCHIVE_CONFIG='DG_CONFIG= (JASON1,JASON2) 'SCOPE=SPFILE

System altered.

SQL > alter system set DB_UNIQUE_NAME='JASON1' SCOPE=SPFILE

System altered.

SQL > alter system set STANDBY_FILE_MANAGEMENT='AUTO' SCOPE=SPFILE

System altered.

SQL > alter system set LOG_ARCHIVE_DEST_1='LOCATION=/u01/app/oracle/archivelog/VALID_FOR= (ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=JASON1' scope=spfile

System altered.

SQL > alter system set LOG_ARCHIVE_DEST_2='SERVICE=JASON2 ASYNCVALID_FOR= (ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=JASON2' scope=spfile

System altered.

SQL > alter system set LOG_ARCHIVE_DEST_STATE_1='ENABLE' scope=spfile

System altered.

SQL > alter system set LOG_ARCHIVE_DEST_STATE_2='ENABLE' scope=spfile

System altered.

SQL > alter system setLOG_FILE_NAME_CONVERT='/ u01 scope=spfile alter system setLOG_FILE_NAME_CONVERT='/ U01 scope=spfile

System altered.

SQL > alter system set FAL_SERVER='JASON2' scope=spfile

System altered.

SQL > shutdown immediate

Database closed.

Database dismounted.

ORACLE instance shut down.

SQL > startup

ORACLE instance started.

Total System Global Area 409194496 bytes

Fixed Size 2253744 bytes

Variable Size 310381648 bytes

Database Buffers 92274688 bytes

Redo Buffers 4284416 bytes

Database mounted.

Database opened.

5. Configure snooping and tnsname

To create listening and tnsname.ora, static listening must be used for slave listening, as shown below:

[oracle@jason1 admin] $cat listener.ora

# listener.ora Network Configuration File:/u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora

# Generated by Oracle configuration tools.

SID_LIST_LISTENER =

(SID_LIST =

(SID_DESC =

(GLOBAL_DBNAME = JASON1)

(ORACLE_HOME = / u01/app/oracle/product/11.2.0/dbhome_1)

(SID_NAME = JASON)

)

)

LISTENER =

(DESCRIPTION =

(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.1.99) (PORT = 1521))

)

ADR_BASE_LISTENER = / u01/app/oracle

[oracle@jason1 admin] $cat tnsnames.ora

# tnsnames.ora Network Configuration File:/u01/app/oracle/product/11.2.0/dbhome_1/network/admin/tnsnames.ora

# Generated by Oracle configuration tools.

JASON1 =

(DESCRIPTION =

(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.1.99) (PORT = 1521))

(CONNECT_DATA =

(SERVER = DEDICATED)

(SERVICE_NAME = JASON1)

)

)

JASON2 =

(DESCRIPTION =

(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.1.100) (PORT = 1521))

(CONNECT_DATA =

(SERVER = DEDICATED)

(SERVICE_NAME = JASON2)

)

)

[oracle@jason1 admin] $lsnrctl status

LSNRCTL for Linux: Version 11.2.0.4.0-Production on 20-JUL-201623:06:17

Copyright (c) 1991, 2013, Oracle. All rights reserved.

Connecting to (DESCRIPTION= (ADDRESS= (PROTOCOL=TCP) (HOST=jason1) (PORT=1521)

STATUS of the LISTENER

-

Alias LISTENER

Version TNSLSNRfor Linux: Version 11.2.0.4.0-Production

Start Date 20-JUL-2016 22:50:04

Uptime 0 days 0hr. 16 min. 13 sec

Trace Level off

Security ON:Local OS Authentication

SNMP OFF

Listener Parameter File / u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora

Listener Log File / u01/app/oracle/diag/tnslsnr/jason1/listener/alert/log.xml

Listening Endpoints Summary...

(DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=jason1) (PORT=1521))

Services Summary...

Service "JASON1" has 2 instance (s).

Instance "JASON", status UNKNOWN, has 1 handler (s) for this service...

Instance "JASON", status READY, has 1 handler (s) for this service...

Service "JASONXDB" has 1 instance (s).

Instance "JASON", status READY, has 1 handler (s) for this service...

The command completed successfully

[oracle@jason1 admin] $

6. Generate pfile files and synchronize the corresponding files to the standby library

Generate a pfile file in the main database.

SQL > create pfile from spfile

File created.

Synchronize the content under dbs to the standby host

[oracle@jason1 dbs] $pwd

/ u01/app/oracle/product/11.2.0/dbhome_1/dbs

[oracle@jason1 dbs] $scp initJASON.ora orapwJASON192.168.1.100:/u01/app/oracle/product/11.2.0/dbhome_1/dbs/

The authenticity of host '192.168.1.100 (192.168.1.100)' can't beestablished.

RSA key fingerprint is 25:ca:65:90:d3:30:fa:68:ed:11:64:b2:0e:b0:39:a7.

Are you sure you want to continue connecting (yes/no)? Yes

Warning: Permanently added '192.168.1.100' (RSA) to the list of knownhosts.

Oracle@192.168.1.100's password:

InitJASON.ora 10015 1.4KB/s 00:00

OrapwJASON 100% 1536 1.5KB/s 00:00

[oracle@jason1 dbs]

Third, prepare the library configuration 7. Create a corresponding directory

Create a related directory on the standby library

[oracle@jason2 oracle] $mkdir-p / u01/app/oracle/admin/JASON2/adump

[oracle@jason2 oracle] $mkdir-p / u01/app/oracle/admin/JASON/dpdump

[oracle@jason2 oracle] $mkdir-p / u01/app/oracle/admin/JASON/pfile

[oracle@jason2 oracle] $mkdir-p / u01/app/oracle/archivelog

[oracle@jason2 oracle] $mkdir-p / u01/app/oracle/oradata/JASON

[oracle@jason2 oracle] $mkdir-p / u01/app/oracle/fast_recovery_area

[oracle@jason2 oracle] $mkdir-p / u01/app/oracle/cfgtoollogs/catbundle

[oracle@jason2 oracle] $mkdir-p / u01/app/oracle/cfgtoollogs/dbca/JASON

[oracle@jason2 oracle] $mkdir-p / u01/app/oracle/cfgtoollogs/emca

[oracle@jason2 oracle] $mkdir-p / u01/app/oracle/cfgtoollogs/netca

[oracle@jason2 oracle] $ll

Total 32

Drwxr-xr-x 3 oracle oinstall 4096Jul 14 22:27 admin

Drwxr-xr-x 2 oracle oinstall 4096Jul 14 22:28 archivelog

Drwxr-xr-x 6 oracle oinstall 4096Jul 14 22:32 cfgtoollogs

Drwxr-xr-x 2 oracle oinstall 4096Jul 13 23:32 checkpoints

Drwxrwxr-x 11 oracle oinstall 4096 Jul 13 23:06 diag

Drwxr-xr-x 2 oracle oinstall 4096Jul 14 22:30 fast_recovery_area

Drwxr-xr-x 3 oracle oinstall 4096Jul 14 22:28 oradata

Drwxr-xr-x 3 oracle oinstall 4096Jul 13 21:37 product

[oracle@jason2 oracle] $

8. Prepare the library parameter file configuration

Modify the initial parameter file on the standby library, and the parameters required to configure DG are as follows.

JASON.__db_cache_size=75497472

JASON.__java_pool_size=4194304

JASON.__large_pool_size=71303168

JASON.__oracle_base='/u01/app/oracle'#ORACLE_BASE set from environment

JASON.__pga_aggregate_target=155189248

JASON.__sga_target=255852544

JASON.__shared_io_pool_size=0

JASON.__shared_pool_size=96468992

JASON.__streams_pool_size=0

* .audit_file_dest='/u01/app/oracle/admin/JASON2/adump'

* .audit_trail='db'

* .compatible='11.2.0.4.0'

* .control_files='/u01/app/oracle/oradata/JASON/control01.ctl','/u01/app/oracle/oradata/JASON/control02.ctl','/u01/app/oracle/oradata/JASON/control03.ctl'

* .db_block_size=8192

* .db_domain=''

* .db_name='JASON'

* .db_recovery_file_dest_size=4385144832

* .db_recovery_file_dest='/u01/app/oracle/fast_recovery_area'

* .log_file_name_convert='/u01/app/oracle/oradata/JASON','/u01/app/oracle/oradata/JASON'

* .db_unique_name='JASON2'

* .diagnostic_dest='/u01/app/oracle'

* .dispatchers=' (PROTOCOL=TCP) (SERVICE=JASONXDB)'

* .fal_server='JASON1'

* .log_archive_config='DG_CONFIG= (JASON1,JASON2)'

* .log_archive_dest_1='LOCATION=/u01/app/oracle/archivelog/VALID_FOR= (ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=JASON2'

* .log_archive_dest_2='SERVICE=JASON1 ASYNC VALID_FOR= (ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=JASON1'

* .log_archive_dest_state_1='ENABLE'

* .log_archive_dest_state_2='ENABLE'

* .log_archive_format='%t_%s_%r.dbf'

* .memory_target=411041792

* .open_cursors=300

* .processes=150

* .remote_login_passwordfile='EXCLUSIVE'

* .standby_file_management='AUTO'

* .undo_tablespace='UNDOTBS1

9. Configure snooping

Standby listening must be set to static snooping

[oracle@jason2 admin] $cat listener.ora

# listener.ora Network Configuration File:/u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora

# Generated by Oracle configuration tools.

SID_LIST_LISTENER =

(SID_LIST =

(SID_DESC =

(GLOBAL_DBNAME = JASON2)

(ORACLE_HOME = / u01/app/oracle/product/11.2.0/dbhome_1)

(SID_NAME = JASON)

)

)

LISTENER =

(DESCRIPTION =

(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.1.100) (PORT = 1521))

)

ADR_BASE_LISTENER = / u01/app/oracle

[oracle@jason2 admin] $cat tnsnames.ora

# tnsnames.ora Network Configuration File:/u01/app/oracle/product/11.2.0/dbhome_1/network/admin/tnsnames.ora

# Generated by Oracle configuration tools.

JASON1 =

(DESCRIPTION =

(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.1.99) (PORT = 1521))

(CONNECT_DATA =

(SERVER = DEDICATED)

(SERVICE_NAME = JASON1)

)

)

JASON2 =

(DESCRIPTION =

(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.1.100) (PORT = 1521))

(CONNECT_DATA =

(SERVER = DEDICATED)

(SERVICE_NAME = JASON2)

)

)

10. Create a spfile file

[oracle@jason2 dbs] $sqlplus / nolog

SQL*Plus: Release 11.2.0.4.0 Production on Thu Jul 14 23:07:22 2016

Copyright (c) 1982, 2013, Oracle. All rights reserved.

SQL > conn /

As sysdba

Connected to an idle instance.

SQL > startup nomount

ORACLE instance started.

Total System Global Area 409194496 bytes

Fixed Size 2253744 bytes

Variable Size 310381648 bytes

Database Buffers 92274688 bytes

Redo Buffers 4284416 bytes

SQL > create spfile from pfile

File created.

11. Create a standby library

Start the slave database to the nomount state, and then connect to the master library on the slave for duplicate operation.

SQL > shutdown immediate

ORA-01507: database not mounted

ORACLE instance shut down.

SQL > startup nomount

ORACLE instance started.

Total System Global Area 409194496 bytes

Fixed Size 2253744 bytes

Variable Size 310381648 bytes

Database Buffers 92274688 bytes

Redo Buffers 4284416 bytes

SQL > exit

Disconnected from Oracle Database 11g Enterprise Edition Release11.2.0.4.0-64bit Production

With the Partitioning, OLAP, Data Mining and Real Application Testingoptions

[oracle@jason2 ~] $lsnrctl status

LSNRCTL for Linux: Version 11.2.0.4.0-Production on 20-JUL-201623:04:56

Copyright (c) 1991, 2013, Oracle. All rights reserved.

Connecting to (DESCRIPTION= (ADDRESS= (PROTOCOL=TCP) (HOST=jason2) (PORT=1521)

STATUS of the LISTENER

-

Alias LISTENER

Version TNSLSNRfor Linux: Version 11.2.0.4.0-Production

Start Date 20-JUL-201622:50:42

Uptime 0 days 0hr. 14 min. 14 sec

Trace Level off

Security ON:Local OS Authentication

SNMP OFF

Listener Parameter File / u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora

Listener Log File / u01/app/oracle/diag/tnslsnr/jason2/listener/alert/log.xml

Listening Endpoints Summary...

(DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=jason2) (PORT=1521))

Services Summary...

Service "JASON2" has 2 instance (s).

Instance "JASON", status UNKNOWN, has 1 handler (s) for this service...

Instance "JASON", status BLOCKED, has 1 handler (s) for this service...

The command completed successfully

[oracle@jason2 ~] $rman targetsys/system@JASON1 auxiliary sys/system@JASON2

Recovery Manager: Release 11.2.0.4.0-Production on Thu Jul 21 00 purl 05purl 082016

Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.

Connected to target database: JASON (DBID=2141348976)

Connected to auxiliary database: JASON (not mounted)

RMAN > duplicate target database for standby nofilenamecheck fromactive database

Starting Duplicate Db at 21-JUL-16

Using target database control file instead of recovery catalog

Allocated channel: ORA_AUX_DISK_1

Channel ORA_AUX_DISK_1: SID=19 device type=DISK

Contents of Memory Script:

{

Backup as copy reuse

Targetfile'/ u01 targetfile'/ u01apapapwJASON' auxiliaryformat

'/ u01apapapwJASON'.' / u01apapapwJASON'

}

Executing Memory Script

Starting backup at 21-JUL-16

Allocated channel: ORA_DISK_1

Channel ORA_DISK_1: SID=40 device type=DISK

Finished backup at 21-JUL-16

Contents of Memory Script:

{

Backup as copy currentcontrolfile for standby auxiliary format'/ u01Gap appOnOnOnOnOnOnOnOnOnOnOnOnOnOnOnOnAction01.ctl'

Restore clone controlfileto'/ u01 from

'/ u01 apprenticeship oraclescarpJASONUniver control01.ctl'

Restore clone controlfileto'/ u01/app/oracle/oradata/JASON/control03.ctl'from

'/ u01 apprenticeship oraclescarpJASONUniver control01.ctl'

}

Executing Memory Script

Starting backup at 21-JUL-16

Using channel ORA_DISK_1

Channel ORA_DISK_1: starting datafile copy

Copying standby control file

Output file name=/u01/app/oracle/product/11.2.0/dbhome_1/dbs/snapcf_JASON.ftag=TAG20160721T000524 RECID=1 STAMP=917741125

Channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:03

Finished backup at 21-JUL-16

Starting restore at 21-JUL-16

Using channel ORA_AUX_DISK_1

Channel ORA_AUX_DISK_1: copied control file copy

Finished restore at 21-JUL-16

Starting restore at 21-JUL-16

Using channel ORA_AUX_DISK_1

Channel ORA_AUX_DISK_1: copied control file copy

Finished restore at 21-JUL-16

Contents of Memory Script:

{

Sql clone 'alter database mountstandby database'

}

Executing Memory Script

Sql statement: alter database mount standby database

Contents of Memory Script:

{

Set newname for tempfile 1 to

"/ u01/app/oracle/oradata/JASON/temp01.dbf"

Switch clone tempfile all

Set newname for datafile 1 to

"/ u01/app/oracle/oradata/JASON/system01.dbf"

Set newname for datafile 2 to

"/ u01/app/oracle/oradata/JASON/sysaux01.dbf"

Set newname for datafile 3 to

"/ u01/app/oracle/oradata/JASON/undotbs01.dbf"

Set newname for datafile 4 to

"/ u01/app/oracle/oradata/JASON/users01.dbf"

Backup as copy reuse

Datafile 1 auxiliary format

"/ u01/app/oracle/oradata/JASON/system01.dbf" datafile

2 auxiliary format

"/ u01/app/oracle/oradata/JASON/sysaux01.dbf" datafile

3 auxiliary format

"/ u01/app/oracle/oradata/JASON/undotbs01.dbf" datafile

4 auxiliary format

"/ u01/app/oracle/oradata/JASON/users01.dbf"

Sql 'alter system archive logcurrent'

}

Executing Memory Script

Executing command: SET NEWNAME

Renamed tempfile 1 to / u01/app/oracle/oradata/JASON/temp01.dbf incontrol file

Executing command: SET NEWNAME

Executing command: SET NEWNAME

Executing command: SET NEWNAME

Executing command: SET NEWNAME

Starting backup at 21-JUL-16

Using channel ORA_DISK_1

Channel ORA_DISK_1: starting datafile copy

Input datafile file number=00001name=/u01/app/oracle/oradata/JASON/system01.dbf

Output file name=/u01/app/oracle/oradata/JASON/system01.dbftag=TAG20160721T000536

Channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:38

Channel ORA_DISK_1: starting datafile copy

Input datafile file number=00002name=/u01/app/oracle/oradata/JASON/sysaux01.dbf

Output file name=/u01/app/oracle/oradata/JASON/sysaux01.dbf tag=TAG20160721T000536

Channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:27

Channel ORA_DISK_1: starting datafile copy

Input datafile file number=00003name=/u01/app/oracle/oradata/JASON/undotbs01.dbf

Output file name=/u01/app/oracle/oradata/JASON/undotbs01.dbftag=TAG20160721T000536

Channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:07

Channel ORA_DISK_1: starting datafile copy

Input datafile file number=00004name=/u01/app/oracle/oradata/JASON/users01.dbf

Output file name=/u01/app/oracle/oradata/JASON/users01.dbftag=TAG20160721T000536

Channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:01

Finished backup at 21-JUL-16

Sql statement: alter system archive log current

Contents of Memory Script:

{

Switch clone datafile all

}

Executing Memory Script

Datafile 1 switched to datafile copy

Input datafile copy RECID=1 STAMP=917741211 filename=/u01/app/oracle/oradata/JASON/system01.dbf

Datafile 2 switched to datafile copy

Input datafile copy RECID=2 STAMP=917741211 file name=/u01/app/oracle/oradata/JASON/sysaux01.dbf

Datafile 3 switched to datafile copy

Input datafile copy RECID=3 STAMP=917741211 filename=/u01/app/oracle/oradata/JASON/undotbs01.dbf

Datafile 4 switched to datafile copy

Input datafile copy RECID=4 STAMP=917741211 filename=/u01/app/oracle/oradata/JASON/users01.dbf

Finished Duplicate Db at 21-JUL-16

RMAN >

twelve。 Turn on ADG

Put the repository in active dataguard mode.

[oracle@jason2 ~] $sqlplus / nolog

SQL*Plus: Release 11.2.0.4.0 Production on Thu Jul 14 23:42:40 2016

Copyright (c) 1982, 2013, Oracle. All rights reserved.

SQL > conn / as sysdba

Connected.

SQL > alter database open

Database altered.

SQL > alter database recover managed standby database using currentlogfile disconnect from session

Database altered.

SQL > select open_mode,database_role,db_unique_name from v$database

OPEN_MODE DATABASE_ROLE DB_UNIQUE_NAME

READ ONLY WITH APPLY PHYSICAL STANDBY JASON2

SQL > select protection_mode,protection_level from v$database

PROTECTION_MODE PROTECTION_LEVEL

--

MAXIMUMPERFORMANCE MAXIMUMPERFORMANCE

SQL > select status from v$standby_log

STATUS

-

ACTIVE

UNASSIGNED

UNASSIGNED

UNASSIGNED

SQL > select group#,status,type,member from v$logfile

GROUP# STATUS TYPE MEMBER

3 ONLINE / u01/app/oracle/oradata/JASON/redo03.log

2 ONLINE / u01/app/oracle/oradata/JASON/redo02.log

1 ONLINE / u01/app/oracle/oradata/JASON/redo01.log

4 STANDBY/u01/app/oracle/oradata/JASON/standby01.log

5 STANDBY / u01/app/oracle/oradata/JASON/standby02.log

6 STANDBY/u01/app/oracle/oradata/JASON/standby03.log

7 STANDBY/u01/app/oracle/oradata/JASON/standby04.log

7 rows selected.

SQL >

View the database data file as follows:

[root@jason2 JASON] # ll

Total 1744852

-rw-r- 1 oracle oinstall 9748480 Jul 21 00:11 control01.ctl

-rw-r- 1 oracle oinstall 9748480 Jul 21 00:11 control02.ctl

-rw-r- 1 oracle oinstall 9748480 Jul 21 00:11 control03.ctl

-rw-r- 1 oracle oinstall 52429312 Jul 21 00:06 redo01.log

-rw-r- 1 oracle oinstall 52429312 Jul 21 00:06 redo02.log

-rw-r- 1 oracle oinstall 52429312 Jul 21 00:06 redo03.log

-rw-r- 1 oracle oinstall 52429312 Jul 21 00:11 standby01.log

-rw-r- 1 oracle oinstall 52429312 Jul 21 00:09 standby02.log

-rw-r- 1 oracle oinstall 52429312 Jul 21 00:07 standby03.log

-rw-r- 1 oracle oinstall 52429312 Jul 21 00:07 standby04.log

-rw-r- 1 oracle oinstall 534781952 Jul 21 00:09 sysaux01.dbf

-rw-r- 1 oracle oinstall 775954432 Jul 21 00:09 system01.dbf

-rw-r- 1 oracle oinstall 30416896 Jul 21 00:09 temp01.dbf

-rw-r- 1 oracle oinstall 73408512 Jul 21 00:09 undotbs01.dbf

-rw-r- 1 oracle oinstall 5251072 Jul 21 00:09 users01.dbf

[root@jason2 JASON] #

Main database view database status

SQL > select open_mode,database_role,db_unique_name from v$database

OPEN_MODE DATABASE_ROLE DB_UNIQUE_NAME

READ WRITE PRIMARY JASON1

SQL > select protection_mode,protection_level from v$database

PROTECTION_MODE PROTECTION_LEVEL

--

MAXIMUMPERFORMANCE MAXIMUMPERFORMANCE

Fourth, test 13. Master and standby database view log

Host switch log

[oracle@jason1 ~] $sqlplus / nolog

SQL*Plus: Release 11.2.0.4.0 Production on Thu Jul 2123:33:08 2016

Copyright (c) 1982, 2013, Oracle. All rights reserved.

SQL > conn / as sysdba

Connected.

SQL > alter system switch logfile

System altered.

SQL > /

System altered.

SQL > SELECT SEQUENCE#, FIRST_TIME, NEXT_TIME FROMV$ARCHIVED_LOG ORDER BY SEQUENCE#

SEQUENCE#FIRST_TIME NEXT_TIME

413-JUL-16 14-JUL-16

514-JUL-16 14-JUL-16

614-JUL-16 14-JUL-16

714-JUL-16 20-JUL-16

820-JUL-16 20-JUL-16

920-JUL-16 20-JUL-16

1020-JUL-16 20-JUL-16

1120-JUL-16 20-JUL-16

1220-JUL-16 21-JUL-16

1321-JUL-16 21-JUL-16

1421-JUL-16 21-JUL-16

SEQUENCE#FIRST_TIME NEXT_TIME

1421-JUL-16 21-JUL-16

1521-JUL-16 21-JUL-16

1521-JUL-16 21-JUL-16

1621-JUL-16 21-JUL-16

1621-JUL-16 21-JUL-16

1721-JUL-16 21-JUL-16

1721-JUL-16 21-JUL-16

1821-JUL-16 21-JUL-16

18 21-JUL-16 21-JUL-16

20 rows selected.

SQL > SELECT SEQUENCE#,APPLIED FROM V$ARCHIVED_LOGORDER BY SEQUENCE#

SEQUENCE# APPLIED

--

4 NO

5 NO

6 NO

7 NO

8 NO

9 NO

10 NO

11 NO

12 NO

13 NO

14 NO

SEQUENCE# APPLIED

--

14 YES

15 NO

15 YES

16 NO

16 YES

17 NO

17 YES

18 NO

18 NO

20 rows selected.

SQL >

Standby view

SQL > SELECT SEQUENCE#, FIRST_TIME, NEXT_TIME FROM V$ARCHIVED_LOGORDER BY SEQUENCE#

SEQUENCE#FIRST_TIME NEXT_TIME

1421-JUL-16 21-JUL-16

1521-JUL-16 21-JUL-16

1621-JUL-16 21-JUL-16

1721-JUL-16 21-JUL-16

1821-JUL-16 21-JUL-16

SQL > SELECT SEQUENCE#,APPLIED FROM V$ARCHIVED_LOGORDER BY SEQUENCE#

SEQUENCE# APPLIED

--

14 YES

15 YES

16 YES

17 YES

18IN-MEMORY

SQL >

14.switch_over test

Main library switch

SQL > SELECTSWITCHOVER_STATUS FROM V$DATABASE

SWITCHOVER_STATUS

-

TO STANDBY

SQL > ALTERDATABASE COMMIT TO SWITCHOVER TO PHYSICAL STANDBY WITH SESSION SHUTDOWN

Database altered.

SQL > SELECTSWITCHOVER_STATUS FROM V$DATABASE

SELECTSWITCHOVER_STATUS FROM V$DATABASE

*

ERROR at line 1:

ORA-01034: ORACLEnot available

Process ID: 2849

Session ID: 44Serial number: 27

SQL > startup

ORACLE instancestarted.

Total System GlobalArea 409194496 bytes

Fixed Size 2253744 bytes

Variable Size 322964560 bytes

DatabaseBuffers 79691776 bytes

Redo Buffers 4284416 bytes

Database mounted.

Database opened.

SQL > selectopen_mode,database_role,db_unique_name from v$database

OPEN_MODE DATABASE_ROLE DB_UNIQUE_NAME

READ ONLY PHYSICAL STANDBY JASON1

SQL > ALTERDATABASE RECOVER MANAGED STANDBY DATABASE USING CURRENT LOGFILE DISCONNECT FROMSESSION

Database altered.

SQL >

Reserve database switch

SQL > SELECTSWITCHOVER_STATUS FROM V$DATABASE

SWITCHOVER_STATUS

-

TO PRIMARY

SQL > ALTERDATABASE COMMIT TO SWITCHOVER TO PRIMARY WITH SESSION SHUTDOWN

Database altered.

SQL > selectopen_mode,database_role,db_unique_name from v$database

OPEN_MODE DATABASE_ROLE DB_UNIQUE_NAME

MOUNTED PRIMARY JASON2

SQL > alterdatabase open

Database altered.

SQL > selectopen_mode,database_role,db_unique_name from v$database

OPEN_MODE DATABASE_ROLE DB_UNIQUE_NAME

READ WRITE PRIMARY JASON2

SQL >

The host (original machine) views the log and switches

SQL > SELECT SEQUENCE#, FIRST_TIME, NEXT_TIME FROM V$ARCHIVED_LOGORDER BY SEQUENCE#

SEQUENCE# FIRST_TIME NEXT_TIME

14 21-JUL-16 21-JUL-16

15 21-JUL-16 21-JUL-16

16 21-JUL-16 21-JUL-16

17 21-JUL-16 21-JUL-16

18 21-JUL-16 21-JUL-16

19 21-JUL-16 21-JUL-16

20 21-JUL-16 21-JUL-16

20 21-JUL-16 21-JUL-16

21 21-JUL-16 21-JUL-16

21 21-JUL-16 21-JUL-16

10 rows selected.

SQL > alter system switch logfile

System altered.

SQL > /

System altered.

SQL > SELECT SEQUENCE#, FIRST_TIME, NEXT_TIME FROM V$ARCHIVED_LOGORDER BY SEQUENCE#

SEQUENCE# FIRST_TIME NEXT_TIME

14 21-JUL-16 21-JUL-16

15 21-JUL-16 21-JUL-16

16 21-JUL-16 21-JUL-16

17 21-JUL-16 21-JUL-16

18 21-JUL-16 21-JUL-16

19 21-JUL-16 21-JUL-16

20 21-JUL-16 21-JUL-16

20 21-JUL-16 21-JUL-16

21 21-JUL-16 21-JUL-16

21 21-JUL-16 21-JUL-16

22 21-JUL-16 21-JUL-16

SEQUENCE# FIRST_TIME NEXT_TIME

22 21-JUL-16 21-JUL-16

23 21-JUL-16 21-JUL-16

23 21-JUL-16 21-JUL-16

14 rows selected.

SQL >

View logs on standby database (original host)

SQL > SELECT SEQUENCE#, FIRST_TIME, NEXT_TIME FROM V$ARCHIVED_LOGORDER BY SEQUENCE#

SEQUENCE# FIRST_TIME NEXT_TIME

4 13-JUL-16 14-JUL-16

5 14-JUL-16 14-JUL-16

6 14-JUL-16 14-JUL-16

7 14-JUL-16 20-JUL-16

8 20-JUL-16 20-JUL-16

9 20-JUL-16 20-JUL-16

10 20-JUL-16 20-JUL-16

11 20-JUL-16 20-JUL-16

12 20-JUL-16 21-JUL-16

13 21-JUL-16 21-JUL-16

14 21-JUL-16 21-JUL-16

SEQUENCE# FIRST_TIME NEXT_TIME

14 21-JUL-16 21-JUL-16

15 21-JUL-16 21-JUL-16

15 21-JUL-16 21-JUL-16

16 21-JUL-16 21-JUL-16

16 21-JUL-16 21-JUL-16

17 21-JUL-16 21-JUL-16

17 21-JUL-16 21-JUL-16

18 21-JUL-16 21-JUL-16

18 21-JUL-16 21-JUL-16

19 21-JUL-16 21-JUL-16

19 21-JUL-16 21-JUL-16

SEQUENCE# FIRST_TIME NEXT_TIME

20 21-JUL-16 21-JUL-16

21 21-JUL-16 21-JUL-16

22 21-JUL-16 21-JUL-16

23 21-JUL-16 21-JUL-16

26 rows selected.

SQL > SELECT SEQUENCE#,APPLIED FROM V$ARCHIVED_LOG ORDER BY SEQUENCE#

SEQUENCE# APPLIED

--

4 YES

5 YES

6 YES

7 YES

8 YES

9 YES

10 YES

11 YES

12 YES

13 YES

14 YES

SEQUENCE# APPLIED

--

14 YES

15 YES

15 YES

16 YES

16 YES

17 YES

17 YES

18 YES

18 NO

19 YES

19 NO

SEQUENCE# APPLIED

--

20 YES

21 YES

22 YES

23 IN-MEMORY

26 rows selected.

SQL >

Fifth, error reporting 15. Error 1

On the slave server, add static registration information to the $GRID_HOME/network/listener.ora file

This is mainly because when the AUXILIARY instance starts to nomount state, listener cannot register the AUXILIARY instance, and listener will mark the Auxiliary instance as' blocked' status, so the duplicate command cannot connect to the Auxiliary instance through TNS. In order to solve this problem, you need to manually statically register the database instance to the listener. When the Data Guard configuration is complete, you can delete the statically registered configuration information

[oracle@jason2 dbs] $rman target sys/system@JASON_PD auxiliarysys/system@JASON_SD

Recovery Manager: Release 11.2.0.4.0-Production on Thu Jul 14 23 purl 1512016

Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.

Connected to target database: JASON (DBID=2141348976)

RMAN-00571: =

RMAN-00569: = ERROR MESSAGE STACK FOLLOWS =

RMAN-00571: =

RMAN-00554: initialization of internal recovery manager package failed

RMAN-04006: error from auxiliary database: ORA-12528: TNS:listener: allappropriate instances are blocking new connections

Set status after static snooping

[oracle@jason2 dbs] $lsnrctl status

LSNRCTL for Linux: Version 11.2.0.4.0-Production on 14-JUL-201623:15:50

Copyright (c) 1991, 2013, Oracle. All rights reserved.

Connecting to (DESCRIPTION= (ADDRESS= (PROTOCOL=TCP) (HOST=192.168.1.100) (PORT=1521)

STATUS of the LISTENER

-

Alias LISTENER

Version TNSLSNRfor Linux: Version 11.2.0.4.0-Production

Start Date 14-JUL-2016 22:41:05

Uptime 0 days 0hr. 34 min. 44 sec

Trace Level off

Security ON:Local OS Authentication

SNMP OFF

Listener Parameter File / u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora

Listener Log File / u01/app/oracle/diag/tnslsnr/jason2/listener/alert/log.xml

Listening Endpoints Summary...

(DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=192.168.1.100) (PORT=1521))

(DESCRIPTION= (ADDRESS= (PROTOCOL=ipc) (KEY=EXTPROC1521)

Services Summary...

Service "JASON2" has 1 instance (s).

Instance "JASON", status BLOCKED, has 1 handler (s) for this service...

The command completed successfully

[oracle@jason2 dbs] $

16. Error 2

(1) when the database flashback area is not set and the log_file_name_convert parameter is not set, the error in creating a slave database through rman is as follows.

ORACLE error from auxiliary database: ORA-19527: physical standby redolog must be renamed

ORA-00312: online log 1 thread 1 Vortex Greater U01App Uniplex oracleUniplex oradata Universe JASONGUDO 01.log'

RMAN-05535: WARNING: All redo log files were not defined properly.

ORACLE error from auxiliary database: ORA-19527: physical standby redolog must be renamed

ORA-00312: online log 2 thread 1 Flux Grey U01 Grey App Grey oracleGrease oradataUnique JASONUnique redo02.log'

RMAN-05535: WARNING: All redo log files were not defined properly.

ORACLE error from auxiliary database: ORA-19527: physical standby redolog must be renamed

ORA-00312: online log 3 thread 1:'/ u01 apprenticeship oradata Universe redo03.log'

RMAN-05535: WARNING: All redo log files were not defined properly.

ORACLE error from auxiliary database: ORA-19527: physical standby redolog must be renamed

ORA-00312: online log 4 thread 0:'/ u01 thread

RMAN-05535: WARNING: All redo log files were not defined properly.

ORACLE error from auxiliary database: ORA-19527: physical standby redolog must be renamed

ORA-00312: online log 5 thread 0vu01xapplet oracle.oradataplicJASONAction02.log'.

RMAN-05535: WARNING: All redo log files were not defined properly.

ORACLE error from auxiliary database: ORA-19527: physical standby redolog must be renamed

ORA-00312: online log 6 thread 0vu01max appplash oracle.oradataUnique JASONAccording

RMAN-05535: WARNING: All redo log files were not defined properly.

ORACLE error from auxiliary database: ORA-19527: physical standby redolog must be renamed

ORA-00312: online log 7 thread 0vu01applink oracle.oradataplicJASONAction04.log'

RMAN-05535: WARNING: All redo log files were not defined properly.

Finished Duplicate Db at 20-JUL-16

(2) when the database flash zone is set, when the log_file_name_convert parameter is not set, when the slave database is created through rman, the slave database will be created without error, but the online log and standby log will be created to the flash directory by default, as shown below.

SQL > select group#,status,type,member from v$logfile

GROUP# STATUS TYPE MEMBER

3 ONLINE / u01/app/oracle/fast_recovery_area/JASON2/onlinelog/o1_mf_3_crhdk13p_.log

2 ONLINE / u01/app/oracle/fast_recovery_area/JASON2/onlinelog/o1_mf_2_crhdjz7x_.log

1 ONLINE / u01/app/oracle/fast_recovery_area/JASON2/onlinelog/o1_mf_1_crhdjy6n_.log

4 STANDBY/u01/app/oracle/fast_recovery_area/JASON2/onlinelog/o1_mf_4_crhdk55y_.log

5 STANDBY / u01/app/oracle/fast_recovery_area/JASON2/onlinelog/o1_mf_5_crhdk6yo_.log

6 STANDBY/u01/app/oracle/fast_recovery_area/JASON2/onlinelog/o1_mf_6_crhdk9bh_.log

7 STANDBY/u01/app/oracle/fast_recovery_area/JASON2/onlinelog/o1_mf_7_crhdkcqy_.log

7 rows selected.

SQL >

Solution:

The above error in creating a repository using rman is due to the fact that the log_file_name_convert parameter is not specified. To solve the above errors, regardless of whether the log path of the master / slave database is the same or not, you need to add log_file_name_convert parameters to the master / slave database. If the flashback area exists or not, the online log and standby log will be automatically created to the database file directory.

Official information: the following is the official solution.

In order to speed up the switchover of the slave library and the main library, oracle has added an enhanced feature since 10.2, that is, it will clean up the online redo log on the standby library when MRP starts. There are two reasons for the above two errors. The first is that the slave database did not create an online redo log, and the second is that the slave database did not set the log_file_name_convert parameter.

What's New in https://blogs.oracle.com/Database4CN/entry/11g_ _ active_database_duplication1

Method # 1: if you do not consider switchover (do not create an online reod log on the standby database), you can ignore this error, because this error is only a suggestive information and will not affect the work of the MRP of preparing the library.

Method # 2: if switchover is considered, create an online reod log on the slave database and set the log_file_name_convert parameter:

SQL > shutdown immediate

SQL > startup mount

SQL > ALTER DATABASE ADD LOGFILE GROUP 4 ('+ DATA/redo01.log') SIZE52428800

SQL > ALTER DATABASE ADD LOGFILE GROUP 5 ('+ DATA/redo02.log') SIZE52428800

SQL > ALTER DATABASE ADD LOGFILE GROUP 6 ('+ DATA/redo03.log') SIZE52428800

SQL > alter system setlog_file_name_convert='/home/oracle/app/oradata/orcl','+data' scope=spfile

SQL > shutdown immediate

SQL > startup mount

SQL > ALTER DATABASE RECOVER MANAGED STANDBY DATABASE DISCONNECT FROMSESSION

17. Error 3

After rman created the standby database, the following error occurred when opening the database.

[oracle@jason2 ~] $sqlplus / nolog

SQL*Plus: Release 11.2.0.4.0 Production on Thu Jul 21 22:02:15 2016

Copyright (c) 1982, 2013, Oracle. All rights reserved.

SQL > conn / as sysdba

Connected.

SQL > alter database open

Alter database open

*

ERROR at line 1:

ORA-10458: standby database requires recovery

ORA-01152: file 1 was not restored from a sufficiently old backup

ORA-01110: data file 1:'/ u01 *

SQL > exit

Solution:

The above problem is caused by the inconsistency between the log scn and the control file. The log in the main database has not been sent to the standby machine in time, which leads to the failure of database startup. After waiting for a few minutes, the log transfer process can be observed in the warning logs of the main database and standby database, and the real-time log application can be opened in the open database after the transfer is completed. Or add the parameter dorecover to create a standby database, then open the database and open the log real-time application.

Main library:

Thu Jul 21 22:21:32 2016

PING [ARC2]: Heartbeat failed to connect to standby 'JASON2'. Error is16058.

16058Thu Jul 21 22:22:32 2016

PING [ARC2]: Heartbeat failed to connect to standby 'JASON2'. Error is16058.

Thu Jul 21 22:23:32 2016

PING [ARC2]: Heartbeat failed to connect to standby 'JASON2'. Error is16058.

Thu Jul 21 22:23:59 2016

Clearing standby activation ID 2141358704 (0x7fa28a70)

The primary database controlfile was created using the

'MAXLOGFILES 16 'clause.

There is space for up to 13 standby redo logfiles

Use the following SQL commands on the standby database to create

Standby redo logfiles that match the primary database:

ALTER DATABASE ADD STANDBY LOGFILE 'srl1.f' SIZE 52428800

ALTER DATABASE ADD STANDBY LOGFILE 'srl2.f' SIZE 52428800

ALTER DATABASE ADD STANDBY LOGFILE 'srl3.f' SIZE 52428800

ALTER DATABASE ADD STANDBY LOGFILE 'srl4.f' SIZE 52428800

Thu Jul 21 22:24:11 2016

Using STANDBY_ARCHIVE_DEST parameter default value as/u01/app/oracle/archivelog/

ALTER SYSTEM SET log_archive_dest_state_2='ENABLE' SCOPE=MEMORY SID='*'

Thu Jul 21 22:24:11 2016

PING [ARC2]: Heartbeat failed to connect to standby 'JASON2'. Error is16058.

Thu Jul 21 22:24:13 2016

Thread 1 advanced to log sequence 15 (LGWR switch)

Current log# 3 seq# 15 mem# 0:/u01/app/oracle/oradata/JASON/redo03.log

Thu Jul 21 22:24:14 2016

Archived Log entry 11 added for thread 1 sequence 14 ID 0x7fa28a70 dest1:

Thu Jul 21 22:25:43 2016

ALTER SYSTEM ARCHIVE LOG

Thu Jul 21 22:25:43 2016

Thread 1 advanced to log sequence 16 (LGWR switch)

Current log# 1 seq# 16 mem# 0:/u01/app/oracle/oradata/JASON/redo01.log

Archived Log entry 12 added for thread 1 sequence 15 ID 0x7fa28a70 dest1:

Thu Jul 21 22:29:35 2016

Thread 1 advanced to log sequence 17 (LGWR switch)

Current log# 2 seq# 17 mem# 0:/u01/app/oracle/oradata/JASON/redo02.log

Thu Jul 21 22:29:35 2016

Archived Log entry 15 added for thread 1 sequence 16 ID0x7fa28a70 dest 1:

Thu Jul 21 22:29:35 2016

ARC0: Standby redo logfile selected for thread 1 sequence 16for destination LOG_ARCHIVE_DEST_2

Thu Jul 21 22:29:35 2016

*

LGWR: Setting 'active' archival for destinationLOG_ARCHIVE_DEST_2

*

LNS: Standby redo logfile selected for thread 1 sequence 17for destination LOG_ARCHIVE_DEST_2

Thu Jul 21 22:38:19 2016

ALTER SYSTEM SET log_archive_dest_state_2='ENABLE'SCOPE=MEMORY SID='*'

Prepare the library:

RFS connections are allowed

Thu Jul 21 22:29:23 2016

RFS [1]: Assigned to RFS process 3455

RFS [1]: Opened log for thread 1 sequence 15 dbid 2141348976branch 917134706

Thu Jul 21 22:29:23 2016

RFS [2]: Assigned to RFS process 3457

RFS [2]: Opened log for thread 1 sequence 14 dbid 2141348976branch 917134706

Archived Log entry 1 added for thread 1 sequence 15 rlc917134706 ID 0x7fa28a70 dest 2:

Archived Log entry 2 added for thread 1 sequence 14 rlc917134706 ID 0x7fa28a70 dest 2:

RFS [1]: Selected log 4 for thread 1 sequence 16 dbid2141348976 branch 917134706

Thu Jul 21 22:29:26 2016

Primary database is in MAXIMUM PERFORMANCE mode

Re-archiving standby log 4 thread 1 sequence 16

Thu Jul 21 22:29:26 2016

Archived Log entry 3 added for thread 1 sequence 16 ID0x7fa28a70 dest 1:

RFS [3]: Assigned to RFS process 3459

RFS [3]: Selected log 4 for thread 1 sequence 17 dbid 2141348976branch 917134706

Thu Jul 21 22:33:31 2016

Db_recovery_file_dest_size of 4182 MB is 0.005% used. This is a

User-specified limit on the amount of space that will be usedby this

Database for recovery-related files, and does not reflect theamount of

Space available in the underlying filesystem or ASM diskgroup.

Note: after the slave starts to copy and create the slave database through rman, the master / slave log is as follows when adg is enabled for the slave. You can see from the log that the temporary table space of the slave database and log slave database will be automatically cleared and re-created when opened.

Main library log

Thu Jul 21 22:21:32 2016

PING [ARC2]: Heartbeat failed to connect to standby 'JASON2'. Error is16058.

16058Thu Jul 21 22:22:32 2016

PING [ARC2]: Heartbeat failed to connect to standby 'JASON2'. Error is16058.

Thu Jul 21 22:23:32 2016

PING [ARC2]: Heartbeat failed to connect to standby 'JASON2'. Error is16058.

Thu Jul 21 22:23:59 2016

Clearing standby activation ID 2141358704 (0x7fa28a70)

The primary database controlfile was created using the

'MAXLOGFILES 16 'clause.

There is space for up to 13 standby redo logfiles

Use the following SQL commands on the standby database to create

Standby redo logfiles that match the primary database:

ALTER DATABASE ADD STANDBY LOGFILE 'srl1.f' SIZE 52428800

ALTER DATABASE ADD STANDBY LOGFILE 'srl2.f' SIZE 52428800

ALTER DATABASE ADD STANDBY LOGFILE 'srl3.f' SIZE 52428800

ALTER DATABASE ADD STANDBY LOGFILE 'srl4.f' SIZE 52428800

Thu Jul 21 22:24:11 2016

Using STANDBY_ARCHIVE_DEST parameter default value as/u01/app/oracle/archivelog/

ALTER SYSTEM SET log_archive_dest_state_2='ENABLE' SCOPE=MEMORY SID='*'

Thu Jul 21 22:24:11 2016

PING [ARC2]: Heartbeat failed to connect to standby 'JASON2'. Error is16058.

Thu Jul 21 22:24:13 2016

Thread 1 advanced to log sequence 15 (LGWR switch)

Current log# 3 seq# 15 mem# 0:/u01/app/oracle/oradata/JASON/redo03.log

Thu Jul 21 22:24:14 2016

Archived Log entry 11 added for thread 1 sequence 14 ID 0x7fa28a70 dest1:

Thu Jul 21 22:25:43 2016

ALTER SYSTEM ARCHIVE LOG

Thu Jul 21 22:25:43 2016

Thread 1 advanced to log sequence 16 (LGWR switch)

Current log# 1 seq# 16 mem# 0:/u01/app/oracle/oradata/JASON/redo01.log

Archived Log entry 12 added for thread 1 sequence 15 ID 0x7fa28a70 dest1:

Thu Jul 21 22:29:35 2016

Thread 1 advanced to log sequence 17 (LGWR switch)

Current log# 2 seq# 17 mem# 0:/u01/app/oracle/oradata/JASON/redo02.log

Thu Jul 21 22:29:35 2016

Archived Log entry 15 added for thread 1 sequence 16 ID 0x7fa28a70 dest1:

Thu Jul 21 22:29:35 2016

ARC0: Standby redo logfile selected for thread 1 sequence 16 fordestination LOG_ARCHIVE_DEST_2

Thu Jul 21 22:29:35 2016

*

LGWR: Setting 'active' archival for destination LOG_ARCHIVE_DEST_2

*

LNS: Standby redo logfile selected for thread 1 sequence 17 fordestination LOG_ARCHIVE_DEST_2

Thu Jul 21 22:38:19 2016

ALTER SYSTEM SET log_archive_dest_state_2='ENABLE' SCOPE=MEMORY SID='*'

Prepare database log

Thu Jul 21 22:21:22 2016

Using STANDBY_ARCHIVE_DEST parameter default value as/u01/app/oracle/archivelog/

Destination database instance is' started' not 'mounted'

Thu Jul 21 22:22:22 2016

Destination database instance is' started' not 'mounted'

Thu Jul 21 22:23:22 2016

Destination database instance is' started' not 'mounted'

Thu Jul 21 22:23:55 2016

RFS connections have been disallowed

Alter database mount standby database

Set as converted control file due to db_unique_name mismatch

Changing di2dbun from JASON1 to JASON2

ARCH: STARTING ARCH PROCESSES

Thu Jul 21 22:23:59 2016

ARC0 started with pid=22, OS id=3413

ARC0: Archival started

ARCH: STARTING ARCH PROCESSES COMPLETE

ARC0: STARTING ARCH PROCESSES

Thu Jul 21 22:24:00 2016

Successful mount of redo thread 1, with mount id 2142020603

Physical Standby Database mounted.

Lost write protection disabled

Thu Jul 21 22:24:00 2016

ARC1 started with pid=23, OS id=3415

Thu Jul 21 22:24:00 2016

ARC2 started with pid=24, OS id=3417

ARC1: Archival started

ARC2: Archival started

ARC1: Becoming the'no FAL' ARCH

ARC2: Becoming the heartbeat ARCH

ARC2: Becoming the active heartbeat ARCH

Thu Jul 21 22:24:00 2016

ARC3 started with pid=25, OS id=3419

Create Relation IPS_PACKAGE_UNPACK_HISTORY

Completed: alter database mount standby database

ARC3: Archival started

ARC0: STARTING ARCH PROCESSES COMPLETE

Errors in file / u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_lgwr_3342.trc:

ORA-00313: open failed for members of log group 1 of thread 1

ORA-00312: online log 1 thread 1 Vortex Greater U01App Uniplex oracleUniplex oradata Universe JASONGUDO 01.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_lgwr_3342.trc:

ORA-00313: open failed for members of log group 1 of thread 1

ORA-00312: online log 1 thread 1 Vortex Greater U01App Uniplex oracleUniplex oradata Universe JASONGUDO 01.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_lgwr_3342.trc:

ORA-00313: open failed for members of log group 2 of thread 1

ORA-00312: online log 2 thread 1 Flux Grey U01 Grey App Grey oracleGrease oradataUnique JASONUnique redo02.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_lgwr_3342.trc:

ORA-00313: open failed for members of log group 2 of thread 1

ORA-00312: online log 2 thread 1 Flux Grey U01 Grey App Grey oracleGrease oradataUnique JASONUnique redo02.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_lgwr_3342.trc:

ORA-00313: open failed for members of log group 3 of thread 1

ORA-00312: online log 3 thread 1 Flux Grey U01 Grey App Grey oracleGrease oradataUnique JASONUnique redo03.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_lgwr_3342.trc:

ORA-00313: open failed for members of log group 3 of thread 1

ORA-00312: online log 3 thread 1:'/ u01 apprenticeship oradata Universe redo03.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_lgwr_3342.trc:

ORA-00313: open failed for members of log group 4 of thread 0

ORA-00312: online log 4 thread 0VOUGU01AULAGU1Applet oracle.oradataUniJASONandJASBY 01.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file / u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_lgwr_3342.trc:

ORA-00313: open failed for members of log group 4 of thread 0

ORA-00312: online log 4 thread 0VOUGU01AULAGU1Applet oracle.oradataUniJASONandJASBY 01.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_lgwr_3342.trc:

ORA-00313: open failed for members of log group 5 of thread 0

ORA-00312: online log 5 thread 0:'/ u01 thread

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_lgwr_3342.trc:

ORA-00313: open failed for members of log group 5 of thread 0

ORA-00312: online log 5 thread 0vu01xapplet oracle.oradataplicJASONAction02.log'.

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file / u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_lgwr_3342.trc:

ORA-00313: open failed for members of log group 6 of thread 0

ORA-00312: online log 6 thread 0vu01max appplash oracle.oradataUnique JASONAccording

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_lgwr_3342.trc:

ORA-00313: open failed for members of log group 6 of thread 0

ORA-00312: online log 6 thread 0:'/ u01 thread

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_lgwr_3342.trc:

ORA-00313: open failed for members of log group 7 of thread 0

ORA-00312: online log 7 thread 0vu01applink oracle.oradataplicJASONAction04.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file / u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_lgwr_3342.trc:

ORA-00313: open failed for members of log group 7 of thread 0

ORA-00312: online log 7 thread 0vu01applink oracle.oradataplicJASONAction04.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Thu Jul 21 22:24:07 2016

Warning: VKTM detected a time drift.

Time drifts can result in an unexpected behavior such as time-outs.Please check trace file for more details.

Thu Jul 21 22:25:35 2016

Switch of datafile 1 complete to datafile copy

Checkpoint is 1024464

Switch of datafile 2 complete to datafile copy

Checkpoint is 1024513

Switch of datafile 3 complete to datafile copy

Checkpoint is 1024548

Switch of datafile 4 complete to datafile copy

Checkpoint is 1024554

Alter database clear logfile group 1

Clearing online log 1 of thread 1 sequence number 13

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_ora_3399.trc:

ORA-00313: open failed for members of log group 1 of thread 1

ORA-00312: online log 1 thread 1 Vortex Greater U01App Uniplex oracleUniplex oradata Universe JASONGUDO 01.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file / u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_ora_3399.trc:

ORA-00313: open failed for members of log group 1 of thread 1

ORA-00312: online log 1 thread 1 Vortex Greater U01App Uniplex oracleUniplex oradata Universe JASONGUDO 01.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Completed: alter database clear logfile group 1

Alter database clear logfile group 2

Clearing online log 2 of thread 1 sequence number 14

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_ora_3399.trc:

ORA-00313: open failed for members of log group 2 of thread 1

ORA-00312: online log 2 thread 1 Flux Grey U01 Grey App Grey oracleGrease oradataUnique JASONUnique redo02.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file / u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_ora_3399.trc:

ORA-00313: open failed for members of log group 2 of thread 1

ORA-00312: online log 2 thread 1 Flux Grey U01 Grey App Grey oracleGrease oradataUnique JASONUnique redo02.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Completed: alter database clear logfile group 2

Alter database clear logfile group 3

Clearing online log 3 of thread 1 sequence number 12

Errors in file / u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_ora_3399.trc:

ORA-00313: open failed for members of log group 3 of thread 1

ORA-00312: online log 3 thread 1 Flux Grey U01 Grey App Grey oracleGrease oradataUnique JASONUnique redo03.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_ora_3399.trc:

ORA-00313: open failed for members of log group 3 of thread 1

ORA-00312: online log 3 thread 1 Flux Grey U01 Grey App Grey oracleGrease oradataUnique JASONUnique redo03.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Completed: alter database clear logfile group 3

Alter database clear logfile group 4

Clearing online log 4 of thread 0 sequence number 0

Errors in file / u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_ora_3399.trc:

ORA-00313: open failed for members of log group 4 of thread 0

ORA-00312: online log 4 thread 0VOUGU01AULAGU1Applet oracle.oradataUniJASONandJASBY 01.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_ora_3399.trc:

ORA-00313: open failed for members of log group 4 of thread 0

ORA-00312: online log 4 thread 0:'/ u01 thread

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Completed: alter database clear logfile group 4

Alter database clear logfile group 5

Clearing online log 5 of thread 0 sequence number 0

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_ora_3399.trc:

ORA-00313: open failed for members of log group 5 of thread 0

ORA-00312: online log 5 thread 0vu01xapplet oracle.oradataplicJASONAction02.log'.

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_ora_3399.trc:

ORA-00313: open failed for members of log group 5 of thread 0

ORA-00312: online log 5 thread 0vu01xapplet oracle.oradataplicJASONAction02.log'.

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Thu Jul 21 22:25:46 2016

Completed: alter database clear logfile group 5

Alter database clear logfile group 6

Clearing online log 6 of thread 0 sequence number 0

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_ora_3399.trc:

ORA-00313: open failed for members of log group 6 of thread 0

ORA-00312: online log 6 thread 0vu01max appplash oracle.oradataUnique JASONAccording

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file / u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_ora_3399.trc:

ORA-00313: open failed for members of log group 6 of thread 0

ORA-00312: online log 6 thread 0vu01max appplash oracle.oradataUnique JASONAccording

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Completed: alter database clear logfile group 6

Alter database clear logfile group 7

Clearing online log 7 of thread 0 sequence number 0

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_ora_3399.trc:

ORA-00313: open failed for members of log group 7 of thread 0

ORA-00312: online log 7 thread 0vu01applink oracle.oradataplicJASONAction04.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file / u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_ora_3399.trc:

ORA-00313: open failed for members of log group 7 of thread 0

ORA-00312: online log 7 thread 0vu01applink oracle.oradataplicJASONAction04.log'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Completed: alter database clear logfile group 7

RFS connections are allowed

Thu Jul 21 22:29:23 2016

RFS [1]: Assigned to RFS process 3455

RFS [1]: Opened log for thread 1 sequence 15 dbid 2141348976 branch917134706

Thu Jul 21 22:29:23 2016

RFS [2]: Assigned to RFS process 3457

RFS [2]: Opened log for thread 1 sequence 14 dbid 2141348976 branch917134706

Archived Log entry 1 added for thread 1 sequence 15 rlc 917134706 ID0x7fa28a70 dest 2:

Archived Log entry 2 added for thread 1 sequence 14 rlc 917134706 ID0x7fa28a70 dest 2:

RFS [1]: Selected log 4 for thread 1 sequence 16 dbid 2141348976 branch917134706

Thu Jul 21 22:29:26 2016

Primary database is in MAXIMUM PERFORMANCE mode

Re-archiving standby log 4 thread 1 sequence 16

Thu Jul 21 22:29:26 2016

Archived Log entry 3 added for thread 1 sequence 16 ID 0x7fa28a70 dest1:

RFS [3]: Assigned to RFS process 3459

RFS [3]: Selected log 4 for thread 1 sequence 17 dbid 2141348976 branch917134706

Thu Jul 21 22:33:31 2016

Db_recovery_file_dest_size of 4182 MB is 0.005% used. This is a

User-specified limit on the amount of space that will be used by this

Database for recovery-related files, and does not reflect the amount of

Space available in the underlying filesystem or ASM diskgroup.

Thu Jul 21 22:38:09 2016

Alter database open

AUDIT_TRAIL initialization parameter is changed to OS, as DB is NOTcompatible for database opened with read-only access

Signalling error 1152 for datafile 1!

Beginning Standby Crash Recovery.

Serial Media Recovery started

Managed Standby Recovery starting Real Time Apply

Media Recovery Log / u01/app/oracle/archivelog/1_14_917134706.dbf

Media Recovery Log / u01/app/oracle/archivelog/1_15_917134706.dbf

Incomplete Recovery applied until change 1024554 time 07/21/201622:25:42

Completed Standby Crash Recovery.

Thu Jul 21 22:38:10 2016

SMON: enabling cache recovery

Dictionary check beginning

Thu Jul 21 22:38:12 2016

Errors in file / u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_dbw0_3340.trc:

ORA-01157: cannot identify/lock data file 201-see DBWR trace file

ORA-01110: data file 201:'/ u01Applicable oradataUniple JASONUnip temp01.dbf'

ORA-27037: unable to obtain file status

Linux-x86_64 Error: 2: No such file or directory

Additional information: 3

Errors in file/u01/app/oracle/diag/rdbms/jason2/JASON/trace/JASON_dbw0_3340.trc:

ORA-01186: file 201 failed verification tests

ORA-01157: cannot identify/lock data file 201-see DBWR trace file

ORA-01110: data file 201:'/ u01Applicable oradataUniple JASONUnip temp01.dbf'

File 201 not verified due to error ORA-01157

Dictionary check complete

Re-creating tempfile / u01/app/oracle/oradata/JASON/temp01.dbf

Database Characterset is ZHS16GBK

No Resource Manager plan active

* * *

WARNING: Files may exists in db_recovery_file_dest

That are not known to the database. Use the RMAN command

CATALOG RECOVERY AREA to re-catalog any such files.

If files cannot be cataloged, then manually delete them

Using OS command.

One of the following events caused this:

1. A backup controlfile was restored.

2. A standby controlfile was restored.

3. The controlfile was re-created.

4. Db_recovery_file_dest had previously been enabled and

Then disabled.

* * *

Replication_dependency_tracking turned off (no async multimasterreplication found)

Physical standby database opened for read only access.

Completed: alter database open

Thu Jul 21 23:12:52 2016

Alter database recover managedstandby database using current logfile disconnect from session

Attempt to start background Managed Standby Recovery process (JASON)

Thu Jul 21 23:12:53 2016

MRP0 started with pid=28, OS id=3602

MRP0: Background Managed Standby Recovery process started (JASON)

Serial Media Recovery started

Managed Standby Recovery starting Real Time Apply

Waiting for all non-current ORLs to be archived...

All non-current ORLs have been archived.

Media Recovery Log / u01/app/oracle/archivelog/1_15_917134706.dbf

Media Recovery Log / u01/app/oracle/archivelog/1_16_917134706.dbf

Media Recovery Waiting for thread 1 sequence 17 (in transit)

Recovery of Online Redo Log: Thread 1 Group 4 Seq 17 Reading mem 0

Mem# 0:/u01/app/oracle/oradata/JASON/standby01.log

Completed: alter database recovermanaged standby database using current logfile disconnect from session

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report