Skip to content

Instantly share code, notes, and snippets.

@oehrlis
Created August 30, 2023 13:13
Show Gist options
  • Save oehrlis/08e5f021b9f27b84cbd2ede6267dc2f0 to your computer and use it in GitHub Desktop.
Save oehrlis/08e5f021b9f27b84cbd2ede6267dc2f0 to your computer and use it in GitHub Desktop.
Manuel fix Oracle DB container

Manually fix / configure a few things which have not been added to the Oracle Database Container

export CON_NAME='cdbua190'

Install missing packages:

docker exec -it -u root $CON_NAME yum install -y hostname rlwrap

Change basenv profile and SID table order

docker exec -it $CON_NAME sed -i 's/30/10/' /u00/app/oracle/local/dba/etc/sidtab
docker exec -it $CON_NAME sed -i '/^if.*grid/,/^export BE_INITIALSID/d;' /home/oracle/.bash_profile

Do the whole stuff for a bunch of container

for i in tua190 cdbua190; do
  docker exec -it -u root $i yum install -y hostname rlwrap
  docker exec -it $i sed -i 's/30/10/' /u00/app/oracle/local/dba/etc/sidtab
  docker exec -it $i sed -i '/^if.*grid/,/^export BE_INITIALSID/d;' /home/oracle/.bash_profile
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment