Docker image for Oracle Database 18c Express Edition (XE)
1.1K
Created from fuzziebrain/docker-oracle-xe
Note: first run will take a a while due to the oracle-xe configure script that needs to complete
docker run -d \
-p 32118:1521 \
-p 35518:5500 \
--name=oracle-xe \
--volume ~/docker/oracle-xe:/opt/oracle/oradata \
paddan66/oracle-xe
# As this takes a long time to run you can keep track of the initial installation by running:
docker logs oracle-xe
Run parameters:
| Name | Required | Description |
|---|---|---|
-p 1521 | Required | TNS Listener. 32118:1521 maps 32118 on your laptop to 1521 on the container. |
-p 5500 | Optional | Enterprise Manager (EM) Express. 35518:5500 maps 35518 to your laptop to 5500 on the container. You can then access EM via https://localhost:35518/em |
--name | Optional | Name of container. Optional but recommended |
--volume /opt/oracle/oradata | Optional | (recommended) If provided, data files will be stored here. If the container is destroyed can easily rebuild container using the data files. |
--network | Optional | If other containers need to connect to this one (ex: ORDS) then they should all be on the same docker network. |
oracle-xe:18c | Required | This is the name:tag of the docker image that was built in the previous step |
# Status:
# Look under the STATUS column for "(health: ...".
docker ps
# Start container
docker start oracle-xe
# Stop container
docker stop -t 200 oracle-xe
Note sqlcl is an alias for SQLcl. Can also use sqlplus
-- Connect to CDB
sqlcl system/Oracle18@localhost:32118/XE as sysdba
-- Connect to default PDB
sqlcl system/Oracle18@localhost:32118/XEPDB1 as sysdba
In some cases you may need to login to the server to modify or test something on the file system.
docker exec -it oracle-xe bash -c "source /home/oracle/.bashrc; bash"
# Once connected to run sqlplus:
$ORACLE_HOME/bin/sqlplus system/Oracle18@localhost/XE as sysdba
$ORACLE_HOME/bin/sqlplus system/Oracle18@localhost/XEPDB1 as sysdba
# Listener start/stop
$ORACLE_HOME/bin/lsnrctl stop
$ORACLE_HOME/bin/lsnrctl start
Content type
Image
Digest
Size
5.3 GB
Last updated
over 7 years ago
docker pull paddan66/oracle-xe