Far Sync Standby 能不能支持 max protection

2023-11-30 21:30

本文主要是介绍Far Sync Standby 能不能支持 max protection,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

GOAL

 This Note explains the new Standby Type Far Sync Standby

SOLUTION

Far Sync Standby Database:

A Far Sync Standby Database is a cascading Standby Database which acts as a Redo Log Repository for a Terminal Database. It does not contain any datafiles. Only Log Transport Services are active on a Far Sync Standby Database. The Advantage of a Far Sync Standby Database is that it can be a local ArchiveLog Repository for the Primary Database acting in Maximum Availability Mode where the Physical or Logical Standby Database can be on a far remote Site. 

Creating a Far Sync Standby Instance 

You can prepare your Environment for a Far Sync Instance the same Way like for a Physical Standby Database, see

Note 1475344.1 Creating a Physical Standby Database on Oracle 11.2.0.x

-> Preparing the Environment and Standby Instance

for an Example.

Instead of a Physical Standby Controlfile we are creating a Far Sync Standby Controlfile from the Primary Database and use this Controlfile to mount the Far Sync Instance:

SQL> alter database create far sync instance controlfile as ‘<File Specification>’;

 You can then setup Log Transport Services to the Cascaded Standby just like for normal Cascaded Standby Databases. 

Data Guard Broker and Far Sync Standby Database 

The Data Guard Broker also supports Far Sync Standby Databases and Cascaded Standby Databases. You can add a Far Sync Standby to your Data Guard Broker Configuration using

DGMGRL> add far_sync <Name> as connect identifier is <Connect Identifier>;

 Then set the Data Guard Broker Property ‘RedoRoutes’ for the Databases accordingly. You can find an Explanation about ‘RedoRoutes’ in

Note 1542969.1 Cascaded Standby Databases in Oracle 12c

Technical Briefs:

Oracle Active Data Guard Far Sync Zero Data Loss at Any Distance
https://www.oracle.com/technetwork/database/availability/farsync-2267608.pdf

REFERENCES

NOTE:1475344.1 - Creating a Physical Standby Database
NOTE:1578787.1 - 12c Data guard Switchover Best Practices using SQLPLUS
NOTE:1582837.1 - 12c Dataguard Switchover Best Practices using DGMGRL(Dataguard Broker Command Prompt)
NOTE:1542969.1 - Cascaded Standby Databases in Oracle 12c

PURPOSE

 This Documents explains the Enhancements for Cascaded Standby Databases in Oracle 12c.

DETAILS

There are new Possibilities for cascading Standby Databases in Oracle 12c. The main Differents between Oracle 12c and the previous Releases are:

  1. Real-Time Cascading
  2. Far Sync Standby Database
  3. Data Guard Broker now supports cascaded Standby Database

However, you can still only cascade a Standby Database from a Physical Standby Database. It is not supported to cascade a Standby Database from a Logical Standby Database.

Real-Time Cascading

It is now possible to forward Redo in Real-Time Mode from the first to the cascaded Standby Database. So the Redo Record is forwarded to the cascaded Standby Database once written into a Standby RedoLog of the first Standby Database.

Non Real-Time Cascading means that the whole Log Sequence is transferred to the terminal Standby Database(s) after a Log Switch on the Primary Database.

Prerequisites

  • First (Cascading) Standby must be a Physical or Far Sync Standby Database
  • Standby RedoLogs must be in Place and used at least on the Cascading Standby Database
  • Active Data Guard Option must be licensed
  • Primary, Cascading and Cascaded Standby Database db_unique_name must be present in the dg_config of log_archive_config on all the Databases

Setup

First of all setup a Data Guard Environment as usual to the cascading Standby Database. The Log Transport Method should be ‘SYNC’ and Standby RedoLogs must be configured on the cascading Standby Database. Once you created the cascaded Standby Database you can now setup the cascading Log Transport Services. Here are some Hints for correct Setup:

  • Primary, Cascading and Cascaded Standby Database db_unique_name must be present in the dg_config of log_archive_config on all the Databases
  • Setup log_archive_dest_n on the cascading Standby Database to serve the cascaded (terminal) Standby Databases using the Attribute ‘valid_for=(STANDBY_LOGFILES,STANDBY_ROLE)’
  • You can toggle between Real-Time and Non Real-Time Cascading using the Log Transport Method.

