01 - Pre-requisites checks
Check the following pre-requisites before starting Dbvisit Replicate. If these are not correct, then the replication will NOT function.
1. Connect to the source server as oracle.
su - oracle
2. The database XE on both the source and target server should be started and available. To check if the database XE is running, check the pmon process (on both source and target)
ps -ef | grep pmon oracle 2467 1 0 13:31 ? 00:00:00 xe_pmon_XE oracle 2974 2933 0 13:35 pts/1 00:00:00 grep pmon
If the xe_pmon_XE process is running, that is a good indication that the Oracle database is running.
3. On the source server, check the TNS connection to the source database
tnsping ttorcl_src TNS Ping Utility for Linux: Version 11.2.0.2.0 - Production on 25-AUG-2014 13:47:58 Copyright (c) 1997, 2011, Oracle. All rights reserved. Used parameter files: Used TNSNAMES adapter to resolve the alias Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = source)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = XE))) OK (10 msec)
4. On the source server, check the TNS connection to the target database
tnsping ttorcl_trg TNS Ping Utility for Linux: Version 11.2.0.2.0 - Production on 25-AUG-2014 13:48:35 Copyright (c) 1997, 2011, Oracle. All rights reserved. Used parameter files: Used TNSNAMES adapter to resolve the alias Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = target)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = XE))) OK (40 msec)
5. Connect to the target server as oracle.
su - oracle
6. On the target server, check the TNS connection to the source database.
tnsping ttorcl_src TNS Ping Utility for Linux: Version 11.2.0.2.0 - Production on 25-AUG-2014 13:47:58 Copyright (c) 1997, 2011, Oracle. All rights reserved. Used parameter files: Used TNSNAMES adapter to resolve the alias Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = source)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = XE))) OK (30 msec)
7. On the target server, check the TNS connection to the target database.
tnsping ttorcl_trg TNS Ping Utility for Linux: Version 11.2.0.2.0 - Production on 25-AUG-2014 13:48:35 Copyright (c) 1997, 2011, Oracle. All rights reserved. Used parameter files: Used TNSNAMES adapter to resolve the alias Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = target)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = XE))) OK (10 msec)
8. On the source server, check the database connection to the source database.
sqlplus system/manager@ttorcl_src SQL*Plus: Release 11.2.0.2.0 Production on Mon Aug 25 13:51:06 2014 Copyright (c) 1982, 2011, Oracle. All rights reserved. Connected to: Oracle Database 11g Express Edition Release 11.2.0.2.0 - 64bit Production SQL>
Then select the hostname from v$instance.
SQL> SELECT host_name FROM v$instance; HOST_NAME ---------------------------------------------------------------- source
Type exit to exit out of SQL*Plus.
SQL> exit
9. On the source server, check the database connection to the target database.
sqlplus system/manager@ttorcl_trg SQL*Plus: Release 11.2.0.2.0 Production on Mon Aug 25 13:52:11 2014 Copyright (c) 1982, 2011, Oracle. All rights reserved. Connected to: Oracle Database 11g Express Edition Release 11.2.0.2.0 - 64bit Production SQL>
Then select the hostname from v$instance.
SQL> SELECT host_name FROM v$instance; HOST_NAME ---------------------------------------------------------------- target
Type exit to exit out of SQL*Plus.
SQL> exit
10. On the target server, check the database connection to the source database.
sqlplus system/manager@ttorcl_src SQL*Plus: Release 11.2.0.2.0 Production on Mon Aug 25 13:52:11 2014 Copyright (c) 1982, 2011, Oracle. All rights reserved. Connected to: Oracle Database 11g Express Edition Release 11.2.0.2.0 - 64bit Production SQL>
Then select the hostname from v$instance.
SQL> SELECT host_name FROM v$instance; HOST_NAME ---------------------------------------------------------------- source
Type exit to exit out of SQL*Plus.
SQL> exit
11. On the target server, check the database connection to the target database.
sqlplus system/manager@ttorcl_trg SQL*Plus: Release 11.2.0.2.0 Production on Mon Aug 25 13:52:11 2014 Copyright (c) 1982, 2011, Oracle. All rights reserved. Connected to: Oracle Database 11g Express Edition Release 11.2.0.2.0 - 64bit Production SQL>
Then select the hostname from v$instance.
SQL> SELECT host_name FROM v$instance; HOST_NAME ---------------------------------------------------------------- target
Type exit to exit out of SQL*Plus.
SQL> exit
If any of the pre-requisites fail, then verify if all the previous steps have been done correctly before continuing.