您好,登錄后才能下訂單哦!
這篇文章主要介紹“如何利用ORACLE創建物理備庫”,在日常操作中,相信很多人在如何利用ORACLE創建物理備庫問題上存在疑惑,小編查閱了各式資料,整理出簡單好用的操作方法,希望對大家解答”如何利用ORACLE創建物理備庫”的疑惑有所幫助!接下來,請跟著小編一起來學習吧!
準備工作:
主庫啟用歸檔
在所有系統上安裝oralce 11g軟件
備庫創建必要的目錄
創建監聽,配置tnsname文件
第一步:
將主庫的密碼文件cp一份到備庫中
第二步:
主備庫的參數文件修改:
主庫參數文件如:
matrix.__db_cache_size=83886080
matrix.__java_pool_size=4194304
matrix.__large_pool_size=4194304
matrix.__oracle_base='/u2/oracle'#ORACLE_BASE set from environment
matrix.__pga_aggregate_target=176160768
matrix.__sga_target=243269632
matrix.__shared_io_pool_size=0
matrix.__shared_pool_size=138412032
matrix.__streams_pool_size=0
*.audit_file_dest='/u2/oracle/admin/matrix/adump'
*.audit_trail='db'
*.compatible='11.2.0.0.0'
*.control_files='/oradata/matrix/control01.ctl','/u2/oracle/fast_recovery_area/matrix/control02.ctl'
*.db_block_size=8192
*.db_domain=''
*.db_name='matrix'
*.db_recovery_file_dest='/u2/oracle/fast_recovery_area'
*.db_recovery_file_dest_size=4322230272
*.diagnostic_dest='/u2/oracle'
*.dispatchers='(PROTOCOL=TCP) (SERVICE=matrixXDB)'
*.memory_target=419430400
*.open_cursors=300
*.processes=150
*.remote_login_passwordfile='EXCLUSIVE'
*.undo_tablespace='UNDOTBS1'
*.db_unique_name='matrix'
*.log_archive_config='dg_config=(matrix,matrixdg)'
*.log_archive_dest_1='location=/oradata/arch/matrix'
*.log_archive_dest_2='service=matrixdg lgwr async valid_for=(online_logfiles,primary_role) db_unique_name=matrixdg'
*.log_archive_dest_state_1=enable
*.log_archive_dest_state_2=enable
*.standby_file_management='auto'
*.fal_server='matrixdg'
*.fal_client='matrix'
*.db_file_name_convert='/oradata/matrixdg','/oradata/matrix'
*.log_file_name_convert='/oradata/arch/matrixdg','/oradata/matrix'
~
備庫參數文件如:
*.audit_file_dest='/u2/oracle/admin/matrixdg/adump'
*.audit_trail='db'
*.compatible='11.2.0.0.0'
*.control_files='/oradata/matrixdg/control01.ctl','/u2/oracle/fast_recovery_area/matrixdg/control02.ctl'
*.db_block_size=8192
*.db_domain=''
*.db_name='matrix'
*.db_recovery_file_dest='/u2/oracle/fast_recovery_area'
*.db_recovery_file_dest_size=4322230272
*.diagnostic_dest='/u2/oracle'
*.dispatchers='(PROTOCOL=TCP) (SERVICE=matrixXDB)'
*.memory_target=419430400
*.open_cursors=300
*.processes=150
*.remote_login_passwordfile='EXCLUSIVE'
*.undo_tablespace='UNDOTBS1'
*.db_unique_name='matrixdg'
*.log_archive_config='dg_config=(matrix,matrixdg)'
*.log_archive_dest_1='location=/oradata/arch/matrixdg'
*.log_archive_dest_2='service=matrix lgwr async valid_for=(online_logfiles,primary_role) db_unique_name=matrix'
*.log_archive_dest_state_1=enable
*.log_archive_dest_state_2=enable
*.standby_file_management='manual'
*.fal_server='matrix'
*.fal_client='matrixdg'
*.db_file_name_convert='/oradata/matrix','/oradata/matrixdg'
*.log_file_name_convert='/oradata/arch/matrix','/oradata/arch/atrixdg'
第四步:
將備庫啟動到nomount狀態
SQL> startup nomount
第五步:
RMAN>connect target sys/oracle@matrix;
RMAN>connect target sys/oracle@matrixdg;
RMAN>duplicate target database for standby from active database;
第六步:
備為中創建standby redo logfile
SQL>alter database add standby logfile '<PATH>' size 50M;
第七步:
備為中啟動日志應用
SQL>alter database recover managed standby database using current logfile disconnect;
到此,關于“如何利用ORACLE創建物理備庫”的學習就結束了,希望能夠解決大家的疑惑。理論與實踐的搭配能更好的幫助大家學習,快去試試吧!若想繼續學習更多相關知識,請繼續關注億速云網站,小編會繼續努力為大家帶來更多實用的文章!
免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。