ASYNC = Real-Time Cascading

SYNC = Non Real-Time Cascading

  • You can only use log_archive_dest_1 until log_archive_dest_10 for Non Real-Time Cascading Destinations where all log_archive_dest_n’s can be used for Real-Time Cascading on the Cascading Standby Database
  • The Cascading Standby Standby can be in any Protection Mode
  • A Cascading Standby Database can serve one or multiple terminal Standby Databases
  • FAL_SERVER on the cascading Standby Database should be set to the Primary or any other Standby Database served by the Primary Database directly
  • FAL_SERVER on the terminal Standby Database should be set to the cascading Standby Database or the Primary Database

Far Sync Standby Database

A Far Sync Standby Database is a cascading Standby Database which acts as a Redo Log Repository for a Terminal Database. It does not contain any Datafiles. Only Log Transport Services are active on a Far Sync Standby Database. The Advantage of a Far Sync Standby Database is that it can be a local ArchiveLog Repository for the Primary Database acting in Maximum Protection Mode where the Physical or Logical Standby Database can be on a far remote Site. See

Note 1565071.1: Data Guard 12c New Feature: Far Sync Standby

for further Details and Setup of a Far Sync Standby Database.

Data Guard Broker and Cascaded Standby Database

There is a new Data Guard Broker Property called ‘RedoRoutes’ used to build and implement a cascaded Data Guard Broker Configuration. It has the following Format:

RedoRoutes = ‘(<Redo Source> : <Redo Destination>)’

Redo Source: This is the Source the Redo is coming from. It can be a db_unique_name or the ‘LOCAL’-Keyword which is an Alias for the local Database Name (Cannot be used for a Far Sync Standby Database)

Redo Destination: This is the Destination where the Redo is shipped to from this Database. It can be one or more (comma separated) db_unique_name’s or the ‘ALL’-Keyword which is an Alias for all possible Destinations inside the Data Guard Broker Configuration. Optional you can also specify the Transport Method to be used to the Destination. This can be

  • SYNC:                   corresponds to log_archive_dest_n Attributes ‘SYNC AFFIRM’ or Non Real Time Cascade
  • ASYNC:                corresponds to log_archive_dest_n Attribute ‘ASYNC’ or Real Time Cascade
  • FASTSYNC :        corresponds to log_archive_dest_n Attributes ‘SYNC NOAFFIRM’

Example:

NOTE: In the images and/or the document content below, the user information and environment data used represents fictitious data from the
Oracle sample schema(s), Public Documentation delivered with an Oracle database product or other training material. Any similarity to actual
environments, actual persons, living or dead, is purely coincidental and not intended in any manner.

For the purposes of this document, the following fictitious environment is used as an example to describe the procedure:

Primary Database:                               prim
Cascading Standby Database:               local_stdby
Cascaded (terminal) Standby Database: remote_stdby

We want to serve the local Standby Database with ‘SYNC NOAFFIRM’ and the remote Standby Database in Real-Time Cascade Mode. So the setting would be:

Primary Database (prim)

RedoRoutes = ‘(LOCAL : local_stdby FASTSYNC)’

 -> So the Primary Database only ships Redo to the local Standby Database, but has Archive Destination to the remote Standby Database

Local Standby Database (local_stdby)

RedoRoutes = ‘(prim : remote_stdby ASYNC)’

 -> Here we configure that the Redo coming from ‘prim’ is forwarded in Real-Time Cascade (ASYNC) to the remote Standby Database

---------------far sync 配置

PURPOSE

 Use of the terminal standby as an alternate destination in a Far Sync configuration requires accepting that, provided the terminal standby database is not within acceptable sync network range, the configuration will run in asynchronous mode during the entire period required to resolve the Far Sync instance outage.  The advantage of this approach is that it requires no additional hardware or software to deploy or manage.  Applications that can tolerate increased data loss potential during a Far Sync instance outage and where low cost is the main consideration may be best served by configuring the terminal standby as an alternate location using ASYNC redo transport.

SCOPE

APPLIES TO:

Oracle Database versions 12.1.0.1 and 12.1.0.2

Active Data Guard Far Sync 

Data Guard Broker

