
- 拉取阿里云的 Oracle 镜像
docker pull registry.aliyuncs.com/helowin/oracle_11g
- 查看镜像是否下载成功
docker images
- 运行该镜像
docker run -d -p 1521:1521 --name oracle registry.aliyuncs.com/helowin/oracle_11g
- 进入容器
docker exec -it oracle /bin/bash
- 配置容器内的 Oracle 的环境变量和修改账户密码 ``
export ORACLE_HOME=/home/oracle/app/oracle/product/11.2.0/dbhome_2
export ORACLE_SID=helowin
export PATH=$ORACLE_HOME/bin:$PATH
- 切换 Oracle 用户
su oracle
- 设置数据库
alter user system identified by oracle;
alter user sys identified by oracle;
ALTER PROFILE DEFAULT LIMIT PASSWORD_LIFE_TIME UNLIMITED;
远程连接 Oracle 数据库
