电脑奇才!我已经搜索了几天,并应用了我找到的多种解决方案--但仍然存在这个问题。
我已经在Oracle11g中开发了一个数据库,它在我家里的桌面上使用SQL Developer。我想在家里从笔记本电脑上访问数据库,但是根据我尝试的内容,我会收到各种各样的错误。
我将把我的桌面称为主机计算机,将我的笔记本电脑称为CLIENT计算机。我相信我的笔记本电脑上安装了适当的客户端软件(我的笔记本上还安装了完整的Oracle11g数据库)--但我想我的侦听器文件或tns文件有问题。我可以在客户端中使用主机,没有任何问题--只是无法连接到数据库。
我相信你需要看到的相关细节如下:
IP configuration details from the 'HOST' computer:
Windows IP Configuration
Ethernet adapter Ethernet:
Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :
Wireless LAN adapter Local Area Connection* 2:
Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :
Wireless LAN adapter Wi-Fi:
Connection-specific DNS Suffix . :
Link-local IPv6 Address . . . . . : fe80::48e8:82ce:a1cb:c4cd%15
IPv4 Address. . . . . . . . . . . : 192.168.0.110
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . : 192.168.0.1
Wireless LAN adapter Local Area Connection* 13:
Connection-specific DNS Suffix . :
Link-local IPv6 Address . . . . . : fe80::64c6:cc86:259d:3699%12
IPv4 Address. . . . . . . . . . . : 192.168.137.1
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . :
Ethernet adapter Bluetooth Network Connection:
Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :
Tunnel adapter Local Area Connection* 4:
Connection-specific DNS Suffix . :
IPv6 Address. . . . . . . . . . . : 2001:0:9d38:953c:2c32:3d76:3049:aa5c
Link-local IPv6 Address . . . . . : fe80::2c32:3d76:3049:aa5c%13
Default Gateway . . . . . . . . . : ::来自lnsrctl主机的服务
Service "CLRExtProc" has 1 instance(s).
Instance "CLRExtProc", status UNKNOWN, has 1 handler(s) for this service...
Handler(s):
"DEDICATED" established:0 refused:0
LOCAL SERVER
Service "PLSExtProc" has 1 instance(s).
Instance "PLSExtProc", status UNKNOWN, has 1 handler(s) for this service...
Handler(s):
"DEDICATED" established:0 refused:0
LOCAL SERVER
Service "XEXDB" has 1 instance(s).
Instance "xe", status READY, has 1 handler(s) for this service...
Handler(s):
"D000" established:5 refused:2 current:0 max:1022 state:ready
DISPATCHER <machine: DIXON-FAMILY-CO, pid: 1764>
(ADDRESS=(PROTOCOL=tcp)(HOST=Dixon-Family-Computer)(PORT=50310))
Service "xe" has 1 instance(s).
Instance "xe", status READY, has 1 handler(s) for this service...
Handler(s):
"DEDICATED" established:0 refused:0 state:ready
LOCAL SERVER
The command completed successfully
##-----------------------------------TNSnames.ora详细信息来自主机计算机:
LISTENER_DBGLOBAL =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1523))
ORACLR_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1523))
)
(CONNECT_DATA =
(SID = CLRExtProc)
(PRESENTATION = RO)
)
)
DBGLOBAL =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1523))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = dbglobal)
)
)
##----------------------------------------------------------------------------TNSnames.ora来自客户端计算机:
LISTENER_ORCL =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
ORACLR_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
)
(CONNECT_DATA =
(SID = CLRExtProc)
(PRESENTATION = RO)
)
)
ORCL =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = orcl)
)
)
XE =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = Dixon-Family-Computer)(PORT = 1522))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = XE)
)
)Listener.ora CLIENT的详细信息
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(SID_NAME = CLRExtProc)
(ORACLE_HOME = C:\app\erika\product\11.2.0\dbhome_1)
(PROGRAM = extproc)
(ENVS = "EXTPROC_DLLS=ONLY:C:\app\erika\product\11.2.0\dbhome_1\bin\oraclr11.dll")
)
)
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1522))
(ADDRESS = (PROTOCOL = TCP)(HOST = Dixon-Family-Computer)(PORT = 1522))
)
)
DEFAULT_SERVICE_LISTENER = (XE)
##-----------------------------------------------------------------------------我尝试通过SQL 以及SQL 从客户端计算机连接到数据库。
我尝试过以下几种方法--作为TNS和基本连接:
BUDGET_DATASRC/password@//Dixon-Family-Computer:1522/xe:DEDICATED/XEXDB
BUDGET_DATASRC/password@//Dixon-Family-Computer:50310[I'm not sure which port to use]/xe:DEDICATED/XEXDB有人能帮我找出我做错了什么吗?我以前从未在家里建立过数据库连接。这是严格为个人家庭使用-并帮助我提高我的技能。我也希望能够从我的笔记本电脑上访问我的桌面上的数据库。
预先感谢您抽出时间来看这个:)
你好,艾丽卡
发布于 2017-10-22 13:21:51
我能辨认出我错过了什么。我在主机上的防火墙设置中添加了DB侦听器端口,以允许来自客户端计算机的入站连接。现在,我连接到数据库,没有问题,从我的客户电脑。我花了好几天时间在这上面--所以我希望我的问题/答案能帮助到别人!
https://stackoverflow.com/questions/46869187
复制相似问题