Categories: Virtualization

How to Install Oracle 11g (EE) on Docker

This article represents instructions on how to install & configure Oracle 11g Database (Enterprise Edition) on Docker.

Well, I could have lived with installing Oracle 11g express edition, had I have the requirement of testing my application with Oracle database for single user. The primary reason for installing Oracle enterprise edition was to test the high availability using Oracle Data Guard solution. As we may knowing that Oracle Data Guard does not come with Oracle XE Database, thus, it becomes mandatory to work with Oracle EE Database edition which comes bundled with Data Guard solution.

The primary challenge in installing Oracle EE database on Docker is the disk space problem the installation runs into. To get around that problem, I would suggest you to read the page below and configure your docker environment appropriately.

Let’s get started with installing and configuration of oracle database.

  1. Download the following Oracle 12c docker image from https://github.com/wscherphof/oracle-12c. The image consist of three steps. Each step is a folder consisting of a Dockerfile and a couple of scripts which would be referred when Dockerfile gets executed.
  2. Download the Oracle 11G Database: One would be required to download the oracle linux 11g file from Oracle website (this Oracle 11G Linux Download page)
  3. Configure Boot2docker for greater Disk Space: Before getting started, you would want to take care of “disk space” issue which you would eventually run into, if you do not take care. For this purpose, one would require to configure boot2docker to allow image of larger size. This page, https://docs.docker.com/articles/b2d_volume_resize/ consists of instructions to configure boot2docker. Based on the instructions on the page, I increased the disksize to 100000.
  4. Customize the image for Oracle 11G: As the image is for building Oracle 12c (EE) database, one would require to make few changes to the Dockerfiles and scripts to make it work for Oracle 11g (EE) database. Following is required to be done.
    • Place the downloaded Oracle 11g zipped files (two files) in step1 folder.
    • Go to step1/Dockerfile, and change the oracle downloaded zip file names.
    • In step1 folder, change the db_install.rsp to 11.2.0 compatible db_install.rsp file. One could get a sample response file for 11g from web.
    • In step2 folder, change the step2/Dockerfile, step2/create and step2/initORCL.ora such that 12.1.0 is replaced with 11.2.0
    • Once done with above, go ahead and build and commit step 1, step2 and step 3 as per the instructions on the page.
    • You are all set to run the Oracle DB.
  5. Run the image into Docker Container: Individual oracle DB instance (docker run –privileged -ti -d -P –name primary -v /c/Users:/mnt/Users  oracle-12c:step3 /bin/bash). This would expose 1521, 5050, 8080 on random ports which could be used to connect to database. As a result of installation, “start” script is placed in “/tmp” folder. Thus, every time you start and attach the docker, execute the following command, “/tmp/start” to start the Oracle DB instance. In case, you want to start in the background, you could use following command: “nohup /tmp/start &”.
  6. Multiple oracle DB instance requiring to connect each other (docker run –privileged -ti -d -P –name standby -v /c/Users:/mnt/Users –link primary:primary oracle-12c:step3 /bin/bash)

Hope the instructions above would help you install, configure and run with Oracle 11g (EE) database on your laptop. Let me know if you needed any help.

Ajitesh Kumar

I have been recently working in the area of Data analytics including Data Science and Machine Learning / Deep Learning. I am also passionate about different technologies including programming languages such as Java/JEE, Javascript, Python, R, Julia, etc, and technologies such as Blockchain, mobile computing, cloud-native technologies, application security, cloud computing platforms, big data, etc. I would love to connect with you on Linkedin. Check out my latest book titled as First Principles Thinking: Building winning products using first principles thinking.

View Comments

  • Thanks for your comments. Well, I did not ponder upon this. My goal was primarily to have ready to work oracle 11G on Docker. I got myself very much productive after I got Oracle 11G installed on Dockers.

Share
Published by
Ajitesh Kumar

Recent Posts

Agentic Reasoning Design Patterns in AI: Examples

In recent years, artificial intelligence (AI) has evolved to include more sophisticated and capable agents,…

1 month ago

LLMs for Adaptive Learning & Personalized Education

Adaptive learning helps in tailoring learning experiences to fit the unique needs of each student.…

1 month ago

Sparse Mixture of Experts (MoE) Models: Examples

With the increasing demand for more powerful machine learning (ML) systems that can handle diverse…

2 months ago

Anxiety Disorder Detection & Machine Learning Techniques

Anxiety is a common mental health condition that affects millions of people around the world.…

2 months ago

Confounder Features & Machine Learning Models: Examples

In machine learning, confounder features or variables can significantly affect the accuracy and validity of…

2 months ago

Credit Card Fraud Detection & Machine Learning

Last updated: 26 Sept, 2024 Credit card fraud detection is a major concern for credit…

2 months ago