If your migrated guest domain doesn't include Oracle Database, skip this section and follow your application specific procedures to modify the network and storage information.
The Oracle Database environment moved to a domain with a new hostname, and therefore requires some reconfiguration.
This procedure describes the reconfiguration process. The steps were derived and modified from the MOS document titled How to Reconfigure Oracle Restart on 12c / 12.1 (Doc ID 1570358.1).
Ignore the error messages in the output. The messages are expected because the grid infrastructure is not yet running.
bash-3.2# cd /u01/app/oracle1/product/12.1.0/grid/crs/install/ bash-3.2# ./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-4639: Could not contact Oracle High Availability Services CRS-4000: Command Stop failed, or completed with errors. 2018/01/03 07:45:33 CLSRSC-337: Successfully deconfigured Oracle Restart stack
bash-3.2# cd ../../
bash-3.2# ./root.sh
Performing root user operation.
The following environment variables are set as:
ORACLE_OWNER= oracle1
ORACLE_HOME= /u01/app/oracle1/product/12.1.0/grid
Copying dbhome to /usr/local/bin ...
Copying oraenv to /usr/local/bin ...
Copying coraenv to /usr/local/bin ...
Entries will be added to the /var/opt/oracle/oratab file as needed by
Database Configuration Assistant when a database is created
Finished running generic part of root script.
Now product-specific root actions will be performed.
Using configuration parameter file: /u01/app/oracle1/product/12.1.0/grid/crs/install/crsconfig_params
LOCAL ADD MODE
Creating OCR keys for user 'oracle1', privgrp 'dba'..
Operation successful.
LOCAL ONLY MODE
Successfully accumulated necessary OCR keys.
Creating OCR keys for user 'root', privgrp 'root'..
Operation successful.
CRS-4664: Node TargetGuestDomain successfully pinned.
2018/01/03 07:46:38 CLSRSC-330: Adding Clusterware entries to file '/etc/inittab'
Jan 3 07:45:19 TargetGuestDomain last message repeated 19 times
Jan 3 07:46:43 TargetGuestDomain root: Starting execution of Oracle Clusterware init.ohasd
Jan 3 07:46:43 TargetGuestDomain oracle1: exec /u01/app/oracle1/product/12.1.0/grid/perl/bin/perl
-I/u01/app/oracle1/product/12.1.0/grid/perl/lib /u01/app/oracle1/product/12.1.0/grid/bin/crswrapexece.pl
/u01/app/oracle1/product/12.1.0/grid/crs/install/s_crsconfig_TargetGuestDomain_env.txt
/u01/app/oracle1/product/12.1.0/grid/bin/ohasd.bin "reboot"
TargetGuestDomain 2018/01/03 07:47:09 /u01/app/oracle1/product/12.1.0/grid/cdata/TargetGuestDomain
/backup_20180103_074709.olr 0
Jan 3 07:47:13 TargetGuestDomain oracleoks: NOTICE: OKSK-00028: In memory kernel log buffer address: 0x30014875728, size: 10485760
Jan 3 07:47:13 TargetGuestDomain oracleoks: NOTICE: OKSK-00027: Oracle kernel distributed lock manager hash size is 31251
Jan 3 07:47:13 TargetGuestDomain oracleoks: NOTICE: OKSK-00004: Module load succeeded. Build information:
(LOW DEBUG) USM_12.1.0.2.0_SOLARIS.SPARC64_140611.5 2014/07/02 02:53:30
Jan 3 07:47:13 TargetGuestDomain oracleoks: NOTICE: ADVMK-0001: Module load succeeded. Build information:
(LOW DEBUG) - USM_12.1.0.2.0_SOLARIS.SPARC64_140611.5 built on 2014/07/02 02:59:14.
Jan 3 07:47:13 TargetGuestDomain oracleoks: NOTICE: ACFSK-0037: Module load succeeded. Build information:
(LOW DEBUG) USM_12.1.0.2.0_SOLARIS.SPARC64_140611.5 2014/07/02 03:05:09
CRS-2791: Starting shutdown of Oracle High Availability Services-managed resources on 'TargetGuestDomain'
CRS-2673: Attempting to stop 'ora.evmd' on 'TargetGuestDomain'
CRS-2677: Stop of 'ora.evmd' on 'TargetGuestDomain' succeeded
CRS-2793: Shutdown of Oracle High Availability Services-managed resources on 'TargetGuestDomain' has completed
CRS-4133: Oracle High Availability Services has been stopped.
Jan 3 07:47:16 TargetGuestDomain oracle1: exec /u01/app/oracle1/product/12.1.0/grid/perl/bin/perl
-I/u01/app/oracle1/product/12.1.0/grid/perl/lib /u01/app/oracle1/product/12.1.0/grid/bin/crswrapexece.pl
/u01/app/oracle1/product/12.1.0/grid/crs/install/s_crsconfig_TargetGuestDomain_env.txt
/u01/app/oracle1/product/12.1.0/grid/bin/ohasd.bin "reboot"
Jan 3 07:47:16 TargetGuestDomain oracle1: exec /u01/app/oracle1/product/12.1.0/grid/perl/bin/perl
-I/u01/app/oracle1/product/12.1.0/grid/perl/lib /u01/app/oracle1/product/12.1.0/grid/bin/crswrapexece.pl
/u01/app/oracle1/product/12.1.0/grid/crs/install/s_crsconfig_TargetGuestDomain_env.txt
/u01/app/oracle1/product/12.1.0/grid/bin/ohasd.bin "reboot"
CRS-4123: Oracle High Availability Services has been started.
2018/01/03 07:47:31 CLSRSC-327: Successfully configured Oracle Restart for a standalone server
bash-3.2# /u01/app/oracle1/product/12.1.0/grid/bin/crsctl status resource -t
--------------------------------------------------------------------------------
Name Target State Server State details
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.ons
OFFLINE OFFLINE TargetGuestDomain STABLE
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.cssd
1 OFFLINE OFFLINE STABLE
ora.diskmon
1 OFFLINE OFFLINE STABLE
ora.evmd
1 ONLINE ONLINE TargetGuestDomain STABLE
--------------------------------------------------------------------------------
Replace the old source guest domain name with a new target guest domain name in the listener.ora parameter file.
-bash-3.2$ cat /u01/app/oracle1/product/12.1.0/grid/network/admin/listener.ora
# listener.ora Network Configuration File: /u01/app/oracle1/product/12.1.0/grid/network/admin/listener.ora
# Generated by Oracle configuration tools.
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = TargetGuestDomain)(PORT = 1521))
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
)
)
ENABLE_GLOBAL_DYNAMIC_ENDPOINT_LISTENER=ON # line added by Agent
VALID_NODE_CHECKING_REGISTRATION_LISTENER=SUBNET # line added by Agent
-bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/srvctl add listener
-bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/srvctl start listener
-bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/crsctl status resource -t
--------------------------------------------------------------------------------
Name Target State Server State details
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.LISTENER.lsnr
ONLINE ONLINE TargetGuestDomain STABLE
ora.ons
OFFLINE OFFLINE TargetGuestDomain STABLE
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.cssd
1 OFFLINE OFFLINE STABLE
ora.diskmon
1 OFFLINE OFFLINE STABLE
ora.evmd
1 ONLINE ONLINE TargetGuestDomain STABLE
--------------------------------------------------------------------------------
-bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/lsnrctl status LSNRCTL for Solaris: Version 12.1.0.2.0 - Production on 03-JAN-2018 07:51:07 Copyright (c) 1991, 2014, Oracle. All rights reserved. Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=TargetGuestDomain)(PORT=1521))) STATUS of the LISTENER ------------------------ Alias LISTENER Version TNSLSNR for Solaris: Version 12.1.0.2.0 - Production Start Date 03-JAN-2018 07:50:37 Uptime 0 days 0 hr. 0 min. 30 sec Trace Level off Security ON: Local OS Authentication SNMP OFF Listener Parameter File /u01/app/oracle1/product/12.1.0/grid/network/admin/listener.ora Listener Log File /u01/app/oracle1/diag/tnslsnr/TargetGuestDomain/listener/alert/log.xml Listening Endpoints Summary... (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=TargetGuestDomain)(PORT=1521))) (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521))) The listener supports no services The command completed successfully
You can obtain this information from the ASM alert log file. For example:
-bash-3.2$ grep "Using parameter settings in server-side spfile" /u01/app/oracle1/diag/asm/+asm/+ASM/trace/alert_+ASM.log | tail -1 Using parameter settings in server-side spfile +DATA/ASM/ASMPARAMETERFILE/registry.253.962164099
-bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/srvctl add asm -bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/srvctl start asm
-bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/crsctl status resource -t
--------------------------------------------------------------------------------
Name Target State Server State details
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.LISTENER.lsnr
ONLINE ONLINE TargetGuestDomain STABLE
ora.asm
ONLINE ONLINE TargetGuestDomain Started,STABLE
ora.ons
OFFLINE OFFLINE TargetGuestDomain STABLE
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.cssd
1 ONLINE ONLINE TargetGuestDomain STABLE
ora.diskmon
1 OFFLINE OFFLINE STABLE
ora.evmd
1 ONLINE ONLINE TargetGuestDomain STABLE
--------------------------------------------------------------------------------
TargetGuestDomain$ /u01/app/oracle1/product/12.1.0/grid/bin/sqlplus / as sysasm
SQL*Plus: Release 12.1.0.2.0 Production on Wed Jan 3 08:35:48 2018
Copyright (c) 1982, 2014, Oracle. All rights reserved.
Connected to:
Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production
With the Automatic Storage Management option
SQL> alter diskgroup DATA mount ;
Diskgroup altered.
SQL> exit
Disconnected from Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production
With the Automatic Storage Management option
asmcmd
ASMCMD> lsdg
State Type Rebal Sector Block AU Total_MB Free_MB Req_mir_free_MB Usable_file_MB Offline_disks Voting_files Name
MOUNTED NORMAL N 512 4096 16777216 409568 259968 0 129984 0 N DATA/
ASMCMD> lsdsk -p -G DATA
Group_Num Disk_Num Incarn Mount_Stat Header_Stat Mode_Stat State Path
1 0 2419482960 CACHED MEMBER ONLINE NORMAL /dev/rdsk/c0d4s0
1 1 2419482961 CACHED MEMBER ONLINE NORMAL /dev/rdsk/c0d5s0
ASMCMD> cd +DATA/ASM/ASMPARAMETERFILE
ASMCMD> pwd
+DATA/ASM/ASMPARAMETERFILE
ASMCMD> ls
REGISTRY.253.962164099
-bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/sqlplus / as sysasm SQL*Plus: Release 12.1.0.2.0 Production on Wed Jan 3 07:55:53 2018 Copyright (c) 1982, 2014, Oracle. All rights reserved. Connected to: Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production With the Automatic Storage Management option SQL> create pfile='/tmp/init+ASM.ora' from spfile='+DATA/ASM/ASMPARAMETERFILE/REGISTRY.253.962164099'; File created. SQL> create spfile='+DATA' from pfile='/tmp/init+ASM.ora'; File created. SQL> show parameter pfile NAME TYPE VALUE ------------------------------------ ----------- ------------------------------ spfile string
-bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/srvctl stop asm -f
-bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/srvctl start asm
-bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/crsctl status resource -t
--------------------------------------------------------------------------------
Name Target State Server State details
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.DATA.dg
ONLINE ONLINE TargetGuestDomain STABLE
ora.LISTENER.lsnr
ONLINE ONLINE TargetGuestDomain STABLE
ora.asm
ONLINE ONLINE TargetGuestDomain Started,STABLE
ora.ons
OFFLINE OFFLINE TargetGuestDomain STABLE
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.cssd
1 ONLINE ONLINE TargetGuestDomain STABLE
ora.diskmon
1 OFFLINE OFFLINE STABLE
ora.evmd
1 ONLINE ONLINE TargetGuestDomain STABLE
--------------------------------------------------------------------------------
This example uses parameter settings in the server-side spfile +DATA/ORCL18/PARAMETERFILE/spfile.273.962165423.
-bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/asmcmd ASMCMD> cd +DATA/ORCL18/PARAMETERFILE/ ASMCMD> ls spfile.273.962165423 ASMCMD> exit
Note – The first command line is shown on multiple lines for readability, but is entered on a single line.
-bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/srvctl add database -d orcl18 -o $ORACLE_HOME
-p "+DATA/ORCL18/PARAMETERFILE/spfile.273.962165423" -a DATA
-bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/srvctl start db -d orcl18
-bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/crsctl status resource -t
--------------------------------------------------------------------------------
Name Target State Server State details
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.DATA.dg
ONLINE ONLINE TargetGuestDomain STABLE
ora.LISTENER.lsnr
ONLINE ONLINE TargetGuestDomain STABLE
ora.asm
ONLINE ONLINE TargetGuestDomain Started,STABLE
ora.ons
OFFLINE OFFLINE TargetGuestDomain STABLE
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.cssd
1 ONLINE ONLINE TargetGuestDomain STABLE
ora.diskmon
1 OFFLINE OFFLINE STABLE
ora.evmd
1 ONLINE ONLINE TargetGuestDomain STABLE
ora.orcl18.db
1 ONLINE ONLINE TargetGuestDomain Open,STABLE
--------------------------------------------------------------------------------
-bash-3.2$ /u01/app/oracle1/product/12.1.0/grid/bin/lsnrctl status
LSNRCTL for Solaris: Version 12.1.0.2.0 - Production on 03-JAN-2018 08:04:01
Copyright (c) 1991, 2014, Oracle. All rights reserved.
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=TargetGuestDomain)(PORT=1521)))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Solaris: Version 12.1.0.2.0 - Production
Start Date 03-JAN-2018 07:50:37
Uptime 0 days 0 hr. 13 min. 24 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /u01/app/oracle1/product/12.1.0/grid/network/admin/listener.ora
Listener Log File /u01/app/oracle1/diag/tnslsnr/TargetGuestDomain/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=TargetGuestDomain)(PORT=1521)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcps)(HOST=TargetGuestDomain)(PORT=5500))
(Security=(my_wallet_directory=/u01/app/oracle1/product/12.1.0/dbhome_1/admin/orcl18/xdb_wallet))
(Presentation=HTTP)(Session=RAW))
Services Summary...
Service "+ASM" has 1 instance(s).
Instance "+ASM", status READY, has 1 handler(s) for this service...
Service "orcl18" has 1 instance(s).
Instance "orcl18", status READY, has 1 handler(s) for this service...
Service "orcl18XDB" has 1 instance(s).
Instance "orcl18", status READY, has 1 handler(s) for this service...
Service "pdborcl" has 1 instance(s).
Instance "orcl18", status READY, has 1 handler(s) for this service...
The command completed successfully
-bash-3.2$ u01/app/oracle1/product/12.1.0/dbhome_1/bin/sqlplus / as sysdba SQL*Plus: Release 12.1.0.2.0 Production on Wed Jan 3 08:41:21 2018 Copyright (c) 1982, 2014, Oracle. All rights reserved. Connected to: Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production With the Partitioning, Automatic Storage Management, OLAP, Advanced Analytics and Real Application Testing options SQL> show sga Total System Global Area 4.2950E+10 bytes Fixed Size 7643936 bytes Variable Size 7113546976 bytes Database Buffers 2.4964E+10 bytes Redo Buffers 126566400 bytes In-Memory Area 1.0737E+10 bytes SQL> show parameter pfile NAME TYPE VALUE ------------------------------------ ----------- ------------------------------ spfile string +DATA/ORCL18/PARAMETERFILE/spfile.273.962165423
Edit the file and make the change.
The last two SQL results should match the same count as in the source domain steps. The source count was captured in Obtain Configuration Details from the Source Control Domain.
SQL> alter session set container=PDBORCL ; Session altered. SQL> show con_id CON_ID ------------------------------ 3 SQL> connect soe/soe@pdborcl Connected. SQL> select table_name from user_tables ; TABLE_NAME -------------------------------------------------------------------------------- CUSTOMERS ADDRESSES CARD_DETAILS WAREHOUSES ORDER_ITEMS ORDERS INVENTORIES PRODUCT_INFORMATION LOGON PRODUCT_DESCRIPTIONS ORDERENTRY_METADATA 11 rows selected. SQL> select count(*) from ORDERS ; COUNT(*) ---------- 26258963 SQL> select count(*) from ORDER_ITEMS ; COUNT(*) ---------- 70359059