Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion OracleDatabase/SingleInstance/FAQ.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ An example would be: `docker run ... -e TZ="Europe/Vienna" oracle/database:12.2.

## Can I run Oracle Database containers on Apple M1 (Arm) devices?

Oracle Database 19c Enterprise Edition and 23ai Free Edition are now supported on ARM64 platforms. You will have to provide the installation binaries of [Oracle Database 19c](https://www.oracle.com/database/technologies/oracle19c-linux-arm64-downloads.html) and put them into the dockerfiles/19.3.0 folder before running the buildContainerImage.sh script.
Oracle Database 19c Enterprise Edition and 26ai Free Edition are now supported on ARM64 platforms. You will have to provide the installation binaries of [Oracle Database 19c](https://www.oracle.com/database/technologies/oracle19c-linux-arm64-downloads.html) and put them into the dockerfiles/19.3.0 folder before running the buildContainerImage.sh script.

## checkSpace.sh: ERROR - There is not enough space available in the container

Expand Down
48 changes: 24 additions & 24 deletions OracleDatabase/SingleInstance/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,17 @@ Sample container build files to facilitate installation, configuration, and envi
* [Running Oracle Database in a container](#running-oracle-database-in-a-container)
* [Running Oracle Database Enterprise and Standard Edition 2 in a container](#running-oracle-database-enterprise-and-standard-edition-2-in-a-container)
* [Securely specifying the password when using Podman (Supported from 19.3.0 onwards)](#securely-specifying-the-password-when-using-podman-supported-from-1930-onwards)
* [Encrypting the database password (Supported from 23ai onwards))](#encrypting-the-database-password-supported-from-23ai-onwards)
* [Encrypting the database password (Supported from 26ai onwards))](#encrypting-the-database-password-supported-from-26ai-onwards)
* [Selecting the Edition (Supported from 19.3.0 release)](#selecting-the-edition-supported-from-1930-release)
* [Setting the SGA and PGA memory (Supported from 19.3.0 release)](#setting-the-sga-and-pga-memory-supported-from-1930-release)
* [Setting the CPU_COUNT and PROCESSES (Supported from 19.3.0 release)](#setting-the-cpu_count-and-processes-supported-from-1930-release)
* [Changing the admin accounts passwords](#changing-the-admin-accounts-passwords)
* [Enabling archive log mode and/or force logging mode while creating the database](#enabling-archive-log-mode-andor-force-logging-mode-while-creating-the-database)
* [Configuring TCPS connections for Oracle Database (Supported from version 19.3.0 onwards)](#configuring-tcps-connections-for-oracle-database-supported-from-version-1930-onwards)
* [Running Oracle Database 23ai Free in a container](#running-oracle-database-23ai-free-in-a-container)
* [Running Oracle Database 26ai Free in a container](#running-oracle-database-26ai-free-in-a-container)
* [Running Oracle Database 21c/18c Express Edition in a container](#running-oracle-database-21c18c-express-edition-in-a-container)
* [Running Oracle Database 11gR2 Express Edition in a container](#running-oracle-database-11gr2-express-edition-in-a-container)
* [Running Oracle True Cache in a container (Supported from version 23ai onwards)](#running-oracle-true-cache-in-a-container-supported-from-version-23ai-onwards)
* [Running Oracle True Cache in a container (Supported from version 26ai onwards)](#running-oracle-true-cache-in-a-container-supported-from-version-26ai-onwards)
* [Setting Up the Network for Communication Between the Primary Database and the True Cache Container](#setting-up-the-network-for-communication-between-the-primary-database-and-the-true-cache-container)
* [Running Oracle Database Free True Cache in a Container](#running-oracle-database-free-true-cache-in-a-container)
* [Containerizing an on-premise database (Supported from version 19.3.0 release)](#containerizing-an-on-premise-database-supported-from-version-1930-release)
Expand All @@ -36,7 +36,7 @@ Sample container build files to facilitate installation, configuration, and envi

This project offers sample Dockerfiles for:

* Oracle Database 23ai (23.9.0) Free
* Oracle Database 26ai (23.26.0) Free
* Oracle Database 21c (21.3.0) Enterprise Edition, Standard Edition 2 and Express Edition (XE)
* Oracle Database 19c (19.3.0) Enterprise Edition and Standard Edition 2
* Oracle Database 18c (18.4.0) Express Edition (XE)
Expand All @@ -51,10 +51,10 @@ The `buildContainerImage.sh` script is just a utility shell script that performs

### Building Oracle Database container images

**IMPORTANT:** You will have to provide the installation binaries of Oracle Database (except for Oracle Database 18c XE, 21c XE and 23ai Free) and put them into the `dockerfiles/<version>` folder.
**IMPORTANT:** You will have to provide the installation binaries of Oracle Database (except for Oracle Database 18c XE, 21c XE and 26ai Free) and put them into the `dockerfiles/<version>` folder.
You only need to provide the binaries for the edition you are going to install. The binaries can be downloaded from the [Oracle Technology Network](http://www.oracle.com/technetwork/database/enterprise-edition/downloads/index.html), make sure you use the linux link: *Linux x86-64*. The needed file is named *linuxx64_\<version\>_database.zip*.

**Linux ARM64 Support:** Oracle Database 19c Enterprise Edition and 23ai Free Edition are now supported on ARM64 platforms. You will have to provide the installation binaries of [Oracle Database 19c](https://www.oracle.com/database/technologies/oracle19c-linux-arm64-downloads.html) and put them into the dockerfiles/19.3.0 folder. The needed file is named *LINUX.ARM64_1919000_db_home.zip*.
**Linux ARM64 Support:** Oracle Database 19c Enterprise Edition and 26ai Free Edition are now supported on ARM64 platforms. You will have to provide the installation binaries of [Oracle Database 19c](https://www.oracle.com/database/technologies/oracle19c-linux-arm64-downloads.html) and put them into the dockerfiles/19.3.0 folder. The needed file is named *LINUX.ARM64_1919000_db_home.zip*.

You also have to make sure to have internet connectivity for yum. Note that you must not uncompress the binaries. The script will handle that for you and fail if you uncompress them manually!

Expand All @@ -67,7 +67,7 @@ Before you build the image make sure that you have provided the installation bin

Parameters:
-v: version to build
Choose one of: 11.2.0.2 12.1.0.2 12.2.0.1 18.3.0 18.4.0 19.3.0 21.3.0 23.9.0
Choose one of: 11.2.0.2 12.1.0.2 12.2.0.1 18.3.0 18.4.0 19.3.0 21.3.0 23.26.0
-t: image_name:tag for the generated docker image
-e: creates image based on 'Enterprise Edition'
-s: creates image based on 'Standard Edition 2'
Expand Down Expand Up @@ -147,10 +147,10 @@ To run your Oracle Database image use the `docker run` command as follows:
-p: The port mapping of the host port to the container port.
The following ports are exposed: 1521 (Oracle Listener), 5500 (OEM Express), 2484 (TCPS Listener Port if TCPS is enabled).
--ulimit: Resource limits. Update according to Oracle Database documentation.
-e ORACLE_SID: The Oracle Database SID that should be used (default for 23ai Free Edition: FREE; all others, ORCLCDB).
Note: The ORACLE_SID for 11g/18c Express and 23ai Free Editions cannot be changed.
-e ORACLE_PDB: The Oracle Database PDB name that should be used (default for 23ai Free Edition: FREEPDB1; all others, ORCLPDB1).
Note: The ORACLE_PDB for 23ai Free Edition cannot be changed.
-e ORACLE_SID: The Oracle Database SID that should be used (default for 26ai Free Edition: FREE; all others, ORCLCDB).
Note: The ORACLE_SID for 11g/18c Express and 26ai Free Editions cannot be changed.
-e ORACLE_PDB: The Oracle Database PDB name that should be used (default for 26ai Free Edition: FREEPDB1; all others, ORCLPDB1).
Note: The ORACLE_PDB for 26ai Free Edition cannot be changed.
-e ORACLE_PWD: The Oracle Database SYS, SYSTEM and PDBADMIN password (default: auto generated).
-e INIT_SGA_SIZE:
The total memory in MB that should be used for all SGA components (optional).
Expand Down Expand Up @@ -181,7 +181,7 @@ To run your Oracle Database image use the `docker run` command as follows:
Supported by Oracle Database 19.3 onwards.
-e ENABLE_FORCE_LOGGING:
To enable force logging mode when creating the database (default: false).
Supported by Oracle Database 23ai onwards.
Supported by Oracle Database 26ai onwards.
-e ENABLE_TCPS:
To enable TCPS connections for Oracle Database.
Supported by Oracle Database 19.3 onwards.
Expand Down Expand Up @@ -221,7 +221,7 @@ The Oracle Database inside the container also has Oracle Enterprise Manager Expr
# Running the Oracle Database 21c XE image with the secret
podman run -d --name=<container_name> --secret=oracle_pwd oracle/database:21.3.0-xe

##### Encrypting the database password (Supported from 23ai onwards)
##### Encrypting the database password (Supported from 26ai onwards)

Users can generate public-private key pair and pass database password (encrypted) and decryption (private) key to the container securely.

Expand All @@ -245,9 +245,9 @@ Users can generate public-private key pair and pass database password (encrypted
podman secret create oracle_pwd encrypted_pwd.txt
podman secret create oracle_pwd_privkey key.pem

* Run the Oracle Database 23ai Free image with the secrets
* Run the Oracle Database 26ai Free image with the secrets

podman run -td --name=<container_name> --secret=oracle_pwd --secret=oracle_pwd_privkey oracle/database:23.9.0-free
podman run -td --name=<container_name> --secret=oracle_pwd --secret=oracle_pwd_privkey oracle/database:23.26.0-free

#### Selecting the Edition (Supported from 19.3.0 release)

Expand Down Expand Up @@ -357,9 +357,9 @@ To configure wallet password, please use the following command:
After certificate renewal, the client wallet should be updated by downloading it again.
* Supports Oracle Database XE version 21.3.0 onwards.

#### Running Oracle Database 23ai Free in a container
#### Running Oracle Database 26ai Free in a container

To run your Oracle Database 23ai Free container image use the `podman run` command as follows:
To run your Oracle Database 26ai Free container image use the `podman run` command as follows:

podman run --name <container name> \
-p <host port>:1521 \
Expand All @@ -368,7 +368,7 @@ To run your Oracle Database 23ai Free container image use the `podman run` comma
-e ENABLE_ARCHIVELOG=true \
-e ENABLE_FORCE_LOGGING=true \
-v [<host mount point>:]/opt/oracle/oradata \
oracle/database:23.9.0-free
oracle/database:23.26.0-free

Parameters:
--name: The name of the container (default: auto generated)
Expand Down Expand Up @@ -403,7 +403,7 @@ On the first startup of the container a random password will be generated for th
podman exec <container name> /opt/oracle/setPassword.sh <your password>

**Important Note:**
The ORACLE_SID for Oracle Database 23ai Free is always `FREE` and the PDB_NAME is always `FREEPDB1`. They cannot be changed, hence there are no ORACLE_SID or PDB_NAME parameters provided for the Free build.
The ORACLE_SID for Oracle Database 26ai Free is always `FREE` and the PDB_NAME is always `FREEPDB1`. They cannot be changed, hence there are no ORACLE_SID or PDB_NAME parameters provided for the Free build.

#### Running Oracle Database 21c/18c Express Edition in a container

Expand Down Expand Up @@ -500,7 +500,7 @@ Once the container has been started you can connect to it just like to any other
sqlplus sys/<your password>@//localhost:1521/XE as sysdba
sqlplus system/<your password>@//localhost:1521/XE

### Running Oracle True Cache in a container (Supported from version 23ai onwards)
### Running Oracle True Cache in a container (Supported from version 26ai onwards)

Oracle True Cache is an in-memory, consistent, and automatically managed cache for Oracle Database. For more information about Oracle True Cache please see the [Oracle True Cache Online Documentation](https://docs.oracle.com/en/database/oracle/oracle-database/23/odbtc/overview-oracle-true-cache.html).

Expand Down Expand Up @@ -533,7 +533,7 @@ Set up a podman network for inter-container communication using the following co
-e ENABLE_ARCHIVELOG=true \
-e ENABLE_FORCE_LOGGING=true \
-v [<host mount point>:]/opt/oracle/oradata \
oracle/database:23.9.0-free
oracle/database:23.26.0-free

Ensure that your Primary Database container is up and running and in a healthy state.

Expand All @@ -552,14 +552,14 @@ You need to run the preceding podman run command with the host mount point (empt
-e PRIMARY_DB_PWD_FILE=/var/tmp/orapwFREE \
-e PRIMARY_DB_CONN_STR=<PRI_DB_FREE_IP>:1521/FREE \
-v [<host mount point>:]/opt/oracle/oradata \
oracle/database:23.9.0-free
oracle/database:23.26.0-free

**Note:** If a common host mount point is used for both pri-db-free and tru-cc-free containers, then you may skip the podman cp step by specifying the location of pri-db-free password file directly using \
-e PRIMARY_DB_PWD_FILE=/opt/oracle/product/23ai/dbhomeFree/dbs/orapwFREE
-e PRIMARY_DB_PWD_FILE=/opt/oracle/product/26ai/dbhomeFree/dbs/orapwFREE

* For different host mount points, copy password file (example 'orapwFREE') from the Primary Database container to the True Cache container at location $PRIMARY_DB_PWD_FILE (/var/tmp/orapwFREE) using podman cp command as follows:

podman cp pri-db-free:/opt/oracle/product/23ai/dbhomeFree/dbs/orapwFREE tru-cc-free:/var/tmp/
podman cp pri-db-free:/opt/oracle/product/26ai/dbhomeFree/dbs/orapwFREE tru-cc-free:/var/tmp/

* Once the True Cache container turns healthy, create database application services (sales_tc and sales_pdb_tc) for the True Cache by running the following commands from the pri-db-free container:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#
# ORACLE DOCKERFILES PROJECT
# --------------------------
# This is the Contatinerfile for Oracle Database 23ai Free
# This is the Contatinerfile for Oracle Database 26ai Free
#
# REQUIRED FILES TO BUILD THIS IMAGE
# ----------------------------------
Expand All @@ -13,16 +13,25 @@
# HOW TO BUILD THIS IMAGE
# -----------------------
# Run:
# $ podman build -t oracle/database:23.9.0-free -f Containerfile.free .
# $ podman build -t oracle/database:23.26.0-free -f Containerfile.free .
#
#
# Pull base image
# ---------------
FROM oraclelinux:8 as base
ARG BASE_IMAGE=oraclelinux:9
# hadolint ignore=DL3006
FROM ${BASE_IMAGE} as base

# Labels
# ------
LABEL "provider"="Oracle" \
"maintainer"="Oracle Database Container Team <container-team_ww@oracle.com>" \
"vendor"="Oracle Corporation" \
"version"="23.26.0" \
"release"="Free" \
"name"="Oracle AI Database 26ai Free" \
"summary"="Oracle AI Database 26ai Free" \
"description"="Oracle AI Database 26ai Free is a fully functional version of Oracle AI Database 26ai for developers to learn, build, and deploy applications." \
"issues"="https://github.com/oracle/docker-images/issues" \
"volume.data"="/opt/oracle/oradata" \
"volume.setup.location1"="/opt/oracle/scripts/setup" \
Expand All @@ -31,19 +40,19 @@ LABEL "provider"="Oracle" \
"volume.startup.location2"="/docker-entrypoint-initdb.d/startup" \
"port.listener"="1521"

ARG INSTALL_FILE_1="https://download.oracle.com/otn-pub/otn_software/db-free/oracle-database-free-23ai-23.9-1.el8.x86_64.rpm"
ARG INSTALL_FILE_1="https://download.oracle.com/otn-pub/otn_software/db-free/oracle-ai-database-free-26ai-23.26.0-1.el9.x86_64.rpm"

# Environment variables required for this build (do NOT change)
# -------------------------------------------------------------
ENV ORACLE_BASE=/opt/oracle \
ORACLE_HOME=/opt/oracle/product/23ai/dbhomeFree \
ORACLE_HOME=/opt/oracle/product/26ai/dbhomeFree \
ORACLE_SID=FREE \
INSTALL_FILE_1=$INSTALL_FILE_1 \
RUN_FILE="runOracle.sh" \
PWD_FILE="setPassword.sh" \
CREATE_DB_FILE="createDB.sh" \
USER_SCRIPTS_FILE="runUserScripts.sh" \
CONF_FILE="oracle-free-23ai.conf" \
CONF_FILE="oracle-free-26ai.conf" \
CHECK_SPACE_FILE="checkSpace.sh" \
CHECK_DB_FILE="checkDBStatus.sh" \
DB_STARTED_MARKER_FILE="/dev/shm/.db_started" \
Expand Down Expand Up @@ -101,15 +110,20 @@ FROM base
USER oracle
COPY --chown=oracle:oinstall --from=builder $ORACLE_BASE $ORACLE_BASE
COPY --chown=oracle:oinstall --from=builder /etc/oratab /etc/oratab
COPY --from=builder /etc/init.d/oracle-free-23ai /etc/init.d/oracle-free-23ai
COPY --from=builder /usr/share/doc/oracle-free-23ai/LICENSE /usr/share/doc/oracle-free-23ai/LICENSE
COPY --from=builder /etc/init.d/oracle-free-26ai /etc/init.d/oracle-free-26ai
COPY --from=builder /usr/share/doc/oracle-free-26ai/LICENSE /usr/share/doc/oracle-free-26ai/LICENSE

USER root
# To enforce ORACLE_SID as FREE, adding it to .bashrc
RUN $ORACLE_BASE/oraInventory/orainstRoot.sh && \
$ORACLE_HOME/root.sh && \
echo 'export ORACLE_SID=FREE' >> /home/oracle/.bashrc && \
chown oracle.oinstall /home/oracle/.bashrc
chown oracle.oinstall /home/oracle/.bashrc && \
mkdir /licenses && \
cp /usr/share/doc/oracle-free-26ai/LICENSE /licenses/license.txt && \
chmod -R 644 /licenses/license.txt && \
rm -rf /tmp/* /var/tmp/*


USER oracle
WORKDIR /home/oracle
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ EOF
su -c "sed -i -e \"s|^CHARSET=.*$|CHARSET=$ORACLE_CHARACTERSET|g\" /etc/sysconfig/\"$CONF_FILE\""

# Creating database for FREE edition
su -c '/etc/init.d/oracle-free-23ai configure << EOF
su -c '/etc/init.d/oracle-free-26ai configure << EOF
${ORACLE_PWD}
${ORACLE_PWD}
EOF
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# This is a configuration file to setup the Oracle Database.
# It is used when running '/etc/init.d/oracle-free-23ai configure'.
# It is used when running '/etc/init.d/oracle-free-26ai configure'.

# LISTENER PORT used Database listener, Leave empty for automatic port assignment
LISTENER_PORT=1521
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ if [ -f "$ORACLE_BASE"/oradata/.${ORACLE_SID}"${CHECKPOINT_FILE_EXTN}" ] && [ -d

# Start database
if [ "${ORACLE_SID}" = "FREE" ]; then
su -c '/etc/init.d/oracle-free-23ai start'
su -c '/etc/init.d/oracle-free-26ai start'
else
"$ORACLE_BASE"/"$START_FILE";
fi
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,11 @@ ln -s "$ORACLE_BASE"/scripts /docker-entrypoint-initdb.d && \
mkdir -p "$ORACLE_BASE"/oradata /home/oracle && \
mkdir -p "$ORACLE_HOME" && \
chmod ug+x "$ORACLE_BASE"/*.sh && \
dnf install -y oraclelinux-developer-release-el8 && \
if [ "$(arch)" == "aarch64" ] || [ "$(arch)" == "arm64" ]; then
dnf install -y oraclelinux-developer-release-el8
else
dnf install -y oraclelinux-developer-release-el9
fi && \
dnf -y install oracle-database-preinstall-23ai openssl hostname file expect && \
rm -rf /var/cache/yum && \
ln -s "$ORACLE_BASE"/"$PWD_FILE" /home/oracle/ && \
Expand Down
Loading