oracle / docker-images

Official source of container configurations, images, and examples for Oracle products and projects
https://developer.oracle.com/use-cases/#containers
Universal Permissive License v1.0
6.58k stars 5.43k forks source link

=> ERROR [stage-2 2/4] RUN "/opt/oracle"/oraInventory/orainstRoot.sh && 1.3s ------ > [stage-2 2/4] RUN "/opt/oracle"/oraInventory/orainstRoot.sh && "/opt/oracle/product/19c/dbhome_1"/root.sh: #12 1.272 /bin/sh: /opt/oracle/oraInventory/orainstRoot.sh: No such file or directory ------ #2847

Open Quinnduong opened 2 months ago

Quinnduong commented 2 months ago

I got this error. while uploading Oracle Database container image to docker. Can you help me check it out

oraclesean commented 2 months ago

Will you please post the full error in a comment, along with information about your system and Docker version? Also, please share the contents of the ../SingleInstance/dockerfiles/19.3.0 directory?

lesterdgreat commented 1 month ago

I also encountered this issue. See below logs

Building image 'oracle_ee_19.3.0' ... [+] Building 157.2s (13/15) docker:default => [internal] load build definition from Dockerfile 0.0s => => transferring dockerfile: 5.06kB 0.0s => WARN: FromAsCasing: 'as' and 'FROM' keywords' casing do not match (line 25) 0.0s => [internal] load metadata for docker.io/library/oraclelinux:8 2.2s => [auth] library/oraclelinux:pull token for registry-1.docker.io 0.0s => [internal] load .dockerignore 0.0s => => transferring context: 2B 0.0s => CACHED [base 1/4] FROM docker.io/library/oraclelinux:8@sha256:e4370a68f94023d3a33b923553373d01ef775d9de3208b0d880fb449046f621e 0.0s => [internal] load build context 0.0s => => transferring context: 960B 0.0s => [base 2/4] COPY setupLinuxEnv.sh checkSpace.sh /opt/install/ 0.0s => [base 3/4] COPY runOracle.sh startDB.sh createDB.sh createObserver.sh dbca.rsp.tmpl setPassword.sh checkDBStatus.sh runUserScripts.sh relinkOracleBinary.sh configTcps.sh /opt/oracle/ 0.0s => [base 4/4] RUN chmod ug+x /opt/install/.sh && sync && /opt/install/checkSpace.sh && /opt/install/setupLinuxEnv.sh && rm -rf /opt/install 97.7s => [builder 1/2] COPY --chown=oracle:dba LINUX.ARM64_1919000_db_home.zip db_inst.rsp installDBBinaries.sh /opt/install/ 4.3s => [builder 2/2] RUN chmod ug+x "/opt/install"/.sh && sync && "/opt/install"/"installDBBinaries.sh" ee 40.7s => [stage-2 1/4] COPY --chown=oracle:dba --from=builder /opt/oracle /opt/oracle 7.1s => ERROR [stage-2 2/4] RUN "/opt/oracle"/oraInventory/orainstRoot.sh && "/opt/oracle/product/19c/dbhome_1"/root.sh 0.1s


[stage-2 2/4] RUN "/opt/oracle"/oraInventory/orainstRoot.sh && "/opt/oracle/product/19c/dbhome_1"/root.sh:
0.130 /bin/sh: /opt/oracle/oraInventory/orainstRoot.sh: No such file or directory


1 warning found (use docker --debug to expand):

View build details: docker-desktop://dashboard/build/default/default/axxntjj8lfgffmnk94y297ttp

ERROR: Oracle Database container image was NOT successfully created. ERROR: Check the output and correct any reported problems with the build operation.

For the docker version

rk23kg@APM3LMHNFV7LT71 dockerfiles % docker version Client: Version: 27.1.1 API version: 1.46 Go version: go1.21.12 Git commit: 6312585 Built: Tue Jul 23 19:54:12 2024 OS/Arch: darwin/arm64 Context: default

Server: Docker Desktop 4.33.0 (160616) Engine: Version: 27.1.1 API version: 1.46 (minimum version 1.24) Go version: go1.21.12 Git commit: cc13f95 Built: Tue Jul 23 19:57:14 2024 OS/Arch: linux/arm64 Experimental: false containerd: Version: 1.7.19 GitCommit: 2bf793ef6dc9a18e00cb12efb64355c2c9d5eb41 runc: Version: 1.7.19 GitCommit: v1.1.13-0-g58aa920 docker-init: Version: 0.19.0 GitCommit: de40ad0

lesterdgreat commented 1 month ago

For the data inside 19.3.0, I just cloned it in your github. I only added this oracle database which came from oracle site LINUX.ARM64_1919000_db_home.zip

lesterdgreat commented 1 month ago

Upon checking around, error was fixed when I did the following:

  1. In BuildContainerImage.sh, add the following parameters --ulimit nofile=65536:65536 in line 319 (you can see the changes in this link https://github.com/oracle/docker-images/pull/2809/commits/ffe9d9a55d3b2539e9ecd5e117eba482f732a97e)
  2. Add this in the dockerFile of folder 19.3.0, go to Environment variables and paste this line below WALLET_DIR

Execute the below command to validate OS version and then export CV_ASSUME_DISTID to the supported version of OEL for 19c

**CV_ASSUME_DISTID=OEL8**