Use OracleDB Docker On Ubuntu(Mint)

From iDempiere en

Overview

I have test some script on oracle so i need a oracle database server.

docker hear good for save time.

utils/RUN_ImportIdempiere.sh need impdp, look over instant client just oracle 12c-release-2 include that util

so take docker from oracle xe 11g release 2

by compatible it don't work. ok take latest docker for this client at Oracle 12 release 2

it don't work also, because oracle 12 release 2 have new type of user Multi-tenant local vs. common users

i get idea from thread Idempiere with Oracle XE and 2 server

User docker oracle db for idempiere (r11 release 2)

install client

at page Oracle instant client scroll to "Version 11.2.0.4.0 "

download: Instant Client Package - Basic, Instant Client Package - Basic Light, Instant Client Package - SQL*Plus

extract to same folder call [ORACLE_CLIENT]

Setup Docker

guideline is clear Oracle database release 11 R2

Copy oracle server stuff for import to [ORACLE_CLIENT]

 sudo docker cp mystifying_wright:/u01/app/oracle-product/11.2.0/xe/bin/impdp [ORACLE_CLIENT]
 mkdir [ORACLE_CLIENT]/rdbms
 sudo docker cp mystifying_wright:/u01/app/oracle-product/11.2.0/xe/rdbms/mesg [ORACLE_CLIENT]/rdbms
 sudo chown -R $USER:$USER [ORACLE_CLIENT]/rdbms
 sudo chown $USER:$USER [ORACLE_CLIENT]/impdp
 

mystifying_wright is name of docker

Import database

1. you can take idempiere binary from community or build by yourself

assume you have it on [IDEMPIERE-HOME]

run console-setup-alt.sh remember that Differences_for_Oracle

2. open terminal and run

 SQL_PLUS_ROOT=[ORACLE_CLIENT]
 export LD_LIBRARY_PATH=$SQL_PLUS_ROOT:$LD_LIBRARY_PATH
 export PATH=$SQL_PLUS_ROOT:$PATH
 export NLS_LANG=AMERICAN_AMERICA.UTF8
 sed -i 's|sqlplus $1@$ADEMPIERE_DB_SERVER:$ADEMPIERE_DB_PORT/$ADEMPIERE_DB_NAME @$IDEMPIERE_HOME/utils/$ADEMPIERE_DB_PATH/CreateDataPumpDir.sql $IDEMPIERE_HOME/data/seed||' [IDEMPIERE-HOME]/utils/oracle/ImportIdempiere.sh
 # below command just one time
 sed -i 's|#chmod 770 $IDEMPIERE_HOME/data/seed|#chmod 770 $IDEMPIERE_HOME/data/seed\nsudo docker cp $IDEMPIERE_HOME/data/seed/Adempiere.dmp mystifying_wright:/u01/app/oracle/admin/XE/dpdump|' [IDEMPIERE-HOME]/utils/oracle/ImportIdempiere.sh
 sed -i 's|DIRECTORY=ADEMPIERE_DATA_PUMP_DIR|DIRECTORY=DATA_PUMP_DIR|' [IDEMPIERE-HOME]/utils/oracle/ImportIdempiere.sh
 cd [IDEMPIERE-HOME]/utils
 ./RUN_ImportIdempiere.sh

Reference

docker command

Oracle database release 11 R2

Oracle instant client

Cookies help us deliver our services. By using our services, you agree to our use of cookies.