Home » RDBMS Server » Networking and Gateways » one ip address..two listeners and two db instances
one ip address..two listeners and two db instances [message #540722] Wed, 25 January 2012 08:01 Go to next message
al_from_indiana
Messages: 6
Registered: January 2012
Junior Member
Is it possible to setup two listeners for two db instances on one server with a single IP address? I search everywhere and could not find any information about this type of configuration.

The error I'm getting when attempting to start the second listener after the first listener is up:

TNS-01150: The address of the specified listener name is incorrect
Re: one ip address..two listeners and two db instances [message #540724 is a reply to message #540722] Wed, 25 January 2012 08:04 Go to previous messageGo to next message
John Watson
Messages: 8394
Registered: January 2010
Location: Global Village
Senior Member
Welcome to the forum - I hope you will both learn and contribute. Please read our OraFAQ Forum Guide and How to use [code] tags and make your code easier to read

You can certainly have several listeners on the same IP address. Post your listener.ora file here, and we can probably work out what is wrong.
Re: one ip address..two listeners and two db instances [message #540729 is a reply to message #540724] Wed, 25 January 2012 08:15 Go to previous messageGo to next message
al_from_indiana
Messages: 6
Registered: January 2012
Junior Member
Hi John,

Thanks for your reply. Here's a copy of my listener.ora file:
DB1 =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS_LIST =
        (ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.34)(PORT = 1521))
      )
      (ADDRESS_LIST =
        (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC))
      )
    )
  )
SID_LIST_DB1 =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = BOOTDB1)
      (ORACLE_HOME = /oracle/app/oracle/product/10.2.0.1)
    )
)

DB2 =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS_LIST =
        (ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.34)(PORT = 1521))
      )
      (ADDRESS_LIST =
        (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC2)
      )
    )
  )

SID_LIST_DB12 =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = DB2)
      (ORACLE_HOME = /oracle/app/oracle/product/10.2.0.1)
    )
)

[Updated on: Wed, 25 January 2012 08:18]

Report message to a moderator

Re: one ip address..two listeners and two db instances [message #540731 is a reply to message #540729] Wed, 25 January 2012 08:22 Go to previous messageGo to next message
John Watson
Messages: 8394
Registered: January 2010
Location: Global Village
Senior Member
Next time, please enclose file listings in code tags, like this:
DB1 =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.34)(PORT = 1521))
)
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC))
)
)
)
SID_LIST_DB1 =
(SID_LIST =
(SID_DESC =
(SID_NAME = BOOTDB1)
(ORACLE_HOME = /oracle/app/oracle/product/10.2.0.1)
)
)

DB2 =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.34)(PORT = 1521))
)
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC2)
)
)
)

SID_LIST_DB12 =
(SID_LIST =
(SID_DESC =
(SID_NAME = DB2)
(ORACLE_HOME = /oracle/app/oracle/product/10.2.0.1)
)
)


Your syntax is wrong, you should have one ADDRESS_LIST within the DESCRIPTION that contains both your TCP listening address and your IPC listening address.
Two processes listening on the same IP adderss must each use a different port, you are trying to run both listeners on port 1521.

[update: I see you've added the code tags! Everyone will love you now.]

[Updated on: Wed, 25 January 2012 08:23]

Report message to a moderator

Re: one ip address..two listeners and two db instances [message #540742 is a reply to message #540731] Wed, 25 January 2012 08:50 Go to previous messageGo to next message
al_from_indiana
Messages: 6
Registered: January 2012
Junior Member
Like so?
DB1 =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS_LIST =
        (ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.34)(PORT = 1521))
      )
        (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC))
      )
    )
  )
SID_LIST_DB1 =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = BOOTDB1)
      (ORACLE_HOME = /oracle/app/oracle/product/10.2.0.1)
    )
)

DB2 =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS_LIST =
        (ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.34)(PORT = 1522))
      )
        (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC2)
      )
    )
  )

SID_LIST_DB12 =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = DB2)
      (ORACLE_HOME = /oracle/app/oracle/product/10.2.0.1)
    )
)

Re: one ip address..two listeners and two db instances [message #540744 is a reply to message #540742] Wed, 25 January 2012 08:55 Go to previous messageGo to next message
John Watson
Messages: 8394
Registered: January 2010
Location: Global Village
Senior Member
Not quote, both the addresses need to be within the address_list.
Re: one ip address..two listeners and two db instances [message #540745 is a reply to message #540744] Wed, 25 January 2012 08:56 Go to previous messageGo to next message
BlackSwan
Messages: 26747
Registered: January 2009
Location: SoCal
Senior Member
It is not necessary & undesirable to run multiple listeners.
A single listener can easily handler multiple instances.
Re: one ip address..two listeners and two db instances [message #540749 is a reply to message #540745] Wed, 25 January 2012 09:09 Go to previous messageGo to next message
al_from_indiana
Messages: 6
Registered: January 2012
Junior Member
Hopefully I got it right this time:
DB1 =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.34)(PORT = 1521))
      )
        (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC))
      )
    )
  )
SID_LIST_DB1 =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = BOOTDB1)
      (ORACLE_HOME = /oracle/app/oracle/product/10.2.0.1)
    )
)

DB2 =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.34)(PORT = 1522))
      )
        (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC2)
      )
    )
  )

SID_LIST_DB12 =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = DB2)
      (ORACLE_HOME = /oracle/app/oracle/product/10.2.0.1)
    )
)
Re: one ip address..two listeners and two db instances [message #540750 is a reply to message #540749] Wed, 25 January 2012 09:18 Go to previous messageGo to next message
BlackSwan
Messages: 26747
Registered: January 2009
Location: SoCal
Senior Member
realize that since Network Interface Card is a serial device, both listener can never be active concurrently.
While one listener is active passing packets on one port, the other listener MUST be idle.
So please explain the advantage for having two listeners.
Re: one ip address..two listeners and two db instances [message #540751 is a reply to message #540750] Wed, 25 January 2012 09:24 Go to previous messageGo to next message
John Watson
Messages: 8394
Registered: January 2010
Location: Global Village
Senior Member
come on, BS! You are right of course, but listeners aren't really doing anything most of the time.

And Al, you still haven't placed both the addresses within the address_list. And you have written SID_LIST_DB12 where I assume you mean SID)LIST_DB2. You might want to get rid of that file entirely, and use the netmgr tool to create a new one. It will save you a lot of stupid mistakes.
Re: one ip address..two listeners and two db instances [message #540752 is a reply to message #540750] Wed, 25 January 2012 09:24 Go to previous messageGo to next message
al_from_indiana
Messages: 6
Registered: January 2012
Junior Member
Blackswan,

Excuse my ignorance, we don't normally run multiple listeners but just "fell" upon running multiple instances so that there's a separate connection for each db instance on one running machine.
I'm upon to suggestions so feel free to "school" me.
Re: one ip address..two listeners and two db instances [message #540753 is a reply to message #540751] Wed, 25 January 2012 09:26 Go to previous message
al_from_indiana
Messages: 6
Registered: January 2012
Junior Member
John,

Can you give a short example of what you mean?

-Al
Previous Topic: ORA-12170: TNS:Connect timeout occurred
Next Topic: Listener support no services
Goto Forum:
  


Current Time: Sat Oct 24 10:39:24 CDT 2020