Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> ORA-12170: TNS:Connect timeout occurred
I have read all topics regarding to this error but not found any answer
that would help: I have Oracle 10g (10.1) installed under Linux. I
can connect just fine using sqlplus from the local machine and I can
connect remotely with any application (e.g. sqldeveloper). However,
when I try to connect to the database locally from a perl script, I get
the ORA-12170 error message.
use DBI;
$ENV{"ORACLE_HOME"} = "/u01/app/oracle/OraHome_1";
$odsn="DBI:Oracle:xxx";
$ouid="yyy";
$opwd="zzz";
$odbh= DBI->connect ($odsn,$ouid,$opwd);
The necessary environmental variables are set:
ORACLE_SID=xxx
ORACLE_HOME=/u01/app/oracle/OraHome
The perl script obviously finds the instance xxx because if I change the instance name xxx to a different name, then I get a different error message (in that case TNS:could not resolve the connect identifier specified). So, DBI understands my xxx SID. The error is not caused by a busy network because I am connecting locally, and sqlplus is able to connect.
Does anybody have any suggestions?
Thank you.
Anke
Received on Wed Jan 17 2007 - 13:01:36 CST