Data Guard Role Transitions

DETAILS

Using the terminal standby database as an alternate of a far sync instance can result in the following errors when attempting a role transition using Oracle Data Guard Broker.

DGMGRL> switchover to standbyDB;
Performing switchover NOW, please wait...
Error: ORA-16778: redo transport error for one or more databases

Failed.
Unable to switchover, primary database is still "primaryDB"

DGMGRL> failover to standbyDB;
Performing failover NOW, please wait...
Error: ORA-16600: not connected to target standby database for failover

Failed.
Unable to failover

Here is an example of an affected configuration:

DGMGRL> create configuration 'DGconfig' as primary database is 'primaryDB' connect identifier is primaryDB;
Configuration "DGconfig" created with primary database "primaryDB"

DGMGRL> ADD FAR_SYNC farsync1 as connect identifier is farsync1;
far sync instance "farsync1" added

DGMGRL> add database standbyDB as connect identifier is standbyDB;
Database "standbyDB" added

DGMGRL> edit far_sync farsync1 set property redoroutes='(primaryDB:standbyDB ASYNC)';
Property "redoroutes" updated

DGMGRL> edit far_sync farsync1 set property maxfailure=1;
Property "maxfailure" updated

DGMGRL> edit far_sync farsync1 set property nettimeout=8;
Property "nettimeout" updated

DGMGRL> edit far_sync farsync1 set property reopensecs=5;
Property "reopensecs" updated

DGMGRL> edit database primaryDB set property redoroutes='(LOCAL:farsync1 sync alt=(standbyDB async fallback))';
Property "redoroutes" updated

DGMGRL> edit database standbyDB set property redoroutes='(LOCAL:primaryDB async)';
Property "redoroutes" updated

DGMGRL> show configuration

Configuration - DGconfig

Protection Mode: MaxPerformance
Members:
primaryDB - Primary database
 farsync1 - Far sync instance
  standbyDB - Physical standby database
 standbyDB - Physical standby database (alternate of farsync1)

Fast-Start Failover: DISABLED

Configuration Status:
DISABLED

To avoid this error apply the patch for bug 19399918 in all environments(Primary, Far Sync, Standby).

GOAL

From the definition of Application Continuity (AC), the AC replays support Data Guard environments, and it replays the uncommitted transactions in the standby when primary fails.

Scenario:
Application is connected to the Primary Database. Application executes transactions and commits the data. However, the committed data does not reach the standby database due to network latency.
In such scenario, if a failover to the standby database from the primary database is performed, will the replay drivers continue to replay the transaction that was committed but not replicated to the standby site?
What level of protection does Application continuity gives in such scenario?
 

SOLUTION

An Application Continuity-aware configuration uses Transaction Guard to know if the last user submission committed or not. When a failure occurs, the replay driver receives a failure notification and reconnects to the new primary database. Then Application Continuity performs sanity checks to verify that is the correct database and able to safely receive replay requests. Next, Transaction Guard is invoked to determine the state of in-flight transactions. If uncommitted changes exist, they are replayed.
So, if the transaction is already committed, Transaction Guard will avoid already-committed transactions being replayed again,causing potential for logical data corruption.
Data Guard has features such as maximize protection modes to handle committed data changes written to redo logs when there are communication issues with the standby.
To find out the protection mode you use in DataGuard, you could query v$database.
 

SQL>select database_role, open_mode, protection_level, protection_mode from v$database;


For MAXIMUM PROTECTION mode, the lgwr sync affirm log transport mode would be used.
So the transaction won't be committed on the primary database until the standby receives the redo from the primary and send acknowledge back to the primary saying the standby receives the redo. In case there is a communication issue between the primary and the standby, the transaction will not be committed on the primary database which could cause the primary hanging.

Reference: 
Data Guard Concepts and Administration

这篇关于Far Sync Standby 能不能支持 max protection的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/438631

相关文章

解决Office Word不能切换中文输入

我们在使用WORD的时可能会经常碰到WORD中无法输入中文的情况。因为,虽然我们安装了搜狗输入法,但是到我们在WORD中使用搜狗的输入法的切换中英文的按键的时候会发现根本没有效果,无法将输入法切换成中文的。下面我就介绍一下如何在WORD中把搜狗输入法切换到中文。

【经验交流】修复系统事件查看器启动不能时出现的4201错误

方法1,取得『%SystemRoot%\LogFiles』文件夹和『%SystemRoot%\System32\wbem』文件夹的权限(包括这两个文件夹的所有子文件夹的权限),简单点说,就是使你当前的帐户拥有这两个文件夹以及它们的子文件夹的绝对控制权限。这是最简单的方法,不少老外说,这样一弄,倒是解决了问题。不过对我的系统,没用; 方法2,以不带网络的安全模式启动,运行命令行,输入“ne

Golang支持平滑升级的HTTP服务

前段时间用Golang在做一个HTTP的接口,因编译型语言的特性,修改了代码需要重新编译可执行文件,关闭正在运行的老程序,并启动新程序。对于访问量较大的面向用户的产品,关闭、重启的过程中势必会出现无法访问的情况,从而影响用户体验。 使用Golang的系统包开发HTTP服务,是无法支持平滑升级(优雅重启)的,本文将探讨如何解决该问题。 一、平滑升级(优雅重启)的一般思路 一般情况下,要实现平滑

sqlite不支持中文排序,采用java排序

方式一 不支持含有重复字段进行排序 /*** sqlite不支持中文排序,改用java排序* 根据指定的对象属性字段,排序对象集合,顺序* @param list* @param field* @return*/public static List sortListByField(List<?> list,String field){List temp = new ArrayList(

一款支持同一个屏幕界面同时播放多个视频的视频播放软件

GridPlayer 是一款基于 VLC 的免费开源跨平台多视频同步播放工具,支持在一块屏幕上同时播放多个视频。其主要功能包括: 多视频播放:用户可以在一个窗口中同时播放任意数量的视频,数量仅受硬件性能限制。支持多种格式和流媒体:GridPlayer 支持所有由 VLC 支持的视频格式以及流媒体 URL(如 m3u8 链接)。自定义网格布局:用户可以配置播放器的网格布局,以适应不同的观看需求。硬

Science Robotics 首尔国立大学研究团队推出BBEX外骨骼,实现多维力量支持!

重复性举起物体可能会对脊柱和背部肌肉造成损伤,由此引发的腰椎损伤是工业环境等工作场所中一个普遍且令人关注的问题。为了减轻这类伤害,有研究人员已经研发出在举起任务中为工人提供辅助的背部支撑装置。然而,现有的这类装置通常无法在非对称性的举重过程中提供多维度的力量支持。此外,针对整个人体脊柱的设备安全性验证也一直是一个缺失的环节。 据探索前沿科技边界,传递前沿科技成果的X-robot投稿,来自首尔国立

超级 密码加密 解密 源码,支持表情,符号,数字,字母,加密

超级 密码加密 解密 源码,支持表情,符号,数字,字母,加密 可以将表情,动物,水果,表情,手势,猫语,兽语,狗语,爱语,符号,数字,字母,加密和解密 可以将文字、字母、数字、代码、标点符号等内容转换成新的文字形式,通过简单的文字以不同的排列顺序来表达不同的内容 源码截图: https://www.httple.net/152649.html

为什么构造函数不能为虚函数

1,从存储空间角度     虚函数对应一个vtable,这大家都知道,可是这个vtable其实是存储在对象的内存空间的。问题出来了,如果构造函数是虚的,就需要通过 vtable来调用,可是对象还没有实例化,也就是内存空间还没有,无法找到vtable,所以构造函数不能是虚函数。 2,从使用角度         虚函数主要用于在信息不全的情况下,能使重载的函数得到对应的调

file-max与ulimit的关系与差别

http://zhangxugg-163-com.iteye.com/blog/1108402 http://ilikedo.iteye.com/blog/1554822

QtC++截图支持窗口获取

介绍 在截图工具中你会发现,接触到窗口后会自动圈出目标窗口,个别强大一点的还能进行元素识别可以自动圈出元素,那么今天简单分析一下QTc++如何获取窗口并圈出当前鼠标下的窗口。 介绍1.如何获取所有窗口2.比较函数3.实现窗口判断 结尾 1.如何获取所有窗口 1.我们需要调用windows接口EnumWindowsProc回调函数来获取所有顶级窗口,需要包含windows.