Public Repository

Last pushed: 4 months ago
Short Description
This is a Docker image with DB2 Express-C installed
Full Description
1. Pull the Docker image to local machine
docker pull cwds/db2:expc

Pulls the docker image with DB2 Express-C installed by default.

2. Start the container in docker daemon
The execution of the container should be in Privileged mode
docker run -it -d -P --privileged=true -p 50000:50000 cwds/db2:expc
  • -p 50000:50000 exposes port 50000 to allow connections from the host
3. Attach the container and Start DB2
To access the console, attach to the docker container
sudo docker attach <container ID / Name of the container>
Switch to DB2 user to start the DB2 instance and start the DB2
NOTE : the db2inst1 default password is 'db2inst1'
su - db2inst1 
db2start

Once the container is configured you can exit the container and keep it running with:

CTRL + P + Q

########################

docker run -d -p 50000:50000 -e DB2INST1_PASSWORD=db2inst1-pwd -e LICENSE=accept cwds/db2
if add -e DB2NAME=<DBNAME> you create new database

Docker Pull Command
Owner
cwds

Comments (0)