查看: 789|回复: 1

[安装] VMware+Centos6.5+oracle 10g 配置DG 不成功日志不同步问题

[复制链接]
论坛徽章:
0
发表于 2017-3-20 15:24 | 显示全部楼层 |阅读模式
本帖最后由 CrazyRabbit_DBA 于 2017-3-20 16:44 编辑

最近在VMware上搭建一个oracle10g 的 DG环境,配置完后测试日志没有同步,APPLIED  都为NO,请大神帮忙给点建议改从哪边开始检查
SQL> SELECT SEQUENCE#,APPLIED FROM V$ARCHIVED_LOG  ORDER BY SEQUENCE#;

SEQUENCE# APP
---------- ---
        32 NO
        33 NO
        34 NO
        35 NO
        36 NO
        37 NO
        38 NO


=========================================
规划如下:
Primary:
    IP:192.168.1.200
    SID:orcl
    Hostname:primary
    DB_UNIQUE_NAME:primaryDB

Standby1:
    IP:192.168.1.201
    SID:orcl
    Hostname:standby01
    DB_UNIQUE_NAME:standby01DB

Standby2:
    IP:192.168.1.202
    SID:orcl
    Hostname:standby02
    DB_UNIQUE_NAME:standby02DB


spfile :
primary:
orcl.__db_cache_size=75497472
orcl.__java_pool_size=37748736
orcl.__large_pool_size=4194304
orcl.__shared_pool_size=150994944
orcl.__streams_pool_size=0
*.audit_file_dest='/u01/app/oracle/admin/orcl/adump'
*.background_dump_dest='/u01/app/oracle/admin/orcl/bdump'
*.compatible='10.2.0.1.0'
*.control_files='/u01/app/oracle/oradata/orcl/control01.ctl','/u01/app/oracle/oradata/orcl/control02.ctl','/u01/app/oracle/oradata/orcl/control03.ctl'
*.core_dump_dest='/u01/app/oracle/admin/orcl/cdump'
*.db_block_size=8192
*.db_domain=''
*.db_file_multiblock_read_count=16
*.db_name='orcl'
*.db_recovery_file_dest='/u01/app/oracle/flash_recovery_area'
*.db_recovery_file_dest_size=2147483648
*.dispatchers='(PROTOCOL=TCP) (SERVICE=orclXDB)'
*.job_queue_processes=10
*.open_cursors=300
*.pga_aggregate_target=92274688
*.processes=150
*.remote_login_passwordfile='EXCLUSIVE'
*.sga_target=276824064
*.undo_management='AUTO'
*.undo_tablespace='UNDOTBS1'
*.user_dump_dest='/u01/app/oracle/admin/orcl/udump'
*.DB_UNIQUE_NAME='primaryDB'
*.log_archive_config='DG_CONFIG=(primaryDB,standby01DB,standby02DB)'
*.log_archive_dest_1='LOCATION=/u01/app/oracle/oradata/orcl/archivelog/'
*.log_archive_dest_2='SERVICE=standby01DB lgwr sync affirm VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLES) db_unique_name=standby01DB'
*.log_archive_dest_3='SERVICE=standby02DB lgwr sync affirm VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLES) db_unique_name=standby02DB'
*.STANDBY_FILE_MANAGEMENT=AUTO
*.LOG_ARCHIVE_DEST_STATE_1=ENABLE
*.LOG_ARCHIVE_DEST_STATE_2=ENABLE
*.LOG_ARCHIVE_DEST_STATE_3=ENABLE
*.FAL_SERVER='standby01DB','standby02DB'
*.FAL_CLIENT='primaryDB'


*-standby01DB-*

orcl.__db_cache_size=75497472
orcl.__java_pool_size=37748736
orcl.__large_pool_size=4194304
orcl.__shared_pool_size=150994944
orcl.__streams_pool_size=0
*.audit_file_dest='/u01/app/oracle/admin/orcl/adump'
*.background_dump_dest='/u01/app/oracle/admin/orcl/bdump'
*.compatible='10.2.0.1.0'
*.control_files='/u01/app/oracle/oradata/orcl/control01.ctl','/u01/app/oracle/oradata/orcl/control02.ctl','/u01/app/oracle/oradata/orcl/control03.ctl'
*.core_dump_dest='/u01/app/oracle/admin/orcl/cdump'
*.db_block_size=8192
*.db_domain=''
*.db_file_multiblock_read_count=16
*.db_name='orcl'
*.db_recovery_file_dest='/u01/app/oracle/flash_recovery_area'
*.db_recovery_file_dest_size=2147483648
*.dispatchers='(PROTOCOL=TCP) (SERVICE=orclXDB)'
*.job_queue_processes=10
*.open_cursors=300
*.pga_aggregate_target=92274688
*.processes=150
*.remote_login_passwordfile='EXCLUSIVE'
*.sga_target=276824064
*.undo_management='AUTO'
*.undo_tablespace='UNDOTBS1'
*.user_dump_dest='/u01/app/oracle/admin/orcl/udump'
*.DB_UNIQUE_NAME='standby01DB'
*.log_archive_config='DG_CONFIG=(primaryDB,standby01DB,standby02DB)'
*.log_archive_dest_1='LOCATION=/u01/app/oracle/oradata/orcl/archivelog/'
*.log_archive_dest_2='SERVICE=standby01DB lgwr sync affirm VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLES) db_unique_name=standby01DB'
*.log_archive_dest_3='SERVICE=standby02DB lgwr sync affirm VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLES) db_unique_name=standby02DB'
*.STANDBY_FILE_MANAGEMENT=AUTO
*.LOG_ARCHIVE_DEST_STATE_1=ENABLE
*.LOG_ARCHIVE_DEST_STATE_2=ENABLE
*.LOG_ARCHIVE_DEST_STATE_3=ENABLE
*.FAL_SERVER='primaryDB','standby02DB'
*.FAL_CLIENT='standby01DB'

