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.47k stars 5.41k forks source link

Installation fails when using non-container mode #2201

Open Naros opened 2 years ago

Naros commented 2 years ago

When making the following changes to dbca.rsp.tmpl to use a non-containerized installation:

createAsContainerDatabase=false
numberOfPDBs=0

The installation fails because several SQL scripts/checks that are performed fail and Oracle treats the installation as unsuccessful and a restart of the container re-installs the database again. The problem scripts are:

The installation should allow the user to specify non-container support and install without the need to make modifications to the above two scripts before allowing the installation to commence in order for the installation to succeed.

checkDBStatus.sh

This script should return a 0 exit code or otherwise check something that is unrelated to PDBs.

createDB.sh

The following two SQL statements should be excluded when built without CDB support:

ALTER PLUGGABLE DATABASE $ORACLE_PDB SAVE STATE;

and

ALTER USER OPS\$oracle SET container_data=all for sys.v_\$pdbs container = current;
yunus-qureshi commented 2 years ago

@Naros Which version are you trying? Non container mode is not supported.

Naros commented 2 years ago

Hi @yunus-qureshi, I know this is problematic for Oracle 19 and 21. I don't recall if this was a problem on Oracle 12.

That said, I would strongly urge that you support non-container mode installations with your images. Deploying Oracle in an EE environment with no container support is still quite commonplace. For software providers like myself who need to test across a wide array of Oracle installations to verify/certify compliance, it would be much more useful if this deployment strategy was something that could more easily be managed via the installation process.

Right now we take the base images (prior to Oracle install) and explicitly overwrite the dbca.rsp.tmpl and the shell scripts mentioned here in order to get a non-container Oracle installation up and running successfully. Anything that can simplify that would be most welcomed.

GOODBOY008 commented 10 months ago

@Naros Hi, How can you solove this when build non-cdb?

Naros commented 10 months ago

Hi @GOODBOY008, if I recall correctly it required (at least on 19.3) to apply a custom dbca.rsp.tmpl, createDB.sh, and checkDBStatus.sh files before the installation started in order to create a non-CDB image.

oraclesean commented 10 months ago

Hi @GOODBOY008, if I recall correctly it required (at least on 19.3) to apply a custom dbca.rsp.tmpl, createDB.sh, and checkDBStatus.sh files before the installation started in order to create a non-CDB image.

There's a how-to for this in my book...