前言:

  没什么特别的,就是快快快,如果你仅仅是需要一个oracle数据库来做测试,那就一路复制粘贴滚键盘,十分钟就可以拥有一个安装好的oracle11数据库

1,拉取镜像:

docker pull registry.cn-hangzhou.aliyuncs.com/helowin/oracle_11g

2.创建容器 

docker run -d -p 1521:1521 --name oracle11g registry.cn-hangzhou.aliyuncs.com/helowin/oracle_11g

3.进入镜像配置

docker exec -it oracle11g bash

su root;

密码:helowin

编辑环境变量:

vi /etc/profile
export ORACLE_HOME=/home/oracle/app/oracle/product/11.2.0/dbhome_2
export ORACLE_SID=helowin
export PATH=$ORACLE_HOME/bin:$PATH

创建软连接

ln -s $ORACLE_HOME/bin/sqlplus /usr/bin

source /etc/profile

切换到oracle 用户

sqlplus /nolog

conn /as sysdba

接着执行下面命令

alter user system identified by system;

alter user sys identified by sys;

 

4.重启容器后就可以直接用了

docker restart oracle11g

现在可以用system用户连接,密码:system

使用docker快速安装oracle

 最后,附上官方对docker安装oracle的建议,点我

相关文章:

  • 2021-12-27
  • 2022-02-06
  • 2021-05-17
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-07-10
  • 2022-12-23
  • 2022-01-13
  • 2019-01-01
  • 2021-11-12
  • 2021-12-25
  • 2022-01-24
相关资源
相似解决方案