*-standby02DB-*

orcl.__db_cache_size=75497472
orcl.__java_pool_size=37748736
orcl.__large_pool_size=4194304
orcl.__shared_pool_size=150994944
orcl.__streams_pool_size=0
*.audit_file_dest='/u01/app/oracle/admin/orcl/adump'
*.background_dump_dest='/u01/app/oracle/admin/orcl/bdump'
*.compatible='10.2.0.1.0'
*.control_files='/u01/app/oracle/oradata/orcl/control01.ctl','/u01/app/oracle/oradata/orcl/control02.ctl','/u01/app/oracle/oradata/orcl/control03.ctl'
*.core_dump_dest='/u01/app/oracle/admin/orcl/cdump'
*.db_block_size=8192
*.db_domain=''
*.db_file_multiblock_read_count=16
*.db_name='orcl'
*.db_recovery_file_dest='/u01/app/oracle/flash_recovery_area'
*.db_recovery_file_dest_size=2147483648
*.dispatchers='(PROTOCOL=TCP) (SERVICE=orclXDB)'
*.job_queue_processes=10
*.open_cursors=300
*.pga_aggregate_target=92274688
*.processes=150
*.remote_login_passwordfile='EXCLUSIVE'
*.sga_target=276824064
*.undo_management='AUTO'
*.undo_tablespace='UNDOTBS1'
*.user_dump_dest='/u01/app/oracle/admin/orcl/udump'
*.DB_UNIQUE_NAME='standby02DB'
*.log_archive_config='DG_CONFIG=(primaryDB,standby01DB,standby02DB)'
*.log_archive_dest_1='LOCATION=/u01/app/oracle/oradata/orcl/archivelog/'
*.log_archive_dest_2='SERVICE=standby01DB lgwr sync affirm VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLES) db_unique_name=standby01DB'
*.log_archive_dest_3='SERVICE=standby02DB lgwr sync affirm VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLES) db_unique_name=standby02DB'
*.STANDBY_FILE_MANAGEMENT=AUTO
*.LOG_ARCHIVE_DEST_STATE_1=ENABLE
*.LOG_ARCHIVE_DEST_STATE_2=ENABLE
*.LOG_ARCHIVE_DEST_STATE_3=ENABLE
*.FAL_SERVER='primaryDB','standby01DB'
*.FAL_CLIENT='standby02DB'


==================================================================
[oracle@primary admin]$ cat listener.ora
# listener.ora Network Configuration File: /u01/app/oracle/product/10.2.0/db_1/network/admin/listener.ora
# Generated by Oracle configuration tools.

SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = PLSExtProc)
      (ORACLE_HOME = /u01/app/oracle/product/10.2.0/db_1)
      (PROGRAM = extproc)
    )
  )

LISTENER =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
      (ADDRESS = (PROTOCOL = TCP)(HOST = primary)(PORT = 1521))
    )
  )

primaryDB =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
      (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.200)(PORT = 1521))
    )
  )

[oracle@standby01 admin]$ cat listener.ora
# listener.ora Network Configuration File: /u01/app/oracle/product/10.2.0/db_1/network/admin/listener.ora
# Generated by Oracle configuration tools.

SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = PLSExtProc)
      (ORACLE_HOME = /u01/app/oracle/product/10.2.0/db_1)
      (PROGRAM = extproc)
    )
  )

LISTENER =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
      (ADDRESS = (PROTOCOL = TCP)(HOST = standby01)(PORT = 1521))
    )
  )

standby01DB =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
      (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.201)(PORT = 1521))
    )
  )



[oracle@standby02 admin]$ cat listener.ora
# listener.ora Network Configuration File: /u01/app/oracle/product/10.2.0/db_1/network/admin/listener.ora
# Generated by Oracle configuration tools.

SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = PLSExtProc)
      (ORACLE_HOME = /u01/app/oracle/product/10.2.0/db_1)
      (PROGRAM = extproc)
    )
  )

LISTENER =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
      (ADDRESS = (PROTOCOL = TCP)(HOST = standby02)(PORT = 1521))
    )
  )

standby02DB =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
      (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.202)(PORT = 1521))
    )
  )


=========================================================  
tnsnames.ora
primaryDB =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.200)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = primaryDB)
    )
  )

standby01DB =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.201)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = standby01DB)
    )
  )

standby02DB =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.202)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = standby02DB)
    )
  )


论坛徽章:
0
 楼主| 发表于 2017-3-20 16:43 | 显示全部楼层

使用道具 举报

回复

您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

TOP技术积分榜 社区积分榜 徽章 团队 统计 知识索引树 积分竞拍 文本模式 帮助
  ITPUB首页 | ITPUB论坛 | 数据库技术 | 企业信息化 | 开发技术 | 微软技术 | 软件工程与项目管理 | IBM技术园地 | 行业纵向讨论 | IT招聘 | IT文档
  ChinaUnix | ChinaUnix博客 | ChinaUnix论坛
CopyRight 1999-2011 itpub.net All Right Reserved. 北京盛拓优讯信息技术有限公司版权所有 联系我们 
京ICP备09055130号-4  北京市公安局海淀分局网监中心备案编号:11010802021510 广播电视节目制作经营许可证:编号(京)字第1149号
  
快速回复 返回顶部 返回列表