oracle/docker-images

`shutdown immediate` gives `listener does not currently know of service`

ZhouXing19 opened this issue · 0 comments

OS: Mac M1 Arm
Docker image: container-registry.oracle.com/database/enterprise:19.19.0.0
Docker start command:

docker run -d --name oracle -p 1521:1521 -p 5500:5500 -v ./docker/oracle-init/oracle-init.sql:/docker-entrypoint-initdb.d/setup/oracle-init.sql -v ./oracle-data:/opt/oracle/oradata   -e ORACLE_PWD=password container-registry.oracle.com/database/enterprise:19.19.0.0

I'm following this tutorial to enable Unified Auditing for oracle 19c. However, after I enter the sql console via sqlcl sys/password@//localhost:1521/ORCLCDB as sysdba (with sqlcl installed via https://download.oracle.com/otn_software/java/sqldeveloper/sqlcl-24.1.0.087.0929.zip), I got this error:

SQL> shutdown immediate;
Database closed.
Database dismounted.
ORACLE instance shut down.
Listener refused the connection with the following error:
ORA-12514, TNS:listener does not currently know of service requested in connect descriptor
  (CONNECTION_ID=PHcmW04YRpK2aaUaKHkOTg==)

Any idea how to solve this? Thanks!