Automatic Startup of Oracle DB on Windows
search cancel

Automatic Startup of Oracle DB on Windows

book

Article ID: 247176

calendar_today

Updated On:

Products

Data Loss Prevention

Issue/Introduction

You noticed that your Enforce console cannot connect to the DB and throws log in errors.

In "localhost.log" you see
"Caused by: oracle.net.ns.NetException: Listener refused the connection with the following error: ORA-12514, TNS:listener does not currently know of service requested in connect descriptor"

"lsnrctl status" in cmd does not show you running 'protect' account.

"
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=enforce.example.com)(PORT=1521)))
STATUS of the LISTENER
------------------------
Alias                       LISTENER
Version                   TNSLSNR for 64-bit Windows: Version 19.0.0.0.0 - Production
Start Date               02-AUG-2022 15:16:54
Uptime                    8 days 18 hr. 39 min. 21 sec
Trace Level             off
Security                  ON: Local OS Authentication
SNMP                     OFF
Listener Parameter File   C:\oracle\product\19.3.0.0\db_1\network\admin\listener.ora
Listener Log File         C:\oracle\diag\tnslsnr\Enforce\listener\alert\log.xml
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=Enforce.example.com)(PORT=1521)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\.\pipe\PROTECTipc)))
Services Summary...
Service "CLRExtProc" has 1 instance(s).
Instance "CLRExtProc", status UNKNOWN, has 1 handler(s) for this service...
The command completed successfully
"

Cause

Most probably DB AutoStart is disabled in registry.

Resolution

Services.msc

Service Properties: Set the Oracle service to startup type=automatic

RegEdit

Navigate to the key:
HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE\oracle_home_name and set the key ORA_<SID>_AUTOSTART=TRUE