zoukankan      html  css  js  c++  java
  • duplicate database的时候,rman连接 auxiliary database的后状态不正确

    auxiliary database 已经被startup nomount,但是rman连接后显示状态是not started

    复制代码
    $ export ORACLE_SID=dupdb
    $ sqlplus '/as sysdba'
    SQL> startup nomount 
    
    $ rman
    
    Recovery Manager: Release 11.2.0.1.0 - Production on Fri Jun 26 14:16:14 2015
    
    Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.
    
    RMAN> connect  target sys/oracle@ora11
    
    connected to target database: ORA11 (DBID=785451981)
    
    RMAN>  connect auxiliary sys/oracle@dupdb
    
    connected to auxiliary database: DUPDB (not started)
    复制代码

    #not started,说明我们连接到一个空闲例程,这种情况通常就是静态服务名中ORACLE_HOME配置不正确,或者SID配置不正确导致的。
    检查监听文件,发现oracle_home路径最后多了一个'/'

    复制代码
    SID_LIST_ORA11 =
            (SID_LIST =
                    (SID_DESC =
                            (GLOBAL_DBNAME = ora11)
                            (ORACLE_HOME = /u11/app/oracle/product/11.2.0/dbhome_1)
                    (SID_NAME =ora11)
                    )
                    (SID_DESC =
                            (GLOBAL_DBNAME = dupdb)
                            (ORACLE_HOME = /u11/app/oracle/product/11.2.0/dbhome_1/)
                            (SID_NAME =dupdb)
                    )
            )
    复制代码

    把上面代码中的'/'去掉即可。

    另外我们通过sqlplus xxx/xxx@xxx as sysdba的方式也可以测试一下是否连接到启动实例的实例,还是连接上了空闲实例。

  • 相关阅读:
    vue
    vim 使用
    ssh 免密码登录
    shell 监控
    shell top
    使用网络技术---WebView
    安卓数据存储
    模块
    面向对象
    文件
  • 原文地址:https://www.cnblogs.com/wangchaoyuana/p/7531985.html
Copyright © 2011-2022 走看看