Oracle XE stopped working. TNS listener refused connection
On Windows 7 64 bit, Orcale XE 11 my OracleXXETNSListener service was not running and did terminate immediately when I tried to start it.
- Adding
(SID_DESC = (SID_NAME = XE) (ORACLE_HOME = C:\oraclexe\app\oracle\product\11.2.0\server) )
to my
C:\oraclexe\app\oracle\product\11.2.0\server\network\ADMIN\listener.ora
changing the hostname to localhost
restarting the OracleServiceXE service under System - Services solved the issue.
So the complete listener.ora section looks like:
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(SID_NAME = PLSExtProc)
(ORACLE_HOME = C:\servers\oraclexe\app\oracle\product\11.2.0\server)
(PROGRAM = extproc)
)
(SID_DESC =
(SID_NAME = CLRExtProc)
(ORACLE_HOME = C:\servers\oraclexe\app\oracle\product\11.2.0\server)
(PROGRAM = extproc)
)
(SID_DESC =
(SID_NAME = XE)
(ORACLE_HOME = C:\servers\oraclexe\app\oracle\product\11.2.0\server)
)
)
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
)
)
DEFAULT_SERVICE_LISTENER = (XE)
Update: Now it is 5 years later and I had the same issue with OracleXE 18c on Win10. The TNS listener would not start right after successful installation because oracleXE\dbhomeXE\NETWORK\ADMIN\listener.ora was pointing to localhost.docker.internal instead of localhost.
I had a similar problem, and I fixed it by removing the "IPC" lines from both listener.ora and tnsnames.ora.
On listener.ora
, I removed:
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
On tnsnames.ora
, I removed:
EXTPROC_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
)
(CONNECT_DATA =
(SID = PLSExtProc)
(PRESENTATION = RO)
)
)
It may have been a overkill, but it's finally fixed, after several hours!
I had the exact same problem and after spending almost 4 hours trying to find and answer, finally adding
(SID_DESC =
(SID_NAME = XE)
(ORACLE_HOME = C:\oraclexe\app\oracle\product\11.2.0\server)
)
to my listener.ora and restarting both XE services solved the issue. I am using 11.2.0 (XE) on windows 7 x64 with out any hitch till yesterday. A reboot of my PC this morning caused the listener to not find the SID.
Now I am backing up both listener.ora and tnsnames.ora.
btw, forgot to mention I changed the hostname in both the files from bob.mycompany.com to localhost.