我尝试在Docker容器中启动Oracle 12.x,但启动序列始终停留在log file is : /home/oracle/setup/log/untarDB.log
上,容器未正确启动。
我已经对版本www.example.com和12.2.0.1尝试了相同的步骤。12.1.0.2 and 12.2.0.1.
我所做的:
登录www.example.comcontainer-registry.oracle.com/database/enterprise:12.2.0.1
Oracle的Oracle凭据
1.登录www.example.com container-registry.oracle.com/database/enterprise:12.2.0.1
- Docker 拉动 container-registry.oracle.com/database/enterprise:12.2.0.1
1.对接程序运行-d-名称对接程序Ora122-p 1521:1521-p 5500:5500-e ORACLE字符集= AL32UTF8-e ORACLE SID = GENAL32UTF8-e ORACLE PDB = GENAL32UTF8PDB-e ORACLE PWD =密码123 www.example.com container-registry.oracle.com/database/enterprise:12.2.0.1
Docker container log shows:
2023-01-09 06:50:56 Setup Oracle Database
2023-01-09 06:50:56 Oracle Database 12.2.0.1 Setup
2023-01-09 06:50:56 Mon Jan 9 05:50:56 UTC 2023
2023-01-09 06:50:56
2023-01-09 06:50:56 Check parameters ......
2023-01-09 06:50:56 log file is : /home/oracle/setup/log/paramChk.log
2023-01-09 06:50:56 paramChk.sh is done at 0 sec
2023-01-09 06:50:56
2023-01-09 06:50:56 untar DB bits ......
2023-01-09 06:50:56 log file is : /home/oracle/setup/log/untarDB.log
而且安装卡住了。
如果对数据库www.example.com执行相同的步骤,则运行正常,Docker容器启动,Oracle数据库在此容器中创建。(docker pull container-registry.oracle.com/database/enterprise:19.3.0.0
)19.3.0.0 it works fine and docker conatainer is started and Oracle Database is created within this container. ( docker pull container-registry.oracle.com/database/enterprise:19.3.0.0
)
请告知12.x版本需要进行哪些更改才能正确启动Oracle Container。
1条答案
按热度按时间ovfsdjhp1#
您需要创建自己的本地映像。您不能使用DockerHub oracle映像,因为这些映像无效(不由Oracle维护)。
参考GitHub中的问题。例如:https://github.com/oracle/docker-images/issues/1165
请查找我为19.3执行的步骤。这些步骤源自文档https://github.com/oracle/docker-images/blob/main/OracleDatabase/SingleInstance/README.md
1.下载ZIP文件https://www.oracle.com/database/technologies/oracle-database-software-downloads.html- LINUX.X64_193000_db_home.zip
1.将LINUX.X64_193000_db_home.zip复制到克隆目录(例如,复制到c:\tmp\OracleDocker\docker-images\OracleDatabase\单示例\docker文件\19.3.0\LINUX.X64_193000_db_home.zip)a.运行文件https://github.com/oracle/docker-images/blob/main/OracleDatabase/SingleInstance/dockerfiles/buildContainerImage.sh(如果您在Windows上,请使用cygwin或WSL 2 Ubutnu)b. WSL Ubuntu
cd /mnt/c/tmp/OracledDocker/docker-images/OracleDatabase/SingleInstance/dockerfiles
./buildContainerImage.sh -v 19.3.0 -t oracle_ee_19.3.0 -e
命令行日志:
现在你应该可以在你的Docker中找到Docker图像了。例如
docker images
现在,您可以启动Oracle容器:
docker run -d --name DockerOra193 -p 1521:1521 -p 5500:5500 -e ORACLE_CHARACTERSET=AL32UTF8 -e ORACLE_SID=GENAL32UTF8 -e ORACLE_PDB=GENAL32UTF8PDB -e ORACLE_PWD=password123 oracle_ee_19.3.0