This content has been marked as final. Show 3 replies
"listener does not currently know of SID given in connect descriptor".
Or could also be SERVICE_NAME, when the database registers with a listener its service name will show in a `lsnrctl services` output, under the "Services Summary..." section.
That error indicates something incorrect with the client configuration, that is done in the tnsnames.ora file. Or possibly the database has not yet registered with the listener, maybe if the database was started first, but instance registration should eventually happen (perhaps within a minute or two) after the listener is started. Or one may force a listener registration to occur with a system connection and an`alter system register;' command.
If the out-of-the-box parameters that affect service registration and naming have not been changed the posted tnsnames.ora setup should work fine.
However, comma, the listener.ora HOST= address is the loopback IP. You won't be able to connect to the database using that address from anywhere but that host.
There may be another ORACLE_HOME installed and the tnsnames.ora file might not be the actual one in use. A `tnsping xe` will reveal the path to the client sqlnet.ora location in use.
The tnsping will verify if there is an oracle listener on the port at the IP address (or hostname) specified by the tnsalias details, in tnsnames.ora but it will not verify the SERVICE_NAME (or SID) specified. To verify the service name requires using an actual connection, i.e. sqlplus username[passwd]@xe.
Or on the database host, with the correct environment settings for $ORACLE_SID, $ORACLE_HOME, with $ORACLE_HOME/bin added to $PATH the ...@<tnsalias> part is not needed to get a connection.