Oracle 18c使用dbca建立級聯DG
Oracle 18c使用dbca建立級聯DG
更多參考: http://blog.itpub.net/26736162/viewspace-2656076/
-------------------- dbca搭建級聯備庫 --------配置tns CDBLHR18cdg2 = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.59.130)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = CDBLHR18cdg2) ) ) --------配置監聽 (SID_DESC = (GLOBAL_DBNAME = CDBLHR18cdg2) (ORACLE_HOME = /u08/app/oracle/product/18.0.0/dbhome_1) (SID_NAME = CDBLHR18cdg2) ) (SID_DESC = (GLOBAL_DBNAME = CDBLHR18cdg2_DGMGRL) (ORACLE_HOME = /u08/app/oracle/product/18.0.0/dbhome_1) (SID_NAME = CDBLHR18cdg2) ) --搭建過程是:備庫和第2備庫的操作 dbca -silent -createDuplicateDB \ -gdbName CDBLHR18cdg2 \ -sid CDBLHR18cdg2 \ -sysPassword lhr \ -primaryDBConnectionString 192.168.59.130:1521/CDBLHR18cdg \ -nodelist rhel6lhr \ -databaseConfigType SINGLE \ -createAsStandby -dbUniqueName CDBLHR18cdg2 \ -datafileDestination '/u01/app/oracle/oradata/CDBLHR18cdg2/' \ -initParams db_create_file_dest=/u01/app/oracle/oradata/CDBLHR18cdg2/,db_create_online_log_dest_1=/u01/app/oracle/oradata/CDBLHR18cdg2/,sga_target=800M,memory_max_target=0,memory_target=0 ---全引數 rac環境 set line 1000 set pagesize 1000 col name format a25 col VALUE format a100 SELECT a.NAME, i.instance_name, a.VALUE FROM gv$parameter a, gv$instance i WHERE a.inst_id = i.inst_id and a.name in ('dg_broker_start','db_name','db_unique_name','log_archive_config','log_archive_dest_1','log_archive_dest_2','log_archive_dest_3','log_archive_dest_state_1','log_archive_dest_state_2','log_archive_dest_state_3','log_archive_max_processes','remote_login_passwordfile','db_file_name_convert','log_file_name_convert','standby_file_management','fal_server','fal_client','dg_broker_config_file1','dg_broker_config_file2') ORDER BY a.name, i.instance_name; --主庫修改引數 Alter system set LOG_ARCHIVE_CONFIG='DG_CONFIG=(CDBLHR18c,CDBLHR18cdg,CDBLHR18cdg2)'; --一級備庫修改引數 alter system set log_archive_config='dg_config=(CDBLHR18c,CDBLHR18cdg,CDBLHR18cdg2)'; alter system set LOG_ARCHIVE_DEST_3= 'SERVICE=CDBLHR18cdg2 VALID_FOR=(STANDBY_LOGFILES,STANDBY_ROLE) DB_UNIQUE_NAME=CDBLHR18cdg2'; -- 二級備庫修改引數 alter system set log_archive_config='dg_config=(CDBLHR18c,CDBLHR18cdg,CDBLHR18cdg2)'; alter system set LOG_ARCHIVE_DEST_1='LOCATION=USE_DB_RECOVERY_FILE_DEST VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=CDBLHR18cdg2'; alter system set db_file_name_convert='/u01/app/oracle/oradata/CDBLHR18cdg/','/u01/app/oracle/oradata/CDBLHR18cdg2/' scope=spfile; alter system set log_file_name_convert='/u01/app/oracle/oradata/CDBLHR18cdg/','/u01/app/oracle/oradata/CDBLHR18cdg2/' scope=spfile; alter system set fal_client='CDBLHR18cdg2'; alter system set fal_server='CDBLHR18cdg'; shutdown immediate startup alter system register; --備庫查詢實時應用 alter database recover managed standby database cancel; ALTER DATABASE flashback on; alter database recover managed standby database using current logfile disconnect; ! ps -ef|grep ora_mrp COL NAME FOR A100 SET LINESIZE 9999 PAGESIZE 9999 COL NEXT_CHANGE# FOR 999999999999999 SELECT THREAD#, NAME, SEQUENCE#, ARCHIVED, APPLIED, A.NEXT_CHANGE# FROM V$ARCHIVED_LOG A WHERE A.SEQUENCE# >= (SELECT MAX(B.SEQUENCE#) - 3 FROM V$ARCHIVED_LOG B WHERE B.THREAD# = A.THREAD# AND B.RESETLOGS_CHANGE# = A.RESETLOGS_CHANGE# AND B.RESETLOGS_CHANGE# = (SELECT D.RESETLOGS_CHANGE# FROM V$DATABASE D) AND B.APPLIED = 'YES' AND B.DEST_ID=A.DEST_ID GROUP BY B.THREAD#) AND A.STANDBY_DEST='NO' ORDER BY A.THREAD#, A.SEQUENCE#; alter system set dg_broker_start=true sid='*'; dgmgrl sys/lhr@CDBLHR18c show configuration add database CDBLHR18cdg2 as connect identifier is CDBLHR18cdg2 maintained as physical; enable configuration enable database CDBLHR18cdg2 show database verbose CDBLHR18c; show database verbose CDBLHR18cdg; show database verbose CDBLHR18cdg2; alter database recover managed standby database cancel; alter database flashback on; select flashback_on,force_logging from v$database; alter database recover managed standby database using current logfile disconnect; edit database CDBLHR18cdg2 set property StaticConnectIdentifier ='(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.59.130)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=CDBLHR18cdg2)(INSTANCE_NAME=lhr19cdg)(SERVER=DEDICATED)))';
配置完結果:
DGMGRL> show configuration Configuration - cdblhr18c Protection Mode: MaxPerformance Members: cdblhr18c - Primary database cdblhr18cdg - Physical standby database cdblhr18cdg2 - Physical standby database Fast-Start Failover: DISABLED Configuration Status: SUCCESS (status updated 49 seconds ago) DGMGRL>
About Me
........................................................................................................................ ● 本文作者:小麥苗,部分內容整理自網路,若有侵權請聯絡小麥苗刪除 ● 本文在itpub、部落格園、CSDN和個人微 信公眾號( xiaomaimiaolhr)上有同步更新 ● 本文itpub地址: http://blog.itpub.net/26736162 ● 本文部落格園地址: http://www.cnblogs.com/lhrbest ● 本文CSDN地址: https://blog.csdn.net/lihuarongaini ● 本文pdf版、個人簡介及小麥苗雲盤地址: http://blog.itpub.net/26736162/viewspace-1624453/ ● 資料庫筆試面試題庫及解答: http://blog.itpub.net/26736162/viewspace-2134706/ ● DBA寶典今日頭條號地址: http://www.toutiao.com/c/user/6401772890/#mid=1564638659405826 ........................................................................................................................ ● QQ群號: 230161599 、618766405 ● 微 信群:可加我微 信,我拉大家進群,非誠勿擾 ● 聯絡我請加QQ好友 ( 646634621 ),註明新增緣由 ● 於 2019-09-01 06:00 ~ 2019-09-31 24:00 在西安完成 ● 最新修改時間:2019-09-01 06:00 ~ 2019-09-31 24:00 ● 文章內容來源於小麥苗的學習筆記,部分整理自網路,若有侵權或不當之處還請諒解 ● 版權所有,歡迎分享本文,轉載請保留出處 ........................................................................................................................ ● 小麥苗的微店: https://weidian.com/s/793741433?wfr=c&ifr=shopdetail ● 小麥苗出版的資料庫類叢書: http://blog.itpub.net/26736162/viewspace-2142121/ ● 小麥苗OCP、OCM、高可用網路班: http://blog.itpub.net/26736162/viewspace-2148098/ ● 小麥苗騰訊課堂主頁: https://lhr.ke.qq.com/ ........................................................................................................................ 使用 微 信客戶端掃描下面的二維碼來關注小麥苗的微 信公眾號( xiaomaimiaolhr)及QQ群(DBA寶典)、新增小麥苗微 信, 學習最實用的資料庫技術。
........................................................................................................................ |
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/26736162/viewspace-2656848/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 【DG】Oracle 19c使用dbca來搭建物理DGOracle
- 【DG】Oracle之級聯DG--(cascade dg) --(一主一備一級聯)Oracle
- 【DG】Oracle 19c使用dbca來搭建物理DG--主rac備racOracle
- Oracle 18c - 配置只讀 OracleHome / DBCA / Patching / Upgrade (文件 ID 2469646.1)Oracle
- Oracle DG建立Physical Standby DatabaseOracleDatabase
- Oracle DG建立Logical Standby DatabaseOracleDatabase
- 4.3.1 關於使用DBCA建立CDB
- 2.3.1 有關使用DBCA建立資料庫資料庫
- Oracle 18C升級到19COracle
- Oracle 12C升級到18COracle
- Oracle 18cOracle
- Oracle OCP(36):DBCA建庫Oracle
- 2.13.3 使用 Oracle Wallet 實現在DBCA中使用身份驗證Oracle
- 【邏輯DG滾動升級二】ORACLE11204 邏輯DG滾動升級至12C---DG端前期準備Oracle
- 2.3.2 關於使用互動式DBCA建立資料庫資料庫
- 3 建立物理DG
- Oracle:DG 的 switchoverOracle
- oracle dg報錯Oracle
- 【邏輯DG滾動升級三】ORACLE11204 邏輯DG滾動升級至12C---正式升級Oracle
- oracle dg庫資料檔案建立失敗ORA-01111Oracle
- 【kingsql分享】Oracle 18c RAC補丁升級實戰【DBRU】SQLOracle
- Oracle DB 18c - 手動升級到 18c 的完整核對清單 (文件 ID 2469647.1)Oracle
- 2.3 通過DBCA建立資料庫資料庫
- Oracle 級聯表更新和SQLServer 級聯表更新OracleSQLServer
- Oracle RAC+DG搭建Oracle
- Oracle DG 日常點檢Oracle
- Oracle DG管理Broker配置Oracle
- oracle11g單例項透過命令列dbca靜默建立資料庫Oracle單例命令列資料庫
- 2.3.3 關於使用非互動式/靜默DBCA建立資料庫資料庫
- 【18c】Oracle 18.3 RPM安裝Oracle
- ORACLE DG之備庫角色Oracle
- Oracle DG運維常用SQLOracle運維SQL
- oracle dg切換操作示例Oracle
- ORACLE 11.2.0.4 DG(Broker) for linux 部署OracleLinux
- Oracle DG Standby Database型別OracleDatabase型別
- Oracle 19c - 手動升級 Oracle 12.x, 18c CDB 到 Oracle 19c (19.x)Oracle
- Oracle Linux 7.1 靜默安裝Oracle 18c RACOracleLinux
- oracle級聯刪除使用者,刪除表空間Oracle