Oracle XE 18C Express Edition Ora-12541 : TNS : No listener

6.6k views Asked by At

I installed Oracle XE 18C Express Edition on my Windows 10 and successefully connected to the pluggable database XEPDB1 the first time.After that, all my temptations to connect to this database have failed. The error I receive is :

Ora-12541 : TNS : No listener.

Checking the control pannel, all the following services are running: OracleOraDB18Home1MTSRecoveryService OracleOraDB18Home1TNSListener OracleServiceXE only the following service is not: OracleVssWriterXE. When i checked the default listener "xe" status I got:

LSNRCTL> status xe
Connexion α (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=****)(PORT=1521)))
TNS-12541: TNS : aucun processus d'Θcoute
 TNS-12560: TNS : erreur d'adaptateur de protocole
  TNS-00511: Pas de processus d'Θcoute
   64-bit Windows Error: 61: Unknown error
Connexion α (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1521)))
TNS-12541: TNS : aucun processus d'Θcoute
 TNS-12560: TNS : erreur d'adaptateur de protocole
  TNS-00511: Pas de processus d'Θcoute
   64-bit Windows Error: 2: No such file or directory

Here's the content of my listener.ora:

# listener.ora Network Configuration File: C:\app\windows\product\18.0.0\dbhomeXE\NETWORK\ADMIN\listener.ora
# Generated by Oracle configuration tools.

DEFAULT_SERVICE_LISTENER = XE

SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = CLRExtProc)
      (ORACLE_HOME = C:\app\windows\product\18.0.0\dbhomeXE)
      (PROGRAM = extproc)
      (ENVS = "EXTPROC_DLLS=ONLY:C:\app\windows\product\18.0.0\dbhomeXE\bin\oraclr18.dll")
    )
  )

XE =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = TCP)(HOST = ****)(PORT = 1521))
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
    )
  )

And here's my tnsnames.ora:

# tnsnames.ora Network Configuration File: C:\app\windows\product\18.0.0\dbhomeXE\NETWORK\ADMIN\tnsnames.ora
# Generated by Oracle configuration tools.

XE =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = ****)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = XE)
    )
  )

LISTENER_XE =
  (ADDRESS = (PROTOCOL = TCP)(HOST = ****)(PORT = 1521))


ORACLR_CONNECTION_DATA =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
    )
    (CONNECT_DATA =
      (SID = CLRExtProc)
      (PRESENTATION = RO)
    )
  )
1

There are 1 answers

0
Robin Kitchin On

Given the tnsnames.ora file you posted you need to add an entry for the XEPDB1 pluggable database.

copy the existing entry for XE and paste below the XE entry.

Edit the line XE = to read XEPDB1 = and edit the SERVICE_NAME line changing XE to XEPDB1

Save the changes, close the file, stop all the Oracle services, restart all the Oracle services and all should be well.