this normally indicates, that an established session is not correctly ended.
In general you need to close database links after you do not need them anymore.
A SQL*Plus session for example querying from the remote database will normally close the db link automatically while ending the SQL*Plus session.
Sometimes it could happen, that you end SQLÃPlus during long runnning queries; in this situaotion it might happen, that hsodbc will stay in the mmory. To get rid of those hsodbc processes, you may use pskill from www.sysinternals.com.
If the hsodbc processes are spawned by frequentyl running job systems, you need to close the database link manually afterwards.
alter session close database link <db link name>;
Thanks for the trick, pskill is very usefull...
Can you help me ? I try to use this command:
SELECT * FROM TableName@ExternalDB ;
ALTER SESSION CLOSE DATABASE LINK ExternalDB;
The system returns this error
ORA-02080 DBLink in use
if I execute only the last command the system returns this
ORA-02081 DBLink is not open
Sure that this dedicated hsodbc.exe process you see here belongs to your SQL*Plus session?
You can only close the hsodbc.exe process belonging to your current session. If for example another user or another SQL*Plus session has opened also an hsodbc process, that you close ONLY the hsodbc process belonging to your session.
So make sure no hsodbc.exe exists, then select from the remote db, wait until the select finished, commit your work and close the db link.
The hsodbc.exe process will disappear.
The only way I could imagine that hsodbc is not removed is while you cancel the query result in sql*plus....
So wait until the query has finished.
I have the same problem.
I'm using Oracle Database 10g Release 10.2.0.4.0 (Windows 2003 Server R2 EE SP2) with heterogeneous services to connect via dblink to SQL Server.
I use this commands but I have multiple instances of HSODBC.EXE. Whenever I make a select, after I commit the transaction and close dblink I have a new instance of this process. It will never disappear.