51Testing软件测试论坛
标题: 基于docker搭建oracle服务器 [打印本页]
作者: 巴黎的灯光下 时间: 2019-6-19 17:20
标题: 基于docker搭建oracle服务器
基于docker搭建oracle服务器拉取镜像
- docker pull wnameless/oracle-xe-11g
复制代码这个比较耗时,中间可能会中断,继续拉取即可
启动实例注意将selinux关掉,不然实例启动失败
- 修改/etc/selinux/config文件,设置为disable
- # disabled - No SELinux policy is loaded.
- SELINUX=disable
复制代码启动
- docker run -d -p 49160:22 -p 49161:1521 wnameless/oracle-xe-11g
复制代码49160是ssh访问端口,初始密码admin
49161是数据库访问端口
实例信息
- hostname: localhost
- port: 49161
- sid: xe
- username: system/sys
- password: oracle
复制代码至此服务端安装完成
客户端访问
安装完成client,启动pl-sql
设置oracle安装路径
[attach]125299[/attach]然后登录页会出现
[attach]125300[/attach]
配置服务名
[attach]125301[/attach]
也可以直接写文件oracle\product\11.2.0\dbhome_1\NETWORK\ADMIN\tnsnames.ora
- # tnsnames.ora Network Configuration File: F:\installsoft\oracle\product\11.2.0\dbhome_1\network\admin\tnsnames.ora
- # Generated by Oracle configuration tools.
- XE =
- (DESCRIPTION =
- (ADDRESS_LIST =
- (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.2.201)(PORT = 49161))
- )
- (CONNECT_DATA =
- (SERVICE_NAME = xe)
- )
- )
- ORACLR_CONNECTION_DATA =
- (DESCRIPTION =
- (ADDRESS_LIST =
- (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
- )
- (CONNECT_DATA =
- (SID = CLRExtProc)
- (PRESENTATION = RO)
- )
- )
复制代码
作者: Miss_love 时间: 2019-6-20 09:05
欢迎光临 51Testing软件测试论坛 (http://bbs.51testing.com/) |
Powered by Discuz! X3.2 |