zoukankan      html  css  js  c++  java
  • dataguard备库开启闪回

    环境:

    OS:Centos 7

    DB:18C 2节点RAC的ADG

    下面的操作在rac的一个节点上执行即可

    1.检查闪回是否开启
    SQL> select flashback_on from V$database;

    FLASHBACK_ON
    ------------------
    NO

    2.查看当前是否设置了闪回的相关参数
    SQL> show parameters db_recovery_file_dest;

    NAME TYPE VALUE
    ------------------------------------ ----------- ------------------------------
    db_recovery_file_dest string +DATA
    db_recovery_file_dest_size big integer 16224M

    默认是一天
    SQL> show parameters db_flashback_retention_target

    NAME TYPE VALUE
    ------------------------------------ ----------- ------------------------------
    db_flashback_retention_target integer 1440
    SQL>


    若是没有设置,那么如下命令设置
    SQL> alter system set db_recovery_file_dest_size=16G scope=both;
    SQL> alter system set db_recovery_file_dest='+DATA' scope=both;
    SQL> alter systemset db_flashback_retention_target=1440;


    3.退出日志应用
    SQL> alter database recover managed standby database cancel;

    Database altered.


    4.开启闪回
    SQL> shutdown immediate
    SQL> startup mount
    SQL> alter database archivelog; ##已经开启了归档就不需要执行
    SQL> alter database flashback on;
    SQL> alter database open;

    5.重新应用日志
    SQL> alter database recover managed standby database using current logfile disconnect from session;

    6.打开pdb
    SQL> alter pluggable database all open;

    Pluggable database altered.

    7.查看闪回情况
    SQL> select flashback_on from V$database;

    FLASHBACK_ON
    ------------------
    YES

  • 相关阅读:
    Docker构建Centos7容器
    Docker命令大全
    win10常用开发配置
    git小结
    JSP页面The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path错误处理
    CentOS 设置mysql的远程访问
    CentOS安装MySQL
    Kali对wifi的破解记录
    MyEclipse对Maven的安装
    关于sqlmap的使用
  • 原文地址:https://www.cnblogs.com/hxlasky/p/15076025.html
Copyright © 2011-2022 走看看