You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@verside2, can you elaborate a bit more on the use case here. How would this be used in an example?
We have a server that monitors the status of over 200 databases. The database versions are different (11.2.0.3.0, 12.1.0.2.0 and 18.0.0.0.0).
The verification process takes place in two stages:
First, the connection to the database takes place.
Next, a simple query is executed.
this.#connection =awaitoracledb.getConnection(this.#dbSettings);// path to sqlnet.ora and instantclient_23_26this.#connection.callTimeout=this.#dbReqTimeout;awaitthis.#connection.execute("select * from mytable");
The following parameters are specified in the sqlnet.ora file:
Periodically, in case of network problems, waiting for a connection (stage 1) takes significantly longer than 1 minute. It has not been possible to find out why this happens. It feels like the timeout is either working or not.
But at the same time, when it comes to stage 2 (query execution), everything works perfectly thanks to the callTimeout setting.
To solve the problem, we have to do something like this:
getDbConnection(dbSettings){const{promise, resolve, reject}=Promise.withResolvers();consttimerId=setTimeout(()=>reject(newError("Error message")),Times.MINUTE);oracledb.getConnection(dbSettings).then(resolve).catch(reject).finally(()=>clearTimeout(timerId));returnpromise;}
...
this.#connection =awaitthis.getDbConnection(this.#dbSettings);// path to sqlnet.ora and instantclient_23_26
...
HI @verside2 ,
If you are using pool (createPool), you should have got the following error: NJS-040 If the default queueTimeout should get triggered in latest node-oracledb release 6.10.0.
NJS-040: connection request timeout. Request exceeded "queueTimeout" of 60000
If you use standalone, (getConnection ) , Can you share sqlnet trace logs If it is feasible to reproduce : Following are the steps.
# setenv
ADR_BASE=/tmp/mylogs
TRACE_LEVEL_CLIENT=16
Set `TNS_ADMIN` so that Node can read `$TNS_ADMIN/sqlnet.ora` and run mkdir /tmp/mylogs. Execute the app and share the logs collected in /tmp/mylogs.
Can you share details of DB, client versions where this issue is seen. Is this only on thick mode?
this.#dbSettings ={user: xxx,password: xxx,connectString: `(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=${xxx})(PORT=1521))(CONNECT_DATA=(SID=ORCL)))`,poolIncrement: 0,poolMax: 1,poolMin: 1,};
...
oracledb.initOracleClient({configDir: this.#configDir,libDir: SETTINGS.instantClientPath,});
...
console.log("start base connect");this.#connection =awaitthis.getDbConnection();// see belowthis.#connection.callTimeout=this.#dbReqTimeout;// 60 secondsconsole.log("start base execute");awaitthis.#connection.execute("select * from mytable");
...
asyncgetDbConnection(){constpool=awaitoracledb.createPool(this.#dbSettings);this.#connectionPool =pool;returnpool.getConnection();}
...
The log of the freeze is attached (unfortunately, writing a clean log is problematic, as connections to several databases may be checked simultaneously. At the moment, there is only one suitable example with a detailed log).
Summary:
"27.08.2026, 03:25:36","t-nnov-01-l working","start base connect"
"27.08.2026, 03:29:07","t-nnov-01-l working","start base execute"
Adding the SQLNET.RECV_TIMEOUT = 60 parameter to the sqlnet.ora file seems to solve the problem. Without this, no other timeouts help.
System info at this time:
Ubuntu 24.04.5 (and 26.04.1)
nodejs 24.21.0
oracle instant client (basic lite package zip) 23.26.3.0.0
oracledb 7.0.1
Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production (for the example provided in the log)
Activity
[-]Support AbortSignal for timeout[/-][+]Support AbortController for timeout[/+][-]Support AbortController for timeout[/-][+]Support AbortController[/+]sharadraju commentedon Oct 16, 2025
Thanks @verside2. We will evaluate this.
sharadraju commentedon Dec 9, 2025
@verside2, can you elaborate a bit more on the use case here.
How would this be used in an example?
verside2 commentedon Dec 15, 2025
We have a server that monitors the status of over 200 databases. The database versions are different (11.2.0.3.0, 12.1.0.2.0 and 18.0.0.0.0).
The verification process takes place in two stages:
The following parameters are specified in the sqlnet.ora file:
Periodically, in case of network problems, waiting for a connection (stage 1) takes significantly longer than 1 minute. It has not been possible to find out why this happens. It feels like the timeout is either working or not.
But at the same time, when it comes to stage 2 (query execution), everything works perfectly thanks to the callTimeout setting.
To solve the problem, we have to do something like this:
sudarshan12s commentedon Feb 9, 2026
HI @verside2 ,
If you are using pool (
createPool), you should have got the following error:NJS-040If the default queueTimeout should get triggered in latest node-oracledb release 6.10.0.NJS-040: connection request timeout. Request exceeded "queueTimeout" of 60000If you use standalone, (
getConnection) , Can you share sqlnet trace logs If it is feasible to reproduce : Following are the steps.Can you share details of DB, client versions where this issue is seen. Is this only on thick mode?
verside2 commentedon Sep 26, 2026
Hello! I apologize for the delayed response. What we managed to find out during this time:
sqlnet.ora
monitoring.js
Summary:
SQLNET.RECV_TIMEOUT = 60parameter to thesqlnet.orafile seems to solve the problem. Without this, no other timeouts help.System info at this time:
Ubuntu 24.04.5 (and 26.04.1)
nodejs 24.21.0
oracle instant client (basic lite package zip) 23.26.3.0.0
oracledb 7.0.1
Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production (for the example provided in the log)
ora_145052_131725593056960.trc.log