Forum Stats

  • 3,838,694 Users
  • 2,262,394 Discussions
  • 7,900,736 Comments

Discussions

Listener refused the connection

User_UL6AR
User_UL6AR Member Posts: 14 Green Ribbon

Dear Oracle community, I know this question was already asked, but I tried to find a solution and unfortunately I'm blocked since 3 days now. I installed Oracle 12c in Linux centos 7 server. When I try to access to the Oracle DB with SQL developer I have the following error:

Listener refused the connection with following error: ORA-12514, TNS:listener does not currently know of service requested in connect descriptor

What I do not understand is that if I restart the database I can connect. But Once I disconnect a try a reconnect I got the same error. Here is my listener.ora file

LISTENER = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = ns3008269.ip-151-80-45.eu)(PORT = 1521)) (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521)) ) ) And my tnsnames.ora is : rspdata = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = ns3008269.ip-151-80-45.eu)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = rspdata) ) )

Here is my tnsnames.ora:

rspdata =

 (DESCRIPTION =

  (ADDRESS = (PROTOCOL = TCP)(HOST = ns3008269.ip-151-80-45.eu)(PORT = 1521))

  (CONNECT_DATA =

   (SERVER = DEDICATED)

   (SERVICE_NAME = rspdata)

  )

 )


oraclepdb =

 (DESCRIPTION =

  (ADDRESS = (PROTOCOL = TCP)(HOST = ns3008269.ip-151-80-45.eu)(PORT = 1521))

  (CONNECT_DATA =

   (SERVER = DEDICATED)

   (SERVICE_NAME = oraclepdb)

  )

 )


And finally you can fin in attachment a screenshot of my Installation configuration. I tried lot of and lot of thing... but still blocked. thank you very much in advance for your help




Tagged:

Best Answers

  • User_UL6AR
    User_UL6AR Member Posts: 14 Green Ribbon
    Answer ✓

    Hi Billy Verreynne,

    Thank you a lot for your reply. I was able to solve this issue. I re-installed Oracle 12c but I used the tools netmgr and catmgr to configure correctly the listener and the tnsnames.

    So when installing Oracle 12c do not modify by hand listener.ora and tnsnames.ora by hand. Thank you this issue is now solved.

    Kind regards.

  • Billy Verreynne
    Billy Verreynne Software Engineer Member Posts: 28,833 Red Diamond

    So when installing Oracle 12c do not modify by hand listener.ora and tnsnames.ora by hand.

    Not really true. Listener config is not a dark art. Customisation allows for extended features and flexibility.

    Thank you this issue is now solved.

    Good going - sticking to defaults is a good choice when dealing with a new product or technology.

Answers

  • Billy Verreynne
    Billy Verreynne Software Engineer Member Posts: 28,833 Red Diamond

    Do a lsnrctl services command to get the list of services registered with the Listener, and the endpoint used by the Listener.

    Use a client connection to that endpoint, requesting a registered service.

  • User_UL6AR
    User_UL6AR Member Posts: 14 Green Ribbon
    Answer ✓

    Hi Billy Verreynne,

    Thank you a lot for your reply. I was able to solve this issue. I re-installed Oracle 12c but I used the tools netmgr and catmgr to configure correctly the listener and the tnsnames.

    So when installing Oracle 12c do not modify by hand listener.ora and tnsnames.ora by hand. Thank you this issue is now solved.

    Kind regards.

  • Billy Verreynne
    Billy Verreynne Software Engineer Member Posts: 28,833 Red Diamond

    So when installing Oracle 12c do not modify by hand listener.ora and tnsnames.ora by hand.

    Not really true. Listener config is not a dark art. Customisation allows for extended features and flexibility.

    Thank you this issue is now solved.

    Good going - sticking to defaults is a good choice when dealing with a new product or technology.