I have got an ORACLE RAC Environment access .The details are
Database Name: orcl Service Name: orcl IP Address: 192.168.1.1 and 192.168.1.2
SQL> host
Your connection string is referencing one instance on one server/node. You should be using the common service name instead, and identifying all the servers it is available on.
The equivalent for you would be something like this (line breaks just for clarity here):
(DESCRIPTION=(ADDRESS_LIST=
(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.1.1)(PORT=1521))
(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.1.2)(PORT=1521))
)(CONNECT_DATA=(SERVICE_NAME=orcl)))
As long as it is resolvable, it shouldn't matter whether you use the DNS names or the IP addresses for the HOST
parameters.
You may also need the LOAD_BALANCE
or FAILOVER
parameters; see the docs.