Db makinamızın sanal klonunu başka bir ortamda farklı isimde veya farklı IP adresinde hazırladığımızda CRS/Grid yapısında aşağıdaki düzenlemeler yapmamız gerekiyor ASM instance ını açabilmek için;
tstdbclone@root </> crsctl start has CLSU-00100: Operating System function: opendir failed with error data: 2 CLSU-00101: Operating System error message: No such file or directory CLSU-00103: error location: scrsearch1 CLSU-00104: additional error information: cant open scr home dir scls_scr_getval CRS-4000: Command Start failed, or completed with errors. tstdbclone@root </> tstdbclone@oracle </oracle/app/grid_11204/bin> tstdbclone@oracle </oracle/app/grid_11204/bin> cd tstdbclone@oracle </oracle> . oraenv ORACLE_SID = [+ASM] ? The Oracle base remains unchanged with value /oracle/app/oracle tstdbclone@oracle </oracle> sqlplus / as sysasm SQL*Plus: Release 11.2.0.4.0 Production on Sat Feb 25 20:15:14 2017 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to an idle instance. SQL> startup ORA-01078: failure in processing system parameters ORA-29701: unable to connect to Cluster Synchronization Service SQL> Terminated tstdbclone@oracle </oracle> tstdbclone@oracle </oracle> ps -ef | grep pmon oracle 5439622 7274616 1 21:14:46 pts/1 0:00 grep pmon tstdbclone@oracle </oracle> sudo su - root tstdbclone@root </> . oraenv ORACLE_SID = [root] ? +ASM The Oracle base has been set to /oracle/app/oracle tstdbclone@root </> crsctl start has CLSU-00100: Operating System function: opendir failed with error data: 2 CLSU-00101: Operating System error message: No such file or directory CLSU-00103: error location: scrsearch1 CLSU-00104: additional error information: cant open scr home dir scls_scr_getval CRS-4000: Command Start failed, or completed with errors. tstdbclone@root </> cd /oracle/app tstdbclone@root </oracle/app> cd grid_11204/crs/install tstdbclone@root </oracle/app/grid_11204/crs/install> ./roothas.pl -deconfig -force Using configuration parameter file: ./crsconfig_params CRS-4639: Could not contact Oracle High Availability Services CRS-4000: Command Stop failed, or completed with errors. CRS-4639: Could not contact Oracle High Availability Services CRS-4000: Command Delete failed, or completed with errors. CLSU-00100: Operating System function: opendir failed with error data: 2 CLSU-00101: Operating System error message: No such file or directory CLSU-00103: error location: scrsearch1 CLSU-00104: additional error information: cant open scr home dir scls_scr_getval CRS-4544: Unable to connect to OHAS CRS-4000: Command Stop failed, or completed with errors. This may take several minutes. Please wait ... 0518-307 odmdelete: 1 objects deleted. 0518-307 odmdelete: 1 objects deleted. 0518-307 odmdelete: 1 objects deleted. Successfully deconfigured Oracle Restart stack tstdbclone@root </oracle/app/grid_11204/crs/install> ./roothas.pl Using configuration parameter file: ./crsconfig_params User ignored Prerequisites during installation LOCAL ADD MODE Creating OCR keys for user 'oracle', privgrp 'dba'.. Operation successful. LOCAL ONLY MODE Successfully accumulated necessary OCR keys. Creating OCR keys for user 'root', privgrp 'system'.. Operation successful. CRS-4664: Node tstdbclone successfully pinned. Adding Clusterware entries to inittab tstdbclone 2017/02/25 21:27:21 /oracle/app/grid_11204/cdata/tstdbclone/backup_20170225_212721.olr Successfully configured Oracle Grid Infrastructure for a Standalone Server tstdbclone@root </oracle/app/grid_11204/crs/install> tstdbclone@oracle </oracle> tstdbclone@oracle </oracle> . oraenv ORACLE_SID = [tstdbsrv] ? +ASM The Oracle base remains unchanged with value /oracle/app/oracle tstdbclone@oracle </oracle> crs_stat -t Name Type Target State Host ------------------------------------------------------------ ora.cssd ora.cssd.type OFFLINE OFFLINE ora.diskmon ora....on.type OFFLINE OFFLINE ora.evmd ora.evm.type ONLINE ONLINE tstdbclone ora.ons ora.ons.type OFFLINE OFFLINE tstdbclone@oracle </oracle> crsctl start resource "ora.cssd" CRS-2672: Attempting to start 'ora.cssd' on 'tstdbclone' CRS-2672: Attempting to start 'ora.diskmon' on 'tstdbclone' CRS-2676: Start of 'ora.diskmon' on 'tstdbclone' succeeded CRS-2676: Start of 'ora.cssd' on 'tstdbclone' succeeded tstdbclone@oracle </oracle> crs_stat -t Name Type Target State Host ------------------------------------------------------------ ora.cssd ora.cssd.type ONLINE ONLINE tstdbclone ora.diskmon ora....on.type OFFLINE OFFLINE ora.evmd ora.evm.type ONLINE ONLINE tstdbclone ora.ons ora.ons.type OFFLINE OFFLINE tstdbclone@oracle </oracle> ps -ef | grep listener oracle 4259846 7274616 0 21:29:57 pts/1 0:00 grep listener tstdbclone@oracle </oracle> cd /oracle/app tstdbclone@oracle </oracle/app> ls Agent12c grid_11204 oraInventory oracle tstdbclone@oracle </oracle/app> cd grid_11204 tstdbclone@oracle </oracle/app/grid_11204> cd network/ tstdbclone@oracle </oracle/app/grid_11204/network> cd admin tstdbclone@oracle </oracle/app/grid_11204/network/admin> ls listener.ora samples sqlnet.ora listener.ora.bak.fbcoredb01s shrept.lst tstdbclone@oracle </oracle/app/grid_11204/network/admin> cat listener.ora # listener.ora Network Configuration File: /oracle/app/grid/network/admin/listener.ora # Generated by Oracle configuration tools. LISTENER = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521)) (ADDRESS = (PROTOCOL = TCP)(HOST = testdbserver)(PORT = 1521)) ) ) #CONNECTION_RATE_LISTENER=10 ADR_BASE_LISTENER = /oracle/app/oracle ENABLE_GLOBAL_DYNAMIC_ENDPOINT_LISTENER=ON # line added by Agent INBOUND_CONNECT_TIMEOUT_LISTENER=500 tstdbclone@oracle </oracle/app/grid_11204/network/admin> vi listener.ora "listener.ora" 17 lines, 490 characters # listener.ora Network Configuration File: /oracle/app/grid/network/admin/listener.ora # Generated by Oracle configuration tools. LISTENER = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521)) (ADDRESS = (PROTOCOL = TCP)(HOST = tstdbclone)(PORT = 1521)) ) ) #CONNECTION_RATE_LISTENER=10 ADR_BASE_LISTENER = /oracle/app/oracle ENABLE_GLOBAL_DYNAMIC_ENDPOINT_LISTENER=ON # line added by Agent INBOUND_CONNECT_TIMEOUT_LISTENER=500 ~ ~ ~ "listener.ora" 17 lines, 490 characters tstdbclone@oracle </oracle/app/grid_11204/network/admin> ls listener.ora samples sqlnet.ora listener.ora.bak.fbcoredb01s shrept.lst tstdbclone@oracle </oracle/app/grid_11204/network/admin> cd ../.. tstdbclone@oracle </oracle/app/grid_11204> cd .. tstdbclone@oracle </oracle/app> ls Agent12c grid_11204 oraInventory oracle tstdbclone@oracle </oracle/app> cd oracle tstdbclone@oracle </oracle/app/oracle> ls Clusterware cfgtoollogs diag fbcoredb01s tstdbclone product admin checkpoints fbcoredb01d testdbserver oradata tstdbclone@oracle </oracle/app/oracle> cd product tstdbclone@oracle </oracle/app/oracle/product> ls 11.2.0 tstdbclone@oracle </oracle/app/oracle/product> cd 11.2.0 tstdbclone@oracle </oracle/app/oracle/product/11.2.0> ls dbhome_2 tstdbclone@oracle </oracle/app/oracle/product/11.2.0> cd dbhome_2 tstdbclone@oracle </oracle/app/oracle/product/11.2.0/dbhome_2> cd network/ tstdbclone@oracle </oracle/app/oracle/product/11.2.0/dbhome_2/network> ls admin doc install jlib lib log mesg tools trace tstdbclone@oracle </oracle/app/oracle/product/11.2.0/dbhome_2/network> cd admin/ tstdbclone@oracle </oracle/app/oracle/product/11.2.0/dbhome_2/network/admin> ls samples shrept.lst tnsnames.ora tstdbclone@oracle </oracle/app/oracle/product/11.2.0/dbhome_2/network/admin> cat tnsnames.ora # tnsnames.ora Network Configuration File: /oracle/app/oracle/product/11.2.0/dbhome_1/network/admin/tnsnames.ora # Generated by Oracle configuration tools. TEST_DB = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = testdbserver)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = TEST_DB) ) ) tstdbclone@oracle </oracle/app/oracle/product/11.2.0/dbhome_2/network/admin> tstdbclone@oracle </oracle/app/oracle/product/11.2.0/dbhome_2/network/admin> vi tnsnames.ora "tnsnames.ora" 69 lines, 1234 characters # tnsnames.ora Network Configuration File: /oracle/app/oracle/product/11.2.0/dbhome_1/network/admin/tnsnames.ora # Generated by Oracle configuration tools. TEST_DB = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = tstdbclone)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = TEST_DB) ) ) "tnsnames.ora" 69 lines, 1234 characters tstdbclone@oracle </oracle/app/oracle/product/11.2.0/dbhome_2/network/admin> tstdbclone@oracle </oracle/app/oracle/product/11.2.0/dbhome_2/network/admin> cd tstdbclone@oracle </oracle> crs_stat -t Name Type Target State Host ------------------------------------------------------------ ora.cssd ora.cssd.type ONLINE ONLINE tstdbclone ora.diskmon ora....on.type OFFLINE OFFLINE ora.evmd ora.evm.type ONLINE ONLINE tstdbclone ora.ons ora.ons.type OFFLINE OFFLINE tstdbclone@oracle </oracle> srvctl add listener -l LISTENER tstdbclone@oracle </oracle> srvctl start listener tstdbclone@oracle </oracle> srvctl status listener Listener LISTENER is enabled Listener LISTENER is running on node(s): tstdbclone tstdbclone@oracle </oracle> crs_stat ora.LISTENER.lsnr NAME=ora.LISTENER.lsnr TYPE=ora.listener.type TARGET=ONLINE STATE=ONLINE on tstdbclone tstdbclone@oracle </oracle> crs_stat -t Name Type Target State Host ------------------------------------------------------------ ora....ER.lsnr ora....er.type ONLINE ONLINE tstdbclone ora.cssd ora.cssd.type ONLINE ONLINE tstdbclone ora.diskmon ora....on.type OFFLINE OFFLINE ora.evmd ora.evm.type ONLINE ONLINE tstdbclone ora.ons ora.ons.type OFFLINE OFFLINE tstdbclone@oracle </oracle> srvctl add asm -l LISTENER -p PRKO-2388 : Command line option -p should be followed by a value. tstdbclone@oracle </oracle> tstdbclone@oracle </oracle> srvctl add asm -l LISTENER -p "/oracle/app/grid_11204/dbs/spfile+ASM.ora" tstdbclone@oracle </oracle> srvctl start asm tstdbclone@oracle </oracle> srvctl status asm ASM is running on tstdbclone tstdbclone@oracle </oracle> crs_stat -t Name Type Target State Host ------------------------------------------------------------ ora....ER.lsnr ora....er.type ONLINE ONLINE tstdbclone ora.asm ora.asm.type ONLINE ONLINE tstdbclone ora.cssd ora.cssd.type ONLINE ONLINE tstdbclone ora.diskmon ora....on.type OFFLINE OFFLINE ora.evmd ora.evm.type ONLINE ONLINE tstdbclone ora.ons ora.ons.type OFFLINE OFFLINE tstdbclone@oracle </oracle> ps -ef | grep pmon oracle 3932218 7274616 1 21:41:26 pts/1 0:00 grep pmon oracle 6684782 1 0 21:39:42 - 0:00 asm_pmon_+ASM tstdbclone@oracle </oracle> .oraenv bash: .oraenv: command not found tstdbclone@oracle </oracle> . oraenv ORACLE_SID = [+ASM] ? TEST_DB The Oracle base remains unchanged with value /oracle/app/oracle tstdbclone@oracle </oracle> sqlplus / as sysdba SQL*Plus: Release 11.2.0.4.0 Production on Sat Feb 25 21:41:59 2017 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to an idle instance. SQL> startup ORACLE instance started. Total System Global Area 3.4206E+10 bytes Fixed Size 2245512 bytes Variable Size 1.5502E+10 bytes Database Buffers 1.8522E+10 bytes Redo Buffers 179892224 bytes Database mounted. Database opened. SQL> exit Disconnected tstdbclone@oracle </oracle> ps -ef | grep pmon oracle 6422592 1 0 09:58:03 - 0:00 ora_pmon_TEST_DB oracle 6619240 1 0 09:55:46 - 0:00 asm_pmon_+ASM oracle 6750298 12451876 0 11:11:35 pts/3 0:00 grep pmon
Referans: How to Reconfigure Oracle Restart (Doc ID 986740.1)