I encountered same problem with ORACLE 11G express on Windows.
After a long time waiting I got the same error message.
My solution is to make sure the hostname in tnsnames.ora (usually it’s not «localhost») and the default hostname in sql developer(usually it’s «localhost») same. You can either do this by changing it in the tnsnames.ora, or filling up the same in the sql developer.
Oh, of course you need to reboot all the oracle services (just to be safe).
Hope it helps.
I came across the similar problem again on another machine, but this time above solution doesn’t work.
After some trying, I found restarting all the oracle related services can fix the problem. Originally when the installation is done, connection can be made. Somehow after several reboot of computer, there is problem.
I change all the oracle services with start time as auto. And once I could not connect, I restart them all over again (the core service should be restarted at last order), and works fine.
Some article says it might be due to the MTS problem. Microsoft’s problem. Maybe!
Я пытаюсь подключиться к базе данных с помощью SQLDeveloper, и я получаю следующую ошибку:
An Error was Encountered performing The requested operation:
IO Error: Conection reset
Vendor code 17002.
Не могли бы вы помочь мне?
Ответ 1
Ниже перечислены шаги, которые могут исправить ошибку:
- Нажмите Windows + R
- Введите
services.msc
и нажмите Enter - Найти все службы
- Начиная с
ora
запустите эти службы и подождите!! - Когда инициализируется служба вашего сервера (в моем случае это было
orcl
) - Теперь запустите
mysql
или что вы используете и запустите coding.P
Ответ 2
Я столкнулся с той же проблемой с ORACLE 11G express в Windows.
После долгого ожидания я получил то же сообщение об ошибке.
Мое решение заключается в убедиться, что имя хоста в tnsnames.ora(обычно это не «localhost» ) и имя хоста по умолчанию в sql-разработчике (обычно это «localhost» ) одинаково. Вы можете либо сделать это, изменив его в tnsnames.ora, либо заполнив то же самое в разработчике sql.
О, конечно, вам нужно перезагрузить все службы оракула (просто чтобы быть в безопасности).
Надеюсь, что это поможет.
Я снова столкнулся с подобной проблемой на другой машине, но на этот раз выше решение не работает.
После некоторых попыток я обнаружил, что перезапуск всех связанных с oracle сервисов может решить проблему. Первоначально, когда установка завершена, соединение может быть выполнено. Как-то после нескольких перезагрузок компьютера возникает проблема.
Я меняю все службы оракула с временем начала, как авто. И как только я не смог подключиться, я перезапускаю их снова и снова (основная служба должна быть перезапущена в последнем порядке) и работает нормально.
В какой-то статье говорится, что это может быть связано с проблемой MTS. Проблема с Microsoft. Может быть!
Ответ 3
У меня была та же проблема. Я начал использовать свой слуховой аппарат Oracle TNS, затем он работает нормально снова.
См. LISTENER: TNS-12545… Нет такого файла или каталога.
Ответ 4
В вашем случае «Код 17002 поставщика» является эквивалентом ошибки ORA-12541: скорее всего, ваш слушатель выключен или имеет неправильный порт или имя службы. Из документов:
ORA-12541: TNS no listener
Причина. Слушатель исходного репозитория не запущен.
Действие: Запустите прослушиватель на компьютере, на котором находится исходный репозиторий.
Содержание
- SQL Developer Cannot Connect To Database Fails With Vendor code 17002 (Doc ID 1324766.1)
- Applies to:
- Symptoms
- Changes
- Cause
- To view full details, sign in with your My Oracle Support account.
- Don’t have a My Oracle Support account? Click to get started!
- Cannot Establish Connection (Error Code: 17002) Randomly With JDBC Thin Driver (Doc ID 357445.1)
- Applies to:
- Symptoms
- Changes
- Cause
- To view full details, sign in with your My Oracle Support account.
- Don’t have a My Oracle Support account? Click to get started!
- Christoph Jahn
- 30 thoughts on “ Oracle Error 17002 “Io Exception: The Network Adapter could not establish the connection” ”
- The Network Adapter could not establish the connection Error Code: 17002
SQL Developer Cannot Connect To Database Fails With Vendor code 17002 (Doc ID 1324766.1)
Last updated on SEPTEMBER 20, 2022
Applies to:
Symptoms
In the process of rolling out banners for SEC_USER_UNAUTHORIZED_ACCESS_BANNER and SEC_USER_AUDIT_ACTION_BANNER.
Testing applications to see if there was any effect on connectivity, and noticed unable to connect to the database using SQL Developer (3.0.04). SQL Developer throws error:
Error
———
An error was encountered performing the requested operation:
IO Error: Got minus one from a read call
Vendor code 17002
Works
————
Using SQL Developer 2.1 connects without any errors
SQL Plus can connect to the database without any issues, as can TOAD
SQL Developer can connect to the database without issues if we remove the banner files.
Does Not Work
—————
Using SQL Developer 3.0 and banner files.
Changes
Upgraded from SQL Developer 2.1 to 3.0.
Cause
To view full details, sign in with your My Oracle Support account.
Don’t have a My Oracle Support account? Click to get started!
In this Document
My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.
Oracle offers a comprehensive and fully integrated stack of cloud applications and platform services. For more information about Oracle (NYSE:ORCL), visit oracle.com. пїЅ Oracle | Contact and Chat | Support | Communities | Connect with us | | | | Legal Notices | Terms of Use
Источник
Cannot Establish Connection (Error Code: 17002) Randomly With JDBC Thin Driver (Doc ID 357445.1)
Last updated on FEBRUARY 10, 2022
Applies to:
Symptoms
When using the ORACLEВ JDBC thinВ driver В to access aВ database server instance, it В fails with the following Exception:
java.sql.SQLException: Io exception: The Network Adapter could not establish the connection
This happens whenВ looping on the following sequence :
- connect to the database server В (DriverManager.getConnection() В method)
- close JDBC connection
AfterВ executing N times (randomly) this sequence of code fails at connection time.
Changes
Cause
To view full details, sign in with your My Oracle Support account.
Don’t have a My Oracle Support account? Click to get started!
In this Document
My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.
Oracle offers a comprehensive and fully integrated stack of cloud applications and platform services. For more information about Oracle (NYSE:ORCL), visit oracle.com. пїЅ Oracle | Contact and Chat | Support | Communities | Connect with us | | | | Legal Notices | Terms of Use
Источник
Christoph Jahn
If you search for the Oracle error “Io Exception: The Network Adapter could not establish the connection” (ORA-17002) you will find plenty of discussion on the web. It usually comes down to what the message says, that it is a network issue. But the error can also be caused by e.g. incompatible jar files. In my case, however, I was trying to access a 11g R2 instance from SQL Developer and during initial setup everything had worked. And local access, also with SQL Developer, worked absolutely fine.
Solution: Replace “simple” DB hostname with the fully qualified one. I am not sure why this changed the behavior. I can think of either a DNS setup issue (although my search list included the domain) or some kind of reverse lookup logic that is being applied. Anyway, I wanted to share this finding and also record it for my own future use.
30 thoughts on “ Oracle Error 17002 “Io Exception: The Network Adapter could not establish the connection” ”
Thanks for the tip, it worked for me too !!
Even, I changed localhost to my machine name, it worked, and it was still working when I reverted to localhost. There must be some strange network behaviour beneath.
thank you very much!
I tried a lot of complex solutions and this was the winner, now I can continue my work, thanks again
thank you very much …!
other solution :
you make sure that you have the right DNS on your IP Address this is happened if you have 2 network
It didn’t work for me.
Thank you very much, it helped me to solve the problem I had
Thank you so much for your helping me.
it worked fo me too ! merci beacoup !!
Awesome tip! worked for me too…it was a dns issue
Hey, what’s the difference between “simple DB hostname” and “fully qualified DB hostname”? some example pls because I’m not sure did I understand it right? 🙂
Simple name is e.g. “dbserver” whereas fully qualified one is “dbserver.mycomany.com”. Does that help?
Where can I find fully qualified name? I tried with select * from global_name, but I got same name as simple name….
The fully qualified hostname is part of the machine’s network setup and only indirectly part of Oracle
It worked like a charm. Thanks
Awesome tip. It worked for me..
I tried everything, it doesn’t work. Finally i tried by using connection type as local/Bequeath. Then it worked for me.
Other solution: In your application data-source change the connect string from
“jdbc:oracle:thin:@host:port:sid” (short connection string)
“jdbc:oracle:thin:@(DESCRIPTION= (ADDRESS = (PROTOCOL = TCP)
(HOST = host)
(PORT = port)
)
(CONNECT_DATA=
(SERVICE_NAME=sid)
(SERVER=DEDICATED)
)
)” (full server string)
Super… Used the fully qualified hostname and it worked. Thanks.
Thanks worked for me 🙂
Hello All ,
I have tried all these techniques but still my facing same issue.
1- I have data source on my local websphere6.1 and when do test connection from web console server ,it was successful but when i tried to do the same it giving me error
” java.sql.SQLException: Io exception: The Network Adapter could not establish the connectionDSRA0010E: SQL State = null, Error Code = 17,002″
Note : I am connection to remote oracle db.
in my machine , i have only raid & web sphere installed.
Please any body help me.
Advance thank you
It c an be bacause of the wrong credentials of the service name. I changed my system credentials which i was using for the service, the moment i updated that it worked for me. Thanks.
@Lucas Silva: perfect, your my hero!
I got this error but the hostname is the fully one
I changed to localhost and it worked fine
Источник
The Network Adapter could not establish the connection Error Code: 17002
+Hi, I am stuck on this exception. i have made a desktop application using netbeans wizard. When i connect the db with jdbcracle:thin:@localhost:1521:XE it runs fine. But when i change url to+
jdbcracle:thin:@remoteaddress:1521:MyORCL it throws the following exception.+
run:
[TopLink Info]: 2011.03.16 12:34:53.012—ServerSession(26335425)—TopLink, version: Oracle TopLink Essentials — 2.0.1 (Build b09d-fcs (12/06/2007))
Mar 16, 2011 12:35:07 PM org.jdesktop.application.Application$1 run
SEVERE: Application class desktopapplication5.DesktopApplication5 failed to launch
Local Exception Stack:
Exception [TOPLINK-4002] (Oracle TopLink Essentials — 2.0.1 (Build b09d-fcs (12/06/2007))): oracle.toplink.essentials.exceptions.DatabaseException
Internal Exception: java.sql.SQLException: Io exception: The Network Adapter could not establish the connection
Error Code: 17002
at oracle.toplink.essentials.exceptions.DatabaseException.sqlException(DatabaseException.java:305)
at oracle.toplink.essentials.sessions.DefaultConnector.connect(DefaultConnector.java:102)
at oracle.toplink.essentials.sessions.DatasourceLogin.connectToDatasource(DatasourceLogin.java:184)
at oracle.toplink.essentials.internal.sessions.DatabaseSessionImpl.loginAndDetectDatasource(DatabaseSessionImpl.java:582)
at oracle.toplink.essentials.ejb.cmp3.EntityManagerFactoryProvider.login(EntityManagerFactoryProvider.java:280)
at oracle.toplink.essentials.internal.ejb.cmp3.EntityManagerSetupImpl.deploy(EntityManagerSetupImpl.java:229)
at oracle.toplink.essentials.internal.ejb.cmp3.base.EntityManagerFactoryImpl.getServerSession(EntityManagerFactoryImpl.java:93)
at oracle.toplink.essentials.internal.ejb.cmp3.base.EntityManagerFactoryImpl.createEntityManagerImpl(EntityManagerFactoryImpl.java:126)
at oracle.toplink.essentials.internal.ejb.cmp3.base.EntityManagerFactoryImpl.createEntityManagerImpl(EntityManagerFactoryImpl.java:120)
at oracle.toplink.essentials.internal.ejb.cmp3.EntityManagerFactoryImpl.createEntityManager(EntityManagerFactoryImpl.java:91)
at desktopapplication5.DesktopApplication5View.initComponents(DesktopApplication5View.java:345)
at desktopapplication5.DesktopApplication5View. (DesktopApplication5View.java:36)
at desktopapplication5.DesktopApplication5.startup(DesktopApplication5.java:19)
at org.jdesktop.application.Application$1.run(Application.java:171)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
Caused by: java.sql.SQLException: Io exception: The Network Adapter could not establish the connection
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:112)
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:146)
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:255)
at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:387)
at oracle.jdbc.driver.PhysicalConnection. (PhysicalConnection.java:414)
at oracle.jdbc.driver.T4CConnection. (T4CConnection.java:165)
at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:35)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:801)
at java.sql.DriverManager.getConnection(DriverManager.java:582)
at java.sql.DriverManager.getConnection(DriverManager.java:154)
at oracle.toplink.essentials.sessions.DefaultConnector.connect(DefaultConnector.java:100)
. 20 more
Exception in thread «AWT-EventQueue-0» java.lang.Error: Application class desktopapplication5.DesktopApplication5 failed to launch
at org.jdesktop.application.Application$1.run(Application.java:177)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
Caused by: Exception [TOPLINK-4002] (Oracle TopLink Essentials — 2.0.1 (Build b09d-fcs (12/06/2007))): oracle.toplink.essentials.exceptions.DatabaseException
Internal Exception: java.sql.SQLException: Io exception: The Network Adapter could not establish the connection
Error Code: 17002
at oracle.toplink.essentials.exceptions.DatabaseException.sqlException(DatabaseException.java:305)
at oracle.toplink.essentials.sessions.DefaultConnector.connect(DefaultConnector.java:102)
at oracle.toplink.essentials.sessions.DatasourceLogin.connectToDatasource(DatasourceLogin.java:184)
at oracle.toplink.essentials.internal.sessions.DatabaseSessionImpl.loginAndDetectDatasource(DatabaseSessionImpl.java:582)
at oracle.toplink.essentials.ejb.cmp3.EntityManagerFactoryProvider.login(EntityManagerFactoryProvider.java:280)
at oracle.toplink.essentials.internal.ejb.cmp3.EntityManagerSetupImpl.deploy(EntityManagerSetupImpl.java:229)
at oracle.toplink.essentials.internal.ejb.cmp3.base.EntityManagerFactoryImpl.getServerSession(EntityManagerFactoryImpl.java:93)
at oracle.toplink.essentials.internal.ejb.cmp3.base.EntityManagerFactoryImpl.createEntityManagerImpl(EntityManagerFactoryImpl.java:126)
at oracle.toplink.essentials.internal.ejb.cmp3.base.EntityManagerFactoryImpl.createEntityManagerImpl(EntityManagerFactoryImpl.java:120)
at oracle.toplink.essentials.internal.ejb.cmp3.EntityManagerFactoryImpl.createEntityManager(EntityManagerFactoryImpl.java:91)
at desktopapplication5.DesktopApplication5View.initComponents(DesktopApplication5View.java:345)
at desktopapplication5.DesktopApplication5View. (DesktopApplication5View.java:36)
at desktopapplication5.DesktopApplication5.startup(DesktopApplication5.java:19)
at org.jdesktop.application.Application$1.run(Application.java:171)
. 8 more
Caused by: java.sql.SQLException: Io exception: The Network Adapter could not establish the connection
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:112)
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:146)
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:255)
at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:387)
at oracle.jdbc.driver.PhysicalConnection. (PhysicalConnection.java:414)
at oracle.jdbc.driver.T4CConnection. (T4CConnection.java:165)
at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:35)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:801)
at java.sql.DriverManager.getConnection(DriverManager.java:582)
at java.sql.DriverManager.getConnection(DriverManager.java:154)
at oracle.toplink.essentials.sessions.DefaultConnector.connect(DefaultConnector.java:100)
. 20 more
BUILD SUCCESSFUL (total time: 17 seconds)
What could be possible remedies? Waiting.
Источник
I encountered same problem with ORACLE 11G express on Windows.
After a long time waiting I got the same error message.
My solution is to make sure the hostname in tnsnames.ora (usually it’s not «localhost») and the default hostname in sql developer(usually it’s «localhost») same. You can either do this by changing it in the tnsnames.ora, or filling up the same in the sql developer.
Oh, of course you need to reboot all the oracle services (just to be safe).
Hope it helps.
I came across the similar problem again on another machine, but this time above solution doesn’t work.
After some trying, I found restarting all the oracle related services can fix the problem. Originally when the installation is done, connection can be made. Somehow after several reboot of computer, there is problem.
I change all the oracle services with start time as auto. And once I could not connect, I restart them all over again (the core service should be restarted at last order), and works fine.
Some article says it might be due to the MTS problem. Microsoft’s problem. Maybe!
I have an Oracle database 12c standard edition release 12.2.0.1.0 running on a Linux instance of AWS ec2. When I try to connect to it remotely from my machine (macOS) using SQL Developer I get an IO Error: The Network Adapter could not establish the connection
Vendor Code 17002
error.
- connecting using sqlplus from my machine:
sqlplus cd2/ @ec2-publicIp.myCloud.compute.amazonaws.com:1522/orcl
SQL*Plus: Release 19.0.0.0.0 - Production on Mon Aug 3 15:30:56 2020
Version 19.3.0.0.0
Copyright (c) 1982, 2019, Oracle. All rights reserved.
ERROR:
ORA-12541: TNS:no listener
- On the ec2 instance, Security Groups, a TCP 1522 port is open for my machine’s public IP
- telnet to the instance, port 1522 seems to indicate that the port is open:
telnet ec2-pubIp.compute.amazonaws.com 1522
Trying pubIp...
telnet: connect to address pubIp: Connection refused
telnet: Unable to connect to remote host
- Port 1522 is used consistently across all the configurations
- I verified that the ec2 hostname (
hostname
command) matches the service name output fromlsnrctl status
. The output showslocalhost
instead ofip-localIp.myCloud.compute.internal
.
$ hostname
ip-localIp.myCloud.compute.internal
$ lsnrctl status
LSNRCTL for Linux: Version 12.2.0.1.0 - Production on 03-AUG-2020 15:20:44
Copyright (c) 1991, 2016, Oracle. All rights reserved.
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=ip-localIp.myCloud.compute.internal)(PORT=1522)))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Linux: Version 12.2.0.1.0 - Production
Start Date 03-AUG-2020 13:30:22
Uptime 0 days 1 hr. 50 min. 22 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /u01/app/centos/product/12.2.0/dbhome_1/network/admin/listener.ora
Listener Log File /u01/app/centos/diag/tnslsnr/ip-localIp/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1522)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1522)))
Services Summary...
Service "orcl.myCloud.compute.internal" has 1 instance(s).
Instance "orcl", status READY, has 1 handler(s) for this service...
Service "orclXDB.myCloud.compute.internal" has 1 instance(s).
Instance "orcl", status READY, has 1 handler(s) for this service...
The command completed successfully
- The hostname and port also matches the default listener configured in
listener.ora
:
cat /u01/app/centos/product/12.2.0/dbhome_1/network/admin/listener.ora
# listener.ora Network Configuration File: /u01/app/centos/product/12.2.0/dbhome_1/network/admin/listener.ora
# Generated by Oracle configuration tools.
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = ip-localIp.myCloud.compute.internal)(PORT = 1522))
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1522))
)
)
- Oracle parameters are as shown, again both host and port match:
SQL> show parameter listener_networks
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
listener_networks string
SQL> show parameter local_listener
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
local_listener string (ADDRESS=(PROTOCOL=TCP)(HOST =
ip-localIp.myCloud
.compute.internal)(PORT = 1522
))
SQL> show parameter remote_listener
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
remote_listener string
- I can connect from the ec2 instance:
sqlplus / as sysdba
- I can connect from the ec2 instance as a schema/user cd2:
sqlplus cd2/ @orcl
SQL*Plus: Release 12.2.0.1.0 Production on Mon Aug 3 18:04:13 2020
Copyright (c) 1982, 2016, Oracle. All rights reserved.
Enter password:
Last Successful login time: Mon Aug 03 2020 18:03:52 +00:00
Connected to:
Oracle Database 12c Standard Edition Release 12.2.0.1.0 - 64bit Production
SP2-0310: unable to open file "orcl.sql"
SQL> select 1 from dual;
1
----------
1
SQL>
- SQL Developer connection matches both the port and ec2’s public domain name:
- This database server is our dev instance so no license was installed
- Updated
listener.ora
by setting theHOST
value to0.0.0.0
, restarted withlsnrctl
but the result was the same:
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 0.0.0.0)(PORT = 1522))
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1522))
)
)
/etc/hosts
content:
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4 ip-localIp.myCloud.compute.internal
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
- I also tested it with all inbound traffic and all ports opened for the ec2 instance
I have installed ORACLE SQL on my Manjaro Linux. But after restarting my PC getting below error in SQL developer:
An error was encountered performing the requested operation:
IO Error: The Network Adapter could not establish the connection
Vendor code 17002
I checked whetherr listener is running or not:
[akoley@animesh-pc ~]$ lsnrctl status
LSNRCTL for Linux: Version 11.2.0.2.0 - Production on 06-AUG-2019 21:03:48
Copyright (c) 1991, 2011, Oracle. All rights reserved.
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC_FOR_XE)))
TNS-12541: TNS:no listener
TNS-12560: TNS:protocol adapter error
TNS-00511: No listener
Linux Error: 111: Connection refused
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=animesh-pc)(PORT=1521)))
TNS-12541: TNS:no listener
TNS-12560: TNS:protocol adapter error
TNS-00511: No listener
Linux Error: 111: Connection refused
I tried to start it too:
akoley@animesh-pc ~]$ lsnrctl start
LSNRCTL for Linux: Version 11.2.0.2.0 - Production on 06-AUG-2019 21:05:15
Copyright (c) 1991, 2011, Oracle. All rights reserved.
Starting /usr/lib/oracle/product/11.2.0/xe/bin/tnslsnr: please wait...
TNSLSNR for Linux: Version 11.2.0.2.0 - Production
System parameter file is /usr/lib/oracle/product/11.2.0/xe/network/admin/listener.ora
Log messages written to /usr/lib/oracle/product/11.2.0/xe/log/diag/tnslsnr/animesh-pc/listener/alert/log.xml
Error listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC_FOR_XE)))
TNS-12555: TNS:permission denied
TNS-12560: TNS:protocol adapter error
TNS-00525: Insufficient privilege for operation
Linux Error: 1: Operation not permitted
Listener failed to start. See the error message(s) above...
My Listener file is this:
[akoley@animesh-pc ~]$ cat /usr/lib/oracle/product/11.2.0/xe/network/admin/listener.ora
# listener.ora Network Configuration File:
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(SID_NAME = PLSExtProc)
(ORACLE_HOME = /usr/lib/oracle/product/11.2.0/xe)
(PROGRAM = extproc)
)
)
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC_FOR_XE))
(ADDRESS = (PROTOCOL = TCP)(HOST = animesh-pc)(PORT = 1521))
)
)
DEFAULT_SERVICE_LISTENER = (XE)
I have installed ORACLE SQL on my Manjaro Linux. But after restarting my PC getting below error in SQL developer:
An error was encountered performing the requested operation:
IO Error: The Network Adapter could not establish the connection
Vendor code 17002
I checked whetherr listener is running or not:
[akoley@animesh-pc ~]$ lsnrctl status
LSNRCTL for Linux: Version 11.2.0.2.0 - Production on 06-AUG-2019 21:03:48
Copyright (c) 1991, 2011, Oracle. All rights reserved.
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC_FOR_XE)))
TNS-12541: TNS:no listener
TNS-12560: TNS:protocol adapter error
TNS-00511: No listener
Linux Error: 111: Connection refused
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=animesh-pc)(PORT=1521)))
TNS-12541: TNS:no listener
TNS-12560: TNS:protocol adapter error
TNS-00511: No listener
Linux Error: 111: Connection refused
I tried to start it too:
akoley@animesh-pc ~]$ lsnrctl start
LSNRCTL for Linux: Version 11.2.0.2.0 - Production on 06-AUG-2019 21:05:15
Copyright (c) 1991, 2011, Oracle. All rights reserved.
Starting /usr/lib/oracle/product/11.2.0/xe/bin/tnslsnr: please wait...
TNSLSNR for Linux: Version 11.2.0.2.0 - Production
System parameter file is /usr/lib/oracle/product/11.2.0/xe/network/admin/listener.ora
Log messages written to /usr/lib/oracle/product/11.2.0/xe/log/diag/tnslsnr/animesh-pc/listener/alert/log.xml
Error listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC_FOR_XE)))
TNS-12555: TNS:permission denied
TNS-12560: TNS:protocol adapter error
TNS-00525: Insufficient privilege for operation
Linux Error: 1: Operation not permitted
Listener failed to start. See the error message(s) above...
My Listener file is this:
[akoley@animesh-pc ~]$ cat /usr/lib/oracle/product/11.2.0/xe/network/admin/listener.ora
# listener.ora Network Configuration File:
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(SID_NAME = PLSExtProc)
(ORACLE_HOME = /usr/lib/oracle/product/11.2.0/xe)
(PROGRAM = extproc)
)
)
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC_FOR_XE))
(ADDRESS = (PROTOCOL = TCP)(HOST = animesh-pc)(PORT = 1521))
)
)
DEFAULT_SERVICE_LISTENER = (XE)
May 6, 2021
I got ” ORA-17002: io exception: the network adaptor could not establish the connection Vendor code 17002″ error in Oracle database.
ORA-17002: io exception: the network adaptor could not establish the connection Vendor code 17002
Details of error are as follows.
ORA-17002: io exception: the network adaptor could not establish the connection Vendor code 17002
io exception: the network adaptor could not establish the connection Vendor code 17002
This ORA-17002 error is related with the ORA-12541: TNS:no listener error.
This error is related with the listener of database server, if you got this error, then check your database listener as follows.
$ lsnrctl status listener
Listener should be always started.
You can stop and start the Listener as follows.
$ srvctl start listener $ srvctl stop listener
or
$ lsnrctl stop listener $ lsnrctl start listener
Edit the server side sqlnet.ora file and add this parameter:
SQLNET.INBOUND_CONNECT_TIMEOUT=240
There is no need to restart either the listener or the database after this change unless the database is running in shared server mode.
The next dedicated server process that gets spawned will pick up the new setting.
Do you want to learn Oracle Database for Beginners, then read the following articles.
Oracle Tutorial | Oracle Database Tutorials for Beginners ( Junior Oracle DBA )
1,490 views last month, 1 views today
In this post we’re going to talk about Oracle SQL developer “SQL Error 17002 Sqlstate 08006” error on Windows. We’ll talk about the error code and how to fix it fast.
Why Does SQL Error 17002 Sqlstate 08006 Shows Up?
Most of the times it shows up because there is incorrect Misconfiguration or listener isn’t running. Before you’re able to connect with Oracle database, SQL developer must be configured correctly and listener has to be running. The listener handles databases connection, by default the SQL settings does not need listener for connecting to database and so it has to be configured.
SQL Error 17002 Sqlstate 08006
Another possible reason for this SQL error could be database sessions have been terminated by the network firewall or interrupted by another reason. In this case you have to make sure firewall isn’t stopping idle connections.
Connectivity problems between oracle integration and connectivity agent can be the cause of this error also, or when the connectivity agent is disabled. You have to make sure connectivity agent is running. You can check the status under your Dashboards and Agents in oracle integration.
How To Fix SQL Error 17002 Sqlstate 08006
The fixes to this SQL error code is mostly about fixing or configuring the listener. We’ll also share other fixes that will help.
Fix No.1: Ensure listener is running
This can be checked from Windows Service Manager or using Command Prompt. Follow these steps to check the status;
Checking listener status using Windows Service Manager:
- Press Windows + R to open Run Dialogue.
- Type msc in the dialogue box.
- In the list of services, TNS listener is listed, make sure it’s running, the status is shown beside each service. If it’s not running you just need to right-click and click Start.
Checking with command prompt:
Open command prompt, you can do that by typing cmd in windows search, right-click on it and select ‘Run As Administrator’.
- When the command prompt opens, you type this command: C:>lsnrctl status
- If it’s not running, error will be mentioned multiple times, and you need to start it.
- To start the listener service, you need to type this command: C:>lsnrctl start
lsnrctl status
Fix No.2: Making sure the listener has the right configurations
- Open Oracle SQL Developer.
- Right click on database name and select properties.
- A window will open and you need to take note of the Hostname and port values under the ‘details’ tab.
- The default port is 1521, but sometimes it can be 1522, it has to be changed.
- Now back to checking hostname, you should type C:>hostname.
- The hostname will immediately appear below this command and if you’re receiving the SQL error code 17002, in most cases it will be different from the hostname that appeared when you right-click on the database name in the previous step. Remember that I told you to take note of the Hostname, this difference occurs when the computer name is changed. In this situation, the hostname has to be corrected in the connection Window, and the port value also should be changed to 1521 if that’s not the value.
- The next step now is to open tnsnames.ora file and check to confirm that the hostname and port is correct. The full path is; %ORACLE_HOME%/network/admin/tnsnames.ora. if not you need to change the values appropriately.
- Open the Windows Service Manager and Restart OracleserviceXE by right clicking and then click restart.
- Now you should test the connection to see if things are ok. When you’re sure all values are correct, that’s the Port, Hostname, username and password, you should click the test button. If connection show successful it means the problem has been rectified.
- After that you can now click connect and can now browse and query your database.
This fix can be lengthy or seem complex to most users but that’s the way to go about it.
Fix No.3: Restart Oracle TNS listener
As we’ve mentioned in the first fix, you should check whether listener is running or not, so in this case even if it’s running you should restart it. You should follow the same procedure in the first fix. Restarting the listener has work for some, you should give it a try.
Conclusion
So far these are some of the best fixes to SQL Error 17002 Sqlstate 08006, the problem most of the time has to do with listener and you need to ensure that it’s pointing to the correct port and server. Once you can figure this out, you’ll definitely get rid of the problem. Do let us know in the comments if these fixes have solved the SQL error for you, if you also have more ideas to share please drop your comments below for our readers.
Я пытаюсь подключиться к базе данных с помощью SQLDeveloper, и я получаю следующую ошибку:
An Error was Encountered performing The requested operation:
IO Error: Conection reset
Vendor code 17002.
Не могли бы вы помочь мне?
Ответ 1
Ниже перечислены шаги, которые могут исправить ошибку:
- Нажмите Windows + R
- Введите
services.msc
и нажмите Enter - Найти все службы
- Начиная с
ora
запустите эти службы и подождите!! - Когда инициализируется служба вашего сервера (в моем случае это было
orcl
) - Теперь запустите
mysql
или что вы используете и запустите coding.P
Ответ 2
Я столкнулся с той же проблемой с ORACLE 11G express в Windows.
После долгого ожидания я получил то же сообщение об ошибке.
Мое решение заключается в убедиться, что имя хоста в tnsnames.ora(обычно это не «localhost» ) и имя хоста по умолчанию в sql-разработчике (обычно это «localhost» ) одинаково. Вы можете либо сделать это, изменив его в tnsnames.ora, либо заполнив то же самое в разработчике sql.
О, конечно, вам нужно перезагрузить все службы оракула (просто чтобы быть в безопасности).
Надеюсь, что это поможет.
Я снова столкнулся с подобной проблемой на другой машине, но на этот раз выше решение не работает.
После некоторых попыток я обнаружил, что перезапуск всех связанных с oracle сервисов может решить проблему. Первоначально, когда установка завершена, соединение может быть выполнено. Как-то после нескольких перезагрузок компьютера возникает проблема.
Я меняю все службы оракула с временем начала, как авто. И как только я не смог подключиться, я перезапускаю их снова и снова (основная служба должна быть перезапущена в последнем порядке) и работает нормально.
В какой-то статье говорится, что это может быть связано с проблемой MTS. Проблема с Microsoft. Может быть!
Ответ 3
У меня была та же проблема. Я начал использовать свой слуховой аппарат Oracle TNS, затем он работает нормально снова.
См. LISTENER: TNS-12545… Нет такого файла или каталога.
Ответ 4
В вашем случае «Код 17002 поставщика» является эквивалентом ошибки ORA-12541: скорее всего, ваш слушатель выключен или имеет неправильный порт или имя службы. Из документов:
ORA-12541: TNS no listener
Причина. Слушатель исходного репозитория не запущен.
Действие: Запустите прослушиватель на компьютере, на котором находится исходный репозиторий.
Popular posts from this blog
<<Back to DB Administration Main Page Oracle ROWID Explained From Oracle 8 onwards Oracle ROWID format is on 10 bytes and represented as OOOOOOFFFBBBBBBRRR. Bits 1 to 32 (bytes 1 to 4) presents data object id (Possible unique DB Object 4294967295) Bits 33 to 44 (byte 5 and half byte 6): represent file number inside the tablespace (Possible unique datafile 4095) Bits 45 to 64 (half byte 6 and bytes 7 and 8): presents block number inside the file ( possible unique block ids 1048575) Bits 65 to 80 (bytes 9 and 10):presents row number inside the block ( possible number of rows in a block 65535) When printed, each field is displayed in radix 64 (A-Za-z0-9+/): The first 6 characters of the ROWID presents Object ID, Next 3 characters presents datafile# the object belongs to, next 6 characters presents Block ID in the datafile and the last 3 character presents actual row number in the block. That’s said lets understand this with an example. SQL> select row
<<Back to Oracle DATAPUMP Main Page How to check the progress of export or import Jobs You can attach to the export/import job using ATTACH parameter of oracle datapump utility. Once you are attached to the job you check its status by typing STATUS command. Let us see how Step1> Find the Export/Import Job Name You can find the datapump job information from DBA_DATAPUMP_JOBS or USER_DATAPUMP_JOBS view. SQL> SELECT OWNER_NAME,JOB_NAME,OPERATION,JOB_MODE,STATE from DBA_DATAPUMP_JOBS; OWNER_NAME JOB_NAME OPERATION JOB_MODE STATE ———- —————————— ——————— ———- ———- SYSTEM SYS_EXPORT_FULL_02 EXPORT FULL EXECUTING OR You can also find the job name for export/import in logfile in beginning itself. Step2>Attach to the Job and check status One you get the Export/Import Job Name attach the job and check its status. You can attach or det
<<Back to Oracle DB Security Main Page ORA-46665: master keys not activated for all PDBs during REKEY SQL> ADMINISTER KEY MANAGEMENT SET KEY FORCE KEYSTORE IDENTIFIED BY xxxx WITH BACKUP CONTAINER = ALL ; ADMINISTER KEY MANAGEMENT SET KEY FORCE KEYSTORE IDENTIFIED BY xxxx WITH BACKUP CONTAINER = ALL * ERROR at line 1: ORA-46665: master keys not activated for all PDBs during REKEY I found following in the trace file REKEY: Create Key in PDB 3 resulted in error 46658 *** 2019-02-06T15:27:04.667485+01:00 (CDB$ROOT(1)) REKEY: Activation of Key AdnU5OzNP08Qv1mIyXhP/64AAAAAAAAAAAAAAAAAAAAAAAAAAAAA in PDB 3 resulted in error 28374 REKEY: Keystore needs to be restored from the REKEY backup.Aborting REKEY! Cause: All this hassle started because I accidently deleted the wallet and all wallet backup files too and also forgot the keystore password. There was no way to restore the wallet back. Fortunately in my case the PDB which had encrypted data was supposed to be deco
<<Back to DB Administration Main Page There are instances when a DBA need to start the database using pfile, for example to trouble an instance startup error or to validate init file post parameter changes etc. In such situations you can create a pfile from spfile and once you are done with your changes you can create spfile from updated/modified pfile to start the database. How to Create Pfile from Spfile As sysdba execute following command SQL> create pfile=’/tmp/initOrcl.ora’ from spfile; How to Create SPfile from Pfile As sysdba execute following command SQL> create spfile from pfile=’/tmp/initOrcl.ora’; You can also create the pfile directly from memory How to Create Pfile from Memory As sysdba execute following command SQL> create pfile=’/tmp/initOrcl.ora’ from memory;
<<Back to Oracle ASM Main Page ORA-15040: diskgroup is incomplete SQL> startup ORA-00099: warning: no parameter file specified for ASM instance ASM instance started Total System Global Area 1140850688 bytes Fixed Size 8629704 bytes Variable Size 1107055160 bytes ASM Cache 25165824 bytes ORA-15110: no diskgroups mounted Reason: The reason of this error is simply the ASM is not able to find the some or all the disks. Solution: Investigate and make all the disks available to ASM to mount the disk group. Make sure the disks has proper permissions. If you are using AFD check following services are online oracleacfs oracleadvm oracleoks oracleafd Source of Problem : Issue started after restart of the server After restarting the server when I tried to start the ASM instance its started throwing error. ORA-15110: no diskgroups mounted Investigation in my Case Step1> ASM Logfile Scanning Looked i
<<Back to Oracle RAC Main Page How to Find Out VIP of an Oracle RAC Cluster Login clusterware owner (oracle) and execute the below command to find out the VIP hostname used in Oracle RAC $ olsnodes -i node1 node1-vip node2 node2-vip OR $ srvctl config nodeapps -viponly Network 1 exists Subnet IPv4: 10.0.0.0/255.255.0.0/bondeth0, static Subnet IPv6: Ping Targets: Network is enabled Network is individually enabled on nodes: Network is individually disabled on nodes: VIP exists: network number 1, hosting node node1 VIP Name: node1-vip VIP IPv4 Address: 10.0.0.1 VIP IPv6 Address: VIP is enabled. VIP is individually enabled on nodes: VIP is individually disabled on nodes: VIP exists: network number 1, hosting node node2 VIP Name: node2-vip VIP IPv4 Address: 10.0.0.2 VIP IPv6 Address: VIP is enabled. VIP is individually enabled on nodes: VIP is individually disabled on nodes:
<<Back to DB Administration Main Page ORA-28365: wallet is not open Encountered while Starting the Database $ srvctl start instance -d CDB001 -i CDB0011 PRCR-1013 : Failed to start resource ora.cdb001.db PRCR-1064 : Failed to start resource ora.cdb001.db on node node1.oracle.com CRS-5017: The resource action «ora.cdb001.db start» encountered the following error: ORA-28365: wallet is not open . For details refer to «(:CLSN00107:)» in «/u01/app/oracle/diag/crs/node1.oracle.com/crs/trace/crsd_oraagent_oracle.trc». CRS-2674: Start of ‘ora.cdb001.db’ on ‘node1.oracle.com’ failed Solution : Start the instance in mount mode SQL> startup mount; ORACLE instance started. Total System Global Area 2147483648 bytes Fixed Size 2926472 bytes Variable Size 1392511096 bytes Database Buffers 738197504 bytes Redo Buffers 13848576 bytes Database mounted. Check Wallet status set linesiz
<<Back to Oracle DB Security Main Page How to Configure a Software Keystore A software keystore is a container that stores the Transparent Data Encryption master encryption key. To configure a software Keystore follow the steps below. Step 1: Set the Keystore Location in the sqlnet.ora File You can store the software keystore (also known as wallet) in file system or in ASM Diskgroup. Does not matter where you want to store the keystore you have modify the sqlnet.ora and make an entry accordingly Make an entry as shown below in $ORACLE_HOME/network/admin/sqlnet.ora file Example1: If Storing the Wallet in ASM ENCRYPTION_WALLET_LOCATION= (SOURCE=(METHOD=FILE) (METHOD_DATA= (DIRECTORY= +DG_TST_DATA/$ORACLE_SID/wallet ) ) ) Example2: If Storing the Wallet in File System ENCRYPTION_WALLET_LOCATION= (SOURCE=(METHOD=FILE) (METHOD_DATA= (DIRECTORY= /u01/dbatst1/admin/wallet/$ORACLE_SID) ) ) NOTE: Ensure that the path you entered in DIREC
<<Back to DB Administration Main Page How to Upgrade from 11g,12c,18c to 19c DB Upgrade Compatibility Matrix Below is minimum version of the database that can be directly upgraded to Oracle 19c. Source Database Target Database 11.2.0.4 19c 12.1.0.2 19c 12.2.0.1 19c 18.1.0.0 19c NOTE: In this post I will demonstrate the upgrade from 12.1.0.2 to 19c. The steps are same for any other version to 19c upgrade. Upgrading the database from 12.1.0.2 to 19c I will be using DBUA its really easy to use and self explanatory as well as recommended options. It automates many things including upgrading Time zone, gathering dictionary statistics , taking restore RMAN backup or creating restore point , starting the listener with new OH etc. etc. Although DBUA can do many thing its recommended to everything possible that can be done upfront to minimize the overall downtime. General Requirement Ensure All DB Components and objects are valid.
<<Back to DB Administration Main Page How to Configure Auto Login Wallet in Oracle 12c Step1> Check the Wallet’s Current Status As you can see I have already password wallet in place. I will configure this password wallet to Auto_Login Wallet. To Configure Wallet from scratch check out my post How to configure TDE Using Wallet in pluggable database in 12c SQL> set linesize 200 col WALLET_DIR for a32 col status for a21 select STATUS,WRL_PARAMETER WALLET_DIR,WALLET_TYPE from V$ENCRYPTION_WALLET; STATUS WALLET_DIR WALLET_TYPE ——————— ——————————— ———————————————————— OPEN +DATAC4/CDB001/wallet/ PASSWORD 1 row selected. Step2> Create Local Auto Login KeyStore from Existing KeyStore SQL> ADMINISTER KEY MANAGEMENT CREATE LOCAL AUTO_LOGIN KEYSTORE FROM KEYSTORE ‘+DATAC4/CDB01/wallet/’ IDENTIFIED BY &qu
SQL Developer Cannot Connect To Database Fails With Vendor code 17002 (Doc ID 1324766.1)
Last updated on SEPTEMBER 20, 2022
Applies to:
Symptoms
In the process of rolling out banners for SEC_USER_UNAUTHORIZED_ACCESS_BANNER and SEC_USER_AUDIT_ACTION_BANNER.
Testing applications to see if there was any effect on connectivity, and noticed unable to connect to the database using SQL Developer (3.0.04). SQL Developer throws error:
Error
———
An error was encountered performing the requested operation:
IO Error: Got minus one from a read call
Vendor code 17002
Works
————
Using SQL Developer 2.1 connects without any errors
SQL Plus can connect to the database without any issues, as can TOAD
SQL Developer can connect to the database without issues if we remove the banner files.
Does Not Work
—————
Using SQL Developer 3.0 and banner files.
Changes
Upgraded from SQL Developer 2.1 to 3.0.
Cause
To view full details, sign in with your My Oracle Support account.
Don’t have a My Oracle Support account? Click to get started!
In this Document
My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.
Oracle offers a comprehensive and fully integrated stack of cloud applications and platform services. For more information about Oracle (NYSE:ORCL), visit oracle.com. пїЅ Oracle | Contact and Chat | Support | Communities | Connect with us | | | | Legal Notices | Terms of Use
Источник
SQL Developer won’t connect to database — Vendor code 17002
I have latest Oracle Sql Developer 3.2.1 installed, and I cannot connect to databases. I typed correct SID, port number, user and password and it won’t connect saying: «The Network Adapter could not establish the connection. Vendor code: 17002»
Do I need oracle client installed on my machine to connect to remote server using sql developer?
I am tunelling the connection using putty SSH to remote machine, and I put localhost as host in connection details in sql developer, but it works on another computer. I have also JDK 1.7.0_06 installed, and while starting sql developer I get warning that this product is supported with minimum version of 1.6.0_04 and less than 1.7. May this be problem?
Thanks in advance
Tom
Answers
Vendor code 17002 generally means a major network problem like invalid host or port number. Using ssh tunneling complicates the troubleshooting. It may be best to try to replicate the other machine setup as far as possible, including ssh setup, name resolution and sql developer configuration.
These are the normal troubleshooting steps.
Given a SQL Developer connection definition of DBSERVER, 1521, ORCL.
Can you ping DBSERVER?
Can you telnet to DBSERVER on port 1521 (telnet DBSERVER 1521). If you don’t have windows telnet you can use a putty telnet session.
I assume somewhere in your tunnelling setup you have something like locahost:1521 mapping to DBSERVER:1521. In that case you can replace localhost in the troubleshooting steps.
Источник
Christoph Jahn
If you search for the Oracle error “Io Exception: The Network Adapter could not establish the connection” (ORA-17002) you will find plenty of discussion on the web. It usually comes down to what the message says, that it is a network issue. But the error can also be caused by e.g. incompatible jar files. In my case, however, I was trying to access a 11g R2 instance from SQL Developer and during initial setup everything had worked. And local access, also with SQL Developer, worked absolutely fine.
Solution: Replace “simple” DB hostname with the fully qualified one. I am not sure why this changed the behavior. I can think of either a DNS setup issue (although my search list included the domain) or some kind of reverse lookup logic that is being applied. Anyway, I wanted to share this finding and also record it for my own future use.
30 thoughts on “ Oracle Error 17002 “Io Exception: The Network Adapter could not establish the connection” ”
Thanks for the tip, it worked for me too !!
Even, I changed localhost to my machine name, it worked, and it was still working when I reverted to localhost. There must be some strange network behaviour beneath.
thank you very much!
I tried a lot of complex solutions and this was the winner, now I can continue my work, thanks again
thank you very much …!
other solution :
you make sure that you have the right DNS on your IP Address this is happened if you have 2 network
It didn’t work for me.
Thank you very much, it helped me to solve the problem I had
Thank you so much for your helping me.
it worked fo me too ! merci beacoup !!
Awesome tip! worked for me too…it was a dns issue
Hey, what’s the difference between “simple DB hostname” and “fully qualified DB hostname”? some example pls because I’m not sure did I understand it right? 🙂
Simple name is e.g. “dbserver” whereas fully qualified one is “dbserver.mycomany.com”. Does that help?
Where can I find fully qualified name? I tried with select * from global_name, but I got same name as simple name….
The fully qualified hostname is part of the machine’s network setup and only indirectly part of Oracle
It worked like a charm. Thanks
Awesome tip. It worked for me..
I tried everything, it doesn’t work. Finally i tried by using connection type as local/Bequeath. Then it worked for me.
Other solution: In your application data-source change the connect string from
“jdbc:oracle:thin:@host:port:sid” (short connection string)
“jdbc:oracle:thin:@(DESCRIPTION= (ADDRESS = (PROTOCOL = TCP)
(HOST = host)
(PORT = port)
)
(CONNECT_DATA=
(SERVICE_NAME=sid)
(SERVER=DEDICATED)
)
)” (full server string)
Super… Used the fully qualified hostname and it worked. Thanks.
Thanks worked for me 🙂
Hello All ,
I have tried all these techniques but still my facing same issue.
1- I have data source on my local websphere6.1 and when do test connection from web console server ,it was successful but when i tried to do the same it giving me error
” java.sql.SQLException: Io exception: The Network Adapter could not establish the connectionDSRA0010E: SQL State = null, Error Code = 17,002″
Note : I am connection to remote oracle db.
in my machine , i have only raid & web sphere installed.
Please any body help me.
Advance thank you
It c an be bacause of the wrong credentials of the service name. I changed my system credentials which i was using for the service, the moment i updated that it worked for me. Thanks.
@Lucas Silva: perfect, your my hero!
I got this error but the hostname is the fully one
I changed to localhost and it worked fine
Источник
Database connection failes under JDeveloper running on Oracle Linux
After installing Oracle database an tried to follow Introduction to Oracle ADF Development step 2 — point 3, connection keep failing & throwing the following error
An error was encountered performing the requested operation:
IO Error: The Network Adapter could not establish the connection
Vendor code 17002
OS: Oracle Linux Release 5 Update 11 for x86_64 (64 Bit)
Best Answer
Good news .. It is now resolved as follows:
Here is the key actions:
1- Do the 4 steps in earlier post (under this discussion)
2- Make sure of «Network Setting — Network Adapter» of the VM as: NAT
3- Restart your VM to have new Network Settings effective.
4- Verify listeners using this command: lsnrctl services .. search in results in something like this(notice BOLD part):
LSNRCTL for Linux: Version 11.2.0.2.0 — Production on 08-AUG-2016 22:30:00
Copyright (c) 1991, 2011, Oracle. All rights reserved.
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC_FOR_XE)))
STATUS of the LISTENER
Version TNSLSNR for Linux: Version 11.2.0.2.0 — Production
Start Date 08-AUG-2016 22:02:50
Uptime 0 days 0 hr. 27 min. 9 sec
Trace Level off
Security ON: Local OS Authentication
Default Service XE
Listener Parameter File /u01/app/oracle/product/11.2.0/xe/network/admin/listener.ora
Listener Log File /u01/app/oracle/diag/tnslsnr/10/listener/alert/log.xml
Listening Endpoints Summary.
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.0.2.15)(PORT=1521)))
Service «PLSExtProc» has 1 instance(s).
Instance «PLSExtProc», status UNKNOWN, has 1 handler(s) for this service.
Service «XE» has 1 instance(s).
Instance «XE», status READY, has 1 handler(s) for this service...
Service «XEXDB» has 1 instance(s).
Instance «XE», status READY, has 1 handler(s) for this service.
The command completed successfully
3- Issue command: tnsping XE .. you will see something like the following (notice BOLD part):
TNS Ping Utility for Linux: Version 11.2.0.2.0 — Production on 08-AUG-2016 22:32:27
Copyright (c) 1997, 2011, Oracle. All rights reserved.
Used parameter files:
Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.2.15)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = XE)))
5- Provide configuration under JDeveloper making the «Host Name» as 10.0.2.15 (this value is looked up same as listed under step 3 above).
6- Finally, (by using OS user used originally to install Oracle db engine) make sure to issue command lsnrctl start before trying to test connect under JDeveloper
Источник
Problem with SQL Developer 18.4 on linux
During the connection with my database i get a message.
«An error was encountered performing the requested operation:
IO Error: The Network Adapter could not establish the connection
Vendor code 17002″
I found resolution this case on windows, and realized that was a listener fault.
Does anyone know how to solve this issue?
Answers
Have you actually got a Oracle database install and is the database up and running?
SQL Developer is a client tool that can be used to connect to an already installed and running Oracle db.
SQL Developer does not come with its own db.
Unfortunately, that error message from SQL Dev is rather generic. The bane of a DBAs existence is applications what swallow original error messages and substitute their own less informative messages. And here SQL Dev does just that.
Like all connection problems, it is a well-defined chain of defintions, specs, and events. And the listener is way down that that chain. So before we jump on our horses and ride off in all directions at once, let’s calm down and start with the first link.
Show us a screen shot of your connection definition in SQL Dev. With that we will know what the next bit of required information is. Without that, any other suggestions are pure speculation on where the problem might lie.
BTW, it would be really helpful if you would go to your profile and give yourself a recognizable name. It doesn’t have to be your real name, just something that looks like a real name. Who says my name is really Ed Stevens? Maybe I just like a certain TV show (http://www.imdb.com/title/tt0247091/) But at least when people see that on a message they have a recognizable identity. Unlike the system generated name of ‘ed0f625b-6857-4956-9b66-da280b7cf3a2’, which is no better than posting as «Anonymous».
All you ed0f625b-6857-4956-9b66-da280b7cf3a2’s look alike . . .
Got it also installed on linux, Fedora 29, get following error after starting :
Oracle SQL Developer
Copyright (c) 2005, 2018, Oracle and/or its affiliates. All rights reserved.
Available monitors: 1
Work Area: x:0, y:55, w:3200, h:1745
convert monitor[0] -> glass Screen
[x: 0 y: 0 w: 3200 h: 1800]
(java:17618): Gdk-ERROR **: 17:22:02.381: The program ‘java’ received an X Window System error.
This probably reflects a bug in the program.
The error was ‘RenderBadPicture (invalid Picture parameter)’.
(Details: serial 25911 error_code 141 request_code 138 minor_code 7)
(Note to programmers: normally, X errors are reported asynchronously;
that is, you will receive the error a while after causing it.
To debug your program, run it with the —sync command line
option to change this behavior. You can then get a meaningful
backtrace from your debugger if you break on the gdk_x_error() function.)
Источник
May 6, 2021
I got ” ORA-17002: io exception: the network adaptor could not establish the connection Vendor code 17002″ error in Oracle database.
ORA-17002: io exception: the network adaptor could not establish the connection Vendor code 17002
Details of error are as follows.
ORA-17002: io exception: the network adaptor could not establish the connection Vendor code 17002
io exception: the network adaptor could not establish the connection Vendor code 17002
This ORA-17002 error is related with the ORA-12541: TNS:no listener error.
This error is related with the listener of database server, if you got this error, then check your database listener as follows.
$ lsnrctl status listener
Listener should be always started.
You can stop and start the Listener as follows.
$ srvctl start listener $ srvctl stop listener
or
$ lsnrctl stop listener $ lsnrctl start listener
Edit the server side sqlnet.ora file and add this parameter:
SQLNET.INBOUND_CONNECT_TIMEOUT=240
There is no need to restart either the listener or the database after this change unless the database is running in shared server mode.
The next dedicated server process that gets spawned will pick up the new setting.
Do you want to learn Oracle Database for Beginners, then read the following articles.
Oracle Tutorial | Oracle Database Tutorials for Beginners ( Junior Oracle DBA )
1,499 views last month, 1 views today
Я столкнулся с той же проблемой при работе с ORACLE 11G express под Windows.
После долгого ожидания я получил то же сообщение об ошибке.
Мое решение — убедиться, что имя хоста в tnsnames.ora (обычно это не «localhost») и имя хоста по умолчанию в sql developer (обычно это «localhost») одинаковы. Вы можете либо изменить его в файле tnsnames.ora, либо заполнить то же самое в sql developer.
Конечно, вам нужно перезагрузить все службы oracle (на всякий случай).
Надеюсь, это поможет.
Я снова столкнулся с подобной проблемой на другой машине, но на этот раз вышеуказанное решение не сработало.
После некоторых попыток я обнаружил, что перезапуск всех служб, связанных с oracle, может решить проблему. Первоначально, когда установка завершена, соединение может быть установлено. Почему-то после нескольких перезагрузок компьютера проблема остается.
Я изменил во всех службах oracle время запуска на auto. И как только я не смог подключиться, я перезапустил их все заново (основная служба должна быть перезапущена в последнюю очередь), и все работает нормально.
В какой-то статье говорится, что это может быть связано с проблемой MTS. Microsoft’s problem. Возможно!
I have an Oracle database 12c standard edition release 12.2.0.1.0 running on a Linux instance of AWS ec2. When I try to connect to it remotely from my machine (macOS) using SQL Developer I get an IO Error: The Network Adapter could not establish the connection
Vendor Code 17002
error.
- connecting using sqlplus from my machine:
sqlplus cd2/ @ec2-publicIp.myCloud.compute.amazonaws.com:1522/orcl
SQL*Plus: Release 19.0.0.0.0 - Production on Mon Aug 3 15:30:56 2020
Version 19.3.0.0.0
Copyright (c) 1982, 2019, Oracle. All rights reserved.
ERROR:
ORA-12541: TNS:no listener
- On the ec2 instance, Security Groups, a TCP 1522 port is open for my machine’s public IP
- telnet to the instance, port 1522 seems to indicate that the port is open:
telnet ec2-pubIp.compute.amazonaws.com 1522
Trying pubIp...
telnet: connect to address pubIp: Connection refused
telnet: Unable to connect to remote host
- Port 1522 is used consistently across all the configurations
- I verified that the ec2 hostname (
hostname
command) matches the service name output fromlsnrctl status
. The output showslocalhost
instead ofip-localIp.myCloud.compute.internal
.
$ hostname
ip-localIp.myCloud.compute.internal
$ lsnrctl status
LSNRCTL for Linux: Version 12.2.0.1.0 - Production on 03-AUG-2020 15:20:44
Copyright (c) 1991, 2016, Oracle. All rights reserved.
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=ip-localIp.myCloud.compute.internal)(PORT=1522)))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Linux: Version 12.2.0.1.0 - Production
Start Date 03-AUG-2020 13:30:22
Uptime 0 days 1 hr. 50 min. 22 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /u01/app/centos/product/12.2.0/dbhome_1/network/admin/listener.ora
Listener Log File /u01/app/centos/diag/tnslsnr/ip-localIp/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1522)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1522)))
Services Summary...
Service "orcl.myCloud.compute.internal" has 1 instance(s).
Instance "orcl", status READY, has 1 handler(s) for this service...
Service "orclXDB.myCloud.compute.internal" has 1 instance(s).
Instance "orcl", status READY, has 1 handler(s) for this service...
The command completed successfully
- The hostname and port also matches the default listener configured in
listener.ora
:
cat /u01/app/centos/product/12.2.0/dbhome_1/network/admin/listener.ora
# listener.ora Network Configuration File: /u01/app/centos/product/12.2.0/dbhome_1/network/admin/listener.ora
# Generated by Oracle configuration tools.
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = ip-localIp.myCloud.compute.internal)(PORT = 1522))
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1522))
)
)
- Oracle parameters are as shown, again both host and port match:
SQL> show parameter listener_networks
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
listener_networks string
SQL> show parameter local_listener
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
local_listener string (ADDRESS=(PROTOCOL=TCP)(HOST =
ip-localIp.myCloud
.compute.internal)(PORT = 1522
))
SQL> show parameter remote_listener
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
remote_listener string
- I can connect from the ec2 instance:
sqlplus / as sysdba
- I can connect from the ec2 instance as a schema/user cd2:
sqlplus cd2/ @orcl
SQL*Plus: Release 12.2.0.1.0 Production on Mon Aug 3 18:04:13 2020
Copyright (c) 1982, 2016, Oracle. All rights reserved.
Enter password:
Last Successful login time: Mon Aug 03 2020 18:03:52 +00:00
Connected to:
Oracle Database 12c Standard Edition Release 12.2.0.1.0 - 64bit Production
SP2-0310: unable to open file "orcl.sql"
SQL> select 1 from dual;
1
----------
1
SQL>
- SQL Developer connection matches both the port and ec2’s public domain name:
- This database server is our dev instance so no license was installed
- Updated
listener.ora
by setting theHOST
value to0.0.0.0
, restarted withlsnrctl
but the result was the same:
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 0.0.0.0)(PORT = 1522))
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1522))
)
)
/etc/hosts
content:
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4 ip-localIp.myCloud.compute.internal
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
- I also tested it with all inbound traffic and all ports opened for the ec2 instance