Linux install Oracle VM container and other hosts for LAN access query

This paper relates to the mounting Docker Oracle container is provided host ports can achieve the LAN connection terminal on an Oracle database, illustrated as follows:

First, on mounting oracle Docker Bowen container may refer to the following:

https://blog.csdn.net/qq_38380025/article/details/80647620

This paper needs attention is the establishment of container does not use the directory to mount:

RUN -d -p Docker 1521 : 1521 --name oracle11g registry.cnhangzhou.aliyuncs.com/helowin/oracle_11g 
# original directory is not a member mount technology

Without the use of directory is mounted, the container should the crash can not enter, then the database file will not be read, it can be mounted inside the container to map oracle database files to a directory on the host create a directory,

Even in this case the container collapse out, still can be read on CentOS host to an Oracle database files, it is recommended to build container as follows:

docker run -d -p 1521:1521 -v /root/oracle:/home/oracle/app/oracle/oradata --name oracle11g_2 registry.cn-hangzhou.aliyuncs.com/helowin/oracle_11g
#oradata the home directory for the oracle database files, the folder mount root / the host / oracle

Also on Docker establishment MySQL container may refer to a lower portion of the articles of the present blog Bowen:

https://www.cnblogs.com/rango-lhl/p/12293100.html

 

Two, Win host and other LAN hosts to achieve access to the Oracle database

win host connection on a virtual machine that is used locally oracle oracle plsql connect to the server, the problem lies in setting a virtual machine port, connect to the server oracle can see below this, just say here that the port settings problem.

https://blog.csdn.net/qq_21875331/article/details/82890183

Virtual machine port settings:

 

 

 

 CentOS should be noted when establishing selection NAT model, the establishment of Oracle Docker container after opening firewall ports 1521 and 1521 where the host port mapping to Win 1521 port.

Win control panel to enter the next host firewall settings, open port 1521 inbound rules:

 

 New Rule Select the port:

 

 Upon completion, the other hosts in the LAN access Oracle databases only need to use Win to Host IP: 192.168.0.105: 1521

Guess you like

Origin www.cnblogs.com/rango-lhl/p/12310379.html