On January 27th, this site will be read-only as we migrate to Oracle Forums for an improved community experience. You will not be able to initiate activity until January 30th, when you will be able to use this site as normal.

    Forum Stats

  • 3,889,532 Users
  • 2,269,755 Discussions
  • 7,916,773 Comments

Discussions

How users connections are established on RAC ENV

Jhil
Jhil Member Posts: 3,182 Bronze Trophy
edited Jan 16, 2018 10:49AM in Real Application Clusters

Dear RAC Experts,

>> On Node1

Public   : 192.168.212.40

Private  : 10.0.0.1

Virtual  : 192.168.212.70

>> On Node2

Public   : 192.168.212.41

Private  : 10.0.0.2

Virtual  : 192.168.212.71

Cluster may Active-Active or Active Passive !

>> Is this exactly correct ?

User are initially connected to Virtual IP (which is running on NODE1),   then user's  connections are routed to Public IP of the NODE1.

$ lsnrctl status

LSNRCTL for Linux: Version 11.2.0.1.0 - Production on 16-JAN-2018 02:05:44

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

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=LISTENER)))

STATUS of the LISTENER

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

Alias                     LISTENER

Version                   TNSLSNR for Linux: Version 11.2.0.1.0 - Production

Start Date                16-JAN-2018 02:04:46

Uptime                    0 days 0 hr. 0 min. 59 sec

Trace Level               off

Security                  ON: Local OS Authentication

SNMP                      OFF

Listener Parameter File   /u01/product/11.2.0/grid_home/network/admin/listener.ora

Listener Log File         /u01/app/grid/diag/tnslsnr/RAC1/listener/alert/log.xml

Listening Endpoints Summary...

  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=LISTENER)))

(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.212.40)(PORT=1521)))

  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.212.70)(PORT=1521)))

Services Summary...

Service "+ASM" has 1 instance(s).

  Instance "+ASM1", status READY, has 1 handler(s) for this service...

Service "crms" has 1 instance(s).

  Instance "crms1", status READY, has 1 handler(s) for this service...

Service "crmsXDB" has 1 instance(s).

  Instance "crms1", status READY, has 1 handler(s) for this service...

Service "tesco" has 1 instance(s).

  Instance "tesco", status READY, has 1 handler(s) for this service...

Service "tescoXDB" has 1 instance(s).

  Instance "tesco", status READY, has 1 handler(s) for this service...

The command completed successfully

Thanks in advance

Omohei

Answers

  • SUPRIYO DEY
    SUPRIYO DEY KOLKATA,INDIAMember Posts: 2,127 Silver Trophy
    edited Jan 16, 2018 1:18AM

    You will be having another IP called SCAN IP. That routes you to corresponding node listener and load balancing algorithm  decides which node to connect.

    Please check local_listener parameter in every node and REMOTE_LISTENER in every node.

    local_listener parameter is set to nodes VIP and REMOTE_LISTENER set to SCAN:Port

    here is a good doc

    https://docs.oracle.com/database/121/JJDBC/scan.htm#JJDBC29161

    OmoheiJhil
  • Omohei
    Omohei Saudi Arabia,Bahrain and EgyptMember Posts: 184 Blue Ribbon
    edited Jan 16, 2018 1:36AM

    Hi Surriyad ,

    where is the SCAN listener . as i noticed you are running 11.2 release . The scan listener is mandatory since this release

  • Jhil
    Jhil Member Posts: 3,182 Bronze Trophy
    edited Jan 16, 2018 1:37AM

    Hi

    Thanks. I will read it ..

    Please say clearly  ..

    User are initially connected to Virtual IP (which is running on NODE1),   then user's  connections are routed to Public IP of the NODE1

    Is that incorrect  ?

  • SUPRIYO DEY
    SUPRIYO DEY KOLKATA,INDIAMember Posts: 2,127 Silver Trophy
    edited Jan 16, 2018 1:56AM

    NO listener runs on VIP not on public IP.

  • Jhil
    Jhil Member Posts: 3,182 Bronze Trophy
    edited Jan 16, 2018 3:28AM

    Hi,

    $ lsnrctl status

    LSNRCTL for Linux: Version 11.2.0.1.0 - Production on 16-JAN-2018 17:53:24

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

    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=LISTENER)))

    STATUS of the LISTENER

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

    Alias                     LISTENER

    Version                   TNSLSNR for Linux: Version 11.2.0.1.0 - Production

    Start Date                16-JAN-2018 17:52:32

    Uptime                    0 days 0 hr. 0 min. 52 sec

    Trace Level               off

    Security                  ON: Local OS Authentication

    SNMP                      OFF

    Listener Parameter File   /u01/product/11.2.0/grid_home/network/admin/listener.ora

    Listener Log File         /u01/app/grid/diag/tnslsnr/RAC1/listener/alert/log.xml

    Listening Endpoints Summary...

      (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=LISTENER)))

      (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.212.40)(PORT=1521)))

      (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.212.70)(PORT=1521)))

    Services Summary...

    Service "+ASM" has 1 instance(s).

      Instance "+ASM1", status READY, has 1 handler(s) for this service...

    Service "crms" has 1 instance(s).

      Instance "crms1", status READY, has 1 handler(s) for this service...

    Service "tesco" has 1 instance(s).

      Instance "tesco", status READY, has 1 handler(s) for this service...

    Service "tescoXDB" has 1 instance(s).

      Instance "tesco", status READY, has 1 handler(s) for this service...

    The command completed successfully

    1)  why listener is showing public and VIP ?

    2)   SQL> show parameter listener;

    NAME                                 TYPE        VALUE

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

    listener_networks                    string

    local_listener                       string      (DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=rac1-vip)(PORT=1521))))

    remote_listener                      string      rac-scan:1521

    $ srvctl status scan_listener

    SCAN Listener LISTENER_SCAN1 is enabled

    SCAN listener LISTENER_SCAN1 is running on node rac1

  • SUPRIYO DEY
    SUPRIYO DEY KOLKATA,INDIAMember Posts: 2,127 Silver Trophy
    edited Jan 16, 2018 4:20AM

    This is for fail over. Two ip is used .

  • Jhil
    Jhil Member Posts: 3,182 Bronze Trophy
    edited Jan 16, 2018 4:39AM

    Hi,

    I am NOT understanding ..

    I am NOT talking about FAIL-OVER.

    >> Is this correct exactly ?  - How  normally connection is established on RAC env

    1) Users requests are initially handled by SCAN_LISTENER ...

    2) SCAN_LISTENER knows which is least loaded node.

    3) SCAN_LISTENER should handover  the connection to the listener on the VIP (least loaded node).

    4) VIP is routed the the incoming connections to the Public IP.

    5) Finally applications and  users are can access RAC Database.

    Edited.

    Thanks

  • SUPRIYO DEY
    SUPRIYO DEY KOLKATA,INDIAMember Posts: 2,127 Silver Trophy
    edited Jan 16, 2018 5:53AM

    if node public ip is down then?

This discussion has been closed.