Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Problems Trying To Run DUPLICATE

Posted on 2014-02-21
3
Medium Priority
?
3,179 Views
Last Modified: 2014-03-05
Can't get to target database when trying through RMAN, but the same is fine through SQLPlus.  What needs to be done to make it work with RMAN/

RMAN> connect target sys/ora@s2pdb
connected to target database: BB60 (DBID=2714891584)
RMAN> connect auxiliary sys/ora@BB60
connected to auxiliary database: BB60 (not mounted)
RMAN> DUPLICATE TARGET DATABASE FOR STANDBY FROM ACTIVE DATABASE
2> NOFILENAMECHECk
3> DORECOVER ;
Starting Duplicate Db at 21-FEB-14
using target database control file instead of recovery catalog
allocated channel: ORA_AUX_DISK_1
channel ORA_AUX_DISK_1: SID=9 device type=DISK
contents of Memory Script:
{
backup as copy reuse
targetfile '/apps/app/oracle/product/11.2.0/db_1/dbs/orapwBB60' auxiliary format
'/apps/app/oracle/product/11.2.0/db_1/dbs/orapwBB60' ;
}
executing Memory Script
Starting backup at 21-FEB-14
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=956 device type=DISK
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of Duplicate Db command at 02/21/2014 04:18:45
RMAN-03015: error occurred in stored script Memory Script
RMAN-03009: failure of backup command on ORA_DISK_1 channel at 02/21/2014 04:18:45
ORA-17629: Cannot connect to the remote database server
ORA-17627: ORA-12514: TNS:listener does not currently know of service requested in connect descriptor
ORA-17629: Cannot connect to the remote database server

names file

p2sdb =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = 134.154.228.220.csueastbay.edu)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = standby.csueastbay.edu)
      (UR = A)
  )
)
s2pdb =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = bbdevdb1.csueastbay.edu)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = primary.csueastbay.edu)
      (UR = A)
  )
)

Tnsping returns fine.
[oracle@larzena dbs]$ tnsping s2pdb

TNS Ping Utility for Linux: Version 11.2.0.4.0 - Production on 21-FEB-2014 07:18:14

Copyright (c) 1997, 2013, Oracle.  All rights reserved.

Used parameter files:
/apps/app/oracle/product/11.2.0/db_1/network/admin/sqlnet.ora


Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = bbdevdb1.csueastbay.edu)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = primary.csueastbay.edu) (UR = A)))
OK (10 msec)
[oracle@larzena dbs]$

Can connect using SQLPlus


[oracle@larzena dbs]$ $ORACLE_HOME/bin/sqlplus sys/ora@s2pdb as sysdba

SQL*Plus: Release 11.2.0.1.0 Production on Fri Feb 21 07:19:36 2014

Copyright (c) 1982, 2009, Oracle.  All rights reserved.


Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options

SQL> select count(*) from all_tables;

  COUNT(*)
----------
      3885

SQL>


Services from target machine:

-bash-3.2$ lsnrctl services

LSNRCTL for Linux: Version 11.2.0.2.0 - Production on 21-FEB-2014 14:19:24

Copyright (c) 1991, 2010, Oracle.  All rights reserved.

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=REGISTER)))
Services Summary...
Service "BB60" has 1 instance(s).
  Instance "BB60", status UNKNOWN, has 1 handler(s) for this service...
    Handler(s):
      "DEDICATED" established:618162 refused:100
         LOCAL SERVER
Service "BB60.csueastbay.edu" has 1 instance(s).
  Instance "p2sdb", status READY, has 1 handler(s) for this service...
    Handler(s):
      "DEDICATED" established:238 refused:0 state:ready
         LOCAL SERVER
Service "BB60XDB.csueastbay.edu" has 1 instance(s).
  Instance "p2sdb", status READY, has 1 handler(s) for this service...
    Handler(s):
      "D000" established:0 refused:0 current:0 max:1022 state:ready
         DISPATCHER <machine: bbdevdb1.csueastbay.edu, pid: 20014>
         (ADDRESS=(PROTOCOL=tcp)(HOST=bbdevdb1.csueastbay.edu)(PORT=54999))
Service "primary.csueastbay.edu" has 2 instance(s).
  Instance "p2sdb", status READY, has 1 handler(s) for this service...
    Handler(s):
      "DEDICATED" established:238 refused:0 state:ready
         LOCAL SERVER
  Instance "primary.csueastbay.edu", status UNKNOWN, has 1 handler(s) for this service...
    Handler(s):
      "DEDICATED" established:415978 refused:0
         LOCAL SERVER
The command completed successfully
-bash-3.2$
0
Comment
Question by:xoxomos
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 12

Accepted Solution

by:
Praveen Kumar Chandrashekatr earned 1200 total points
ID: 39879098
The tnsnames.ora the SERVICE_NAME should be a valid service name in your database.

SQL>select value from v$parameter where name='service_names';

Also check the steps by steps process using RMAN duplicate for active database.

https://blogs.oracle.com/AlejandroVargas/resource/dataguard/how%20to%20create%20a%20physical%20standby%20database%20using%20Rman%20Duplicate%20command.pdf
0
 

Author Comment

by:xoxomos
ID: 39892615
BB60 =
  (DESCRIPTION =
 (ADDRESS = (PROTOCOL = TCP)(HOST = 134.154.228.220)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = BB60.csueastbay.edu)
    )
  )
p2sdb =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = 134.154.228.220)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = BB60.csueastbay.edu))
      (UR = A)
    )
  )
s2pdb =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = bbdevdb1.csueastbay.edu)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = primary.csueastbay.edu)
      (UR = A)
    )
  )

SQL> show parameter service_names

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
service_names                        string      standby.csueastbay.edu, BB60.c
                                                 sueastbay.edu, standby, BB60
SQL>
SQL> select value from v$parameter where name='service_names';

VALUE
--------------------------------------------------------------------------------
standby.csueastbay.edu, BB60.csueastbay.edu, standby, BB60
0
 

Author Closing Comment

by:xoxomos
ID: 39907521
What you said is true, but in this particular case:
"The basic requirement is that there must be static listener entry in listener.ora for auxiliary."
0

Featured Post

Veeam Task Manager for Hyper-V

Task Manager for Hyper-V provides critical information that allows you to monitor Hyper-V performance by displaying real-time views of CPU and memory at the individual VM-level, so you can quickly identify which VMs are using host resources.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever had to make fundamental changes to a table in Oracle, but haven't been able to get any downtime?  I'm talking things like: * Dropping columns * Shrinking allocated space * Removing chained blocks and restoring the PCTFREE * Re-or…
From implementing a password expiration date, to datatype conversions and file export options, these are some useful settings I've found in Jasper Server.
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
This video shows how to Export data from an Oracle database using the Datapump Export Utility.  The corresponding Datapump Import utility is also discussed and demonstrated.

715 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question