Closed KidA001 closed 7 years ago
I had to modify $ORACLE_HOME/network/admin/*.ora files to listen to 0.0.0.0 instead of the hostname. Does that make sense ?
@anilsamuel this is my tnsnames.ora
ORCL =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.99.100)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = XE)
)
)
Generally localhost/0.0.0.0 doesn't work for me, are you suggesting to change 192.168.99.100
to 0.0.0.0
?
yes, change 192.168.99.100 to 0.0.0.0.
I would commit my changes once I got it working; else you would loose on docker container shutdown
Interesting...I started getting a different error (ORA-21561: OID generation failed) when I used:
sqlplus system/oracle@//192.168.99.100:1521/xe
... note xe
at the end instead of xe.oracle.docker
I looked up the ORA-21561: OID generation failed
error and found this post on stackoverflow. I updated my /etc/hosts
file entry for localhost from
127.0.0.1 localhost
to 127.0.0.1 localhost MacBook-Pro-2.local
Now I'm able to connect with sqlplus system/oracle@//192.168.99.100:1521/xe
@anilsamuel
@KidA001 Where is the tnsnames.ora you put? I can not find a folder like network/admin. Which is the $ORACLE_HOME? mounted on /u01/app/oracle?
I get
ERROR: ORA-12514: TNS:listener does not currently know of service requested in connect descriptor
everytime I try to connect via sqlplusOn my machine I run
docker run --shm-size=1024MB -d -p 8080:8080 -p 1521:1521 sath89/oracle-12c
Logs show:
When I log onto the docker machine through
docker exec -i -t <container_id> bash
I can successfully runsqlplus system/oracle@localhost:1521/xe
When I'm on my local machine and try and run that, it cannot connect:
sqlplus system/oracle@//192.168.99.100:1521/xe.oracle.docker
orsqlplus system/oracle@//192.168.99.100:1521/xe
orsqlplus system/oracle@192.168.99.100:1521/xe
all give me the sameORA-12162: TNS:net service name is incorrectly specified
error.192.168.99.100
is mydocker-machine ip
. Same happens if I trylocalhost
I can successfully connect to the web portal at
http://192.168.99.100:8080/em
and loginAny help appreciated