解决The Network Adapter could not establish the connection

简介: 解决1 主机与虚拟机ping不通解决2 状态: 失败 -测试失败: IO 错误: The Network Adapter could not establish the connection本次尝试在主机连接虚拟机中的oracle12c,经过折腾后成功,总结如下:环境:VMware ,oracle12 ,主机和虚拟机均安装Windows10问题1

解决1 主机与虚拟机ping不通

解决2 状态: 失败 -测试失败: IO 错误: The Network Adapter could not establish the connection

本次尝试在主机连接虚拟机中的oracle12c,经过折腾后成功,总结如下:

环境:VMware ,oracle12 ,主机和虚拟机均安装Windows10

问题1 主机与虚拟机ping不通

1.关闭虚拟机的防火墙,主机不需要关闭。
这样,主机可以ping通虚拟机,而虚拟机ping不同主机。
2.连接模式,选择自定义中的VMnet8(NAT 模式)
本模式下虚拟机可以ping通主机(主意:主机不需要关闭防火墙)

tip1,如何查看本机ip

输入命令ipconfig
IPv4 地址 … … … … : 192.168.244.xxx
对应的为本机地址。

tip2 ,ping 目标机器ip

ping 192.168.244.xxx

解决2 状态: 失败 -测试失败: IO 错误: The Network Adapter could not establish the connection

从以下三个方面入手:
1. 检查格式是否正确,URL,全局名,密码等等

jdbc:oracle:thin:@192.168.186.xxx:1521:orcl

其中,thin为连接方式,192.168.186.xxx为安装了oracle12c的机器ip,1521是端口,orcl是全局名。
当然,还有username和password分别是你要连接的数据库如OLAPSYS和对应的密码(如何创建用户和修改登录权限,请查看Oracle创建用户、表(1)
2. jar包是否引用正确,如果用第三方连接如myeclipse。jar包位置在C:\app\orcl\product\12.1.0\dbhome_1\jdbc\lib
3. 添加该IP到监听器
3.1打开Net Manager
3.2添加新的IP和对应的1521端口
关闭,重启监听服务(实在怕麻烦,重启虚拟机就行)
3.3连接成功。

目录
相关文章
成功解决: Client network socket disconnected before secure TLS connection was established
这篇文章记录了在使用Avue时遇到的"Client network socket disconnected before secure TLS connection was established"错误的解决方法,即通过修改为国内镜像(如淘宝npm镜像)来解决安装问题,并提供了具体的命令示例以及安装成功后的截图。
成功解决: Client network socket disconnected before secure TLS connection was established
|
8月前
|
物联网
BLE 0x3e HCI_ERROR_CODE_CONN_FAILED_TO_ESTABLISH
BLE 0x3e HCI_ERROR_CODE_CONN_FAILED_TO_ESTABLISH
98 0
【已解决】kex_exchange_identification: Connection closed by remote host fatal: Could not read from
【已解决】kex_exchange_identification: Connection closed by remote host fatal: Could not read from
|
7月前
|
Linux 数据安全/隐私保护
Could not connect to ‘121.37.92.110‘ (port 22): Connection failed.
Could not connect to ‘121.37.92.110‘ (port 22): Connection failed.
|
SQL Oracle 关系型数据库
数据库连接报错之IO异常(The Network Adapter could not establish the connection)
有以下四个原因: 1. ORACLE数据库 1、oracle配置 listener.ora 和tnsnames.ora 文件里面查看是否配置正确
2811 1
|
Linux
七个办法只有一个有效:200 PORT command successful. Consider using PASV.425 Failed to establish connection.
七个办法只有一个有效:200 PORT command successful. Consider using PASV.425 Failed to establish connection.
642 0
七个办法只有一个有效:200 PORT command successful. Consider using PASV.425 Failed to establish connection.
|
SQL Oracle 关系型数据库
ORA-12514, TNS:listener does not currently know of service requested in connect descriptor案例2
今天使用SQL Developer连接一台测试服务器数据库(ORACLE 11g)时,遇到了“ORA-12514, TNS:listener does not currently know of service requested in connect descriptor”错误,具体提示如下所示:...
5421 0