欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页  >  IT编程

oracle12cPDB里建立的用户登录不上去,显示IO错误:Unknownhostspecified

程序员文章站 2022-08-22 23:18:39
连接失败, 错误报告: user = store url = jdbc:oracle:thin:@orclpdb 错误消息 = io 错误: unknown host specified 碰到这个问...

连接失败, 错误报告:

user = store

url = jdbc:oracle:thin:@orclpdb

错误消息 = io 错误: unknown host specified

碰到这个问题的童靴们,正解如下:

首先在 oracle enterprise manager database express 12c中查看容器名是

oracle12cPDB里建立的用户登录不上去,显示IO错误:Unknownhostspecified

然后在 $home$\product\12.2.0\dbhome_1\network\admin\tnsnames.ora中增加

orclpdb =

(description =

(address = (protocol = tcp)(host = localhost)(port = 1521))

(connect_data =

(server = dedicated)

(service_name = orclpdb)

)

)

这样,在登录的时候写@orclpdb就可以解析为本地host了,之前出现登录不了也就是无法解析到本地localhost