With Oracle SQL-Developer I’m able to connect to my VMware CentOS 7 Oracle database ORCL.
if I try to connect with SQLPlus I’m told the realm doesn’t exist.
Any idea as to why I can connect with Oracle SQL-Developer and not SQLPlus on the same machine?
TNSPing resolves the SID/Service name without any problems.
C:oracleora11g11.2.0.2networkadminsqlnet.ora
Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP) (Host = 192.168.1.50) (Port = 1521))) (CONNECT_DATA = (SERVICE_NAME = ORCL)))
OK (10 msec)
Here’s the output from the SQLPlus connection attempt from the same machine that SQL-Developer is working without any issues.
C:oracleora11g11.2.0.2BIN>sqlplus system/password@orcl
SQL*Plus: Release 11.2.0.2.0 Production on Wed Jul 3 08:31:13 2019
Copyright (c) 1982, 2010, Oracle. All rights reserved.
ERROR:
ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
Linux-x86_64 Error: 2: No such file or directory
Additional information: 3640
Additional information: -2140813497
Process ID: 0
Session ID: 0 Serial number: 0
2
Answers
Your sqlplus command, try this:
In SQL Developer, once you’re connected, run this:
Make sure you’re actually trying to connect to the same database in SQLPlus, also make sure your $ORACLE_HOME and $ORACLE_SID are properly configured.
This looks like something is wrong with Oracle_Home or your listener.
Could you please – – LSNRCTL and check the status of the same.
If it is fine, then try to connect to sys: