Link to home
Start Free TrialLog in
Avatar of walkerdba
walkerdba

asked on

stand by

I create all the steps to create standy database..

when I connected the standby database,,

I see this..

Can you please help..


[oracle@term admin]$
[oracle@term admin]$ . oraenv stand
ORACLE_SID = [stand] ? stand
The Oracle base for ORACLE_HOME=/u01/app/oracle/product/11.2.0/db_1 is /u01/app/oracle
[oracle@term admin]$ sqlplus sys/oracle@stand as sysdba

SQL*Plus: Release 11.2.0.1.0 Production on Tue Feb 5 12:41:07 2013

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

ERROR:
ORA-12545: Connect failed because target host or object does not exist


Enter user-name:

I don't  know the sys password
why the error is like this
Avatar of slightwv (䄆 Netminder)
slightwv (䄆 Netminder)

Check:
http://ora-12545.ora-code.com/

If the ORACLE_HOME is correct: /u01/app/oracle/product/11.2.0/db_1

Can you post your tnsnames.ora file from:
/u01/app/oracle/product/11.2.0/db_1/network/admin
Hi,
It seems that you mix the ORACLE_SID used for local connection with the service name (using a @ connection string) to connect through the listener.
Regards,
Franck.
>>to connect through the listener

Missed that.

Do you need to connect remotly?  If you are on the server with the standby do this:  sqlplus / as sysdba

Also, as soon as oracle sees 'as sysdba' on a local connection, in most cases, the username and password doesn't matter.  You connect as SYS.  It uses the password file with your OS user.
Avatar of walkerdba

ASKER

This is tnsnamesora from term machine where standby resides

# tnsnames.ora Network Configuration File: /u01/app/oracle/product/11.2.0/dbhome_1/network/admin/tnsnames.ora
# Generated by Oracle configuration tools.

PRIM =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = term1.localdomain)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = prim)
    )
  )

ORCL =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = orcl.localdomain)
    )
  )

STAND =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = term1.localdomain)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = stand)
    )
  )


This is tnsnames.ora from term1 machine where primary database resides

# tnsnames.ora Network Configuration File: /u01/app/oracle/product/11.2.0/dbhome_1/network/admin/tnsnames.ora
# Generated by Oracle configuration tools.

PRIM =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = term1.localdomain)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = prim)
    )
  )

ORCL =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = orcl.localdomain)
    )
  )

STAND =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = term1.localdomain)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = stand)
    )
  )


------------------------------------------------------------------------------------------------------------

This is initstand.ora from  the machine where standby database is created..


stand.__db_cache_size=264241152
stand.__java_pool_size=4194304
stand.__large_pool_size=4194304
stand.__oracle_base='/u01/app/oracle'#ORACLE_BASE set from environment
stand.__pga_aggregate_target=159383552
stand.__sga_target=478150656
stand.__shared_io_pool_size=0
stand.__shared_pool_size=192937984
stand.__streams_pool_size=4194304
*.audit_file_dest='/u01/app/oracle/admin/stand/adump'
*.audit_trail='db'
*.compatible='11.2.0.0.0'
*.control_files='/u01/app/oracle/oradata/stand/control01.ctl','/u01/app/oracle/flash_recovery_area/stand/control02.ctl'
*.db_block_size=8192
*.db_domain=''
*.db_file_name_convert='prim/prim','stand/stand'
*.db_name='prim'
*.db_recovery_file_dest='/u01/app/oracle/flash_recovery_area'
*.db_recovery_file_dest_size=4039114752
*.diagnostic_dest='/u01/app/oracle'
*.dispatchers='(PROTOCOL=TCP) (SERVICE=standXDB)'
*.fal_client='stand'
*.fal_server='prim'
*.log_archive_config='dg_config=(stand,stand)'
*.log_archive_dest_1='location=/u01/app/oracle/stand/archive valid_for=(all_logfiles,all_roles) db_unique_name=stand'
*.log_archive_dest_2='service=prim valid_for=(online_logfile,standary_role) db_unique_name=stand'
*.log_file_name_convert='prim/prim','stand/stand'
*.open_cursors=300
*.pga_aggregate_target=158334976
*.processes=150
*.remote_login_passwordfile='EXCLUSIVE'
*.sga_target=476053504
*.standby_file_management='AUTO'
*.undo_tablespace='UNDOTBS1'
*.db_unique_name=stand


This is initprim.ora  from term1 machine

prim.__db_cache_size=264241152
prim.__java_pool_size=4194304
prim.__large_pool_size=4194304
prim.__oracle_base='/u01/app/oracle'#ORACLE_BASE set from environment
prim.__pga_aggregate_target=159383552
prim.__sga_target=478150656
prim.__shared_io_pool_size=0
prim.__shared_pool_size=192937984
prim.__streams_pool_size=4194304
*.audit_file_dest='/u01/app/oracle/admin/prim/adump'
*.audit_trail='db'
*.compatible='11.2.0.0.0'
*.control_files='/u01/app/oracle/oradata/prim/control01.ctl','/u01/app/oracle/flash_recovery_area/prim/control02.ctl'
*.db_block_size=8192
*.db_domain=''
*.db_file_name_convert='stand/stand','prim/prim'
*.db_name='prim'
*.db_recovery_file_dest='/u01/app/oracle/flash_recovery_area'
*.db_recovery_file_dest_size=4039114752
*.diagnostic_dest='/u01/app/oracle'
*.dispatchers='(PROTOCOL=TCP) (SERVICE=primXDB)'
*.fal_client='prim'
*.fal_server='stand'
*.log_archive_config='dg_config=(prim,stand)'
*.log_archive_dest_1='location=/u01/app/oracle/prim/archive valid_for=(all_logfiles,all_roles) '
*.log_archive_dest_2='service=stand valid_for=(online_logfile,primary_role) db_unique_name=stand '
*.log_file_name_convert='stand/stand','prim/prim'
*.open_cursors=300
*.pga_aggregate_target=158334976
*.processes=150
*.remote_login_passwordfile='EXCLUSIVE'
*.sga_target=476053504
*.standby_file_management='AUTO'
*.undo_tablespace='UNDOTBS1'
You have the same server configured in the tnsnames.ora file for stand and prim.

So is the stand database server configured as term1.localdomain?

Make sure term1.localdomain resolves to the correct IP address.

You also didn't post what happened if you didn't try a network connection with: sqlplus / as sysdba
machines pinging each other fine..

here is the real startup in standby location....



[oracle@term ~]$ export ORACLE_SID=stand
[oracle@term ~]$ sqlplus / as sysdba

SQL*Plus: Release 11.2.0.1.0 Production on Tue Feb 5 18:36:14 2013

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

Connected to an idle instance.

SQL> startup
ORA-16025: parameter LOG_ARCHIVE_DEST_2 contains repeated or conflicting attributes
SQL>
>>machines pinging each other fine..

You really shouldn't have the machines have the same name...  it might cause you problems down the road.

>>ORA-16025: parameter LOG_ARCHIVE_DEST_2 contains repeated or conflicting attributes

Looks like this parameter isn't correct.  Double check the steps you followed to make sure you didn't miss something.

I've never set up a standby database so I'm not sure what this should be set to.  If you can provide a link to the steps you followed, I can take a look at them.
[oracle@term dbs]$ sqlplus / as sysdba

SQL*Plus: Release 11.2.0.1.0 Production on Wed Feb 6 08:14:02 2013

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

Connected to an idle instance.

SQL> startup
ORACLE instance started.

Total System Global Area  477073408 bytes
Fixed Size                  1337324 bytes
Variable Size             205522964 bytes
Database Buffers          264241152 bytes
Redo Buffers                5971968 bytes
ORA-00205: error in identifying control file, check alert log for more info


SQL>
>>ORA-00205: error in identifying control file, check alert log for more info

From the init file you posted, you have:
*.control_files='/u01/app/oracle/oradata/stand/control01.ctl','/u01/app/oracle/flash_recovery_area/stand/control02.ctl'

Make sure the control files exist in those locations and are named as specified.  Also make sure they are owned by the oracle user.
what is wrong here

What is wrong here?
[oracle@term dbs]$ export ORACLE_SID=stand
[oracle@term dbs]$ sqlplus / as sysdba
SQL*Plus: Release 11.2.0.1.0 Production on Wed Feb 6 09:27:15 2013
Copyright (c) 1982, 2009, Oracle. All rights reserved.
Connected to an idle instance.
SQL> startup nomount
ORA-16032: parameter LOG_ARCHIVE_DEST_1 destination string cannot be translated
ORA-07286: sksagdi: cannot obtain device information.
Linux Error: 2: No such file or directory
SQL>
stand.__db_cache_size=264241152
stand.__java_pool_size=4194304
stand.__large_pool_size=4194304
stand.__oracle_base='/u01/app/oracle'#ORACLE_BASE set from environment
stand.__pga_aggregate_target=159383552
stand.__sga_target=478150656
stand.__shared_io_pool_size=0
stand.__shared_pool_size=192937984
stand.__streams_pool_size=4194304
*.audit_file_dest='/u01/app/oracle/admin/stand/adump'
*.audit_trail='db'
*.compatible='11.2.0.0.0'
*.control_files='/u01/app/oracle/oradata/stand/control01.ctl','/u01/app/oracle/flash_recovery_area/stand/control02.ctl'
*.db_block_size=8192
*.db_domain=''
*.db_file_name_convert='oradata/prim','oradata/stand'
*.db_name='prim'
*.db_recovery_file_dest='/u01/app/oracle/flash_recovery_area'
*.db_recovery_file_dest_size=4039114752
*.diagnostic_dest='/u01/app/oracle'
*.dispatchers='(PROTOCOL=TCP) (SERVICE=standXDB)'
*.fal_client='stand'
*.fal_server='prim'
*.log_archive_config='dg_config=(prim,stand)'
*.log_archive_dest_1='location=/u01/app/oracle/prim/archive valid_for=(all_logfiles,all_roles) db_unique_name=stand'
*.log_archive_dest_2='service=prim valid_for=(online_logfile, primary_role) db_unique_name=prim'
*.log_file_name_convert='/oradata/prim','/oradata/stand'
*.open_cursors=300
*.pga_aggregate_target=158334976
*.processes=150
*.remote_login_passwordfile='EXCLUSIVE'
*.sga_target=476053504
*.standby_file_management='AUTO'
*.undo_tablespace='UNDOTBS'
*.db_unique_name=stand
Take a good look at the setting for log_archive_dest_1 in your pfile:
*.log_archive_dest_1='location=/u01/app/oracle/prim/archive
Change
*.log_archive_dest_1='location=/u01/app/oracle/prim/archive



to what?
>>to what?

The correct PATH where you want them to go.  Did you notice it still referenced 'prim' ( I bolded it in my last post)?
Sir the question  is do we need to create
/u01/app/oracle/prim/archive  this path in standby machine...(this is from primary)

I have already this path in primay database machine...

I have this path now in my standby machine.
/u01/app/oracle/stand/stand/arch
For log_archive_dest_1 on the stand machine, I would expect it to be set to the stand folder.

Remember, I've never set up a standby database so I'm not sure if you need another log_archive_dest_n set to point to where the prim archived logs are placed.

The guide you are following to set this all up should have covered the specifics for this.
Is there any way to solve this issue...
>>Is there any way to solve this issue...

Which issue?  You have covered several different issues here.

Which one is still outstanding?

I also asked for the link/doc you used to create the standby back up in http:#a38859311.  I'm thinking you missed a step or three.
Both the nodes has these



[oracle@term stand]$ cd arch/
[oracle@term arch]$ pwd
/u01/app/oracle/stand/stand/arch
[oracle@term arch]$



Where the standby going to be





This is where the primary is



[oracle@term1 stand]$ cd arch/
[oracle@term1 arch]$ pwd
/u01/app/oracle/stand/stand/arch
[oracle@term1 arch]$




But still ,





[oracle@term arch]$ . oraenv
ORACLE_SID = [stand] ? stand
The Oracle base for ORACLE_HOME=/u01/app/oracle/product/11.2.0/db_1 is /u01/app/oracle
[oracle@term arch]$ sqlplus / as sysdba

SQL*Plus: Release 11.2.0.1.0 Production on Thu Feb 7 16:40:18 2013

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

Connected to an idle instance.

SQL> startup nomount
ORA-16032: parameter LOG_ARCHIVE_DEST_1 destination string cannot be translated
ORA-07286: sksagdi: cannot obtain device information.
Linux Error: 2: No such file or directory
SQL>
ASKER CERTIFIED SOLUTION
Avatar of slightwv (䄆 Netminder)
slightwv (䄆 Netminder)

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
yes