D
David Browne
nandu said:Hello everyone,
We have developed a windows forms application using C# and access
Oracle8i database using web services developed using asp.net. The
version of the Oracle database we use is 8.1.7. Both the web server
and db are on windows 2000 servers.
We can connect to the database and work on the application, but after
3-4 hours the application looses connection to the database and this
happens even if no one uses the application also. I can start working
again just by opening and saving the web.config file. (this probably
is resetting the connection pool).
The errors we get are
ORA-03113: end-of-file on communication channel
and
ORA-03114: not connected to ORACLE
I have seen many threads posted earlier with same or similar issues.
Could any of you get a solution to this?
Your help is greatly appreciated as the application is developed and
runs, but cannot be used.
There may be a number of causes of this.
But they all have the same solution.
The root problem is that when connections sit in the connection pool for a
long time, they may break. In your case this may be caused by a firewall
closing your connection, or your Oracle Server going down for reboot, or an
intermediate switch going down, etc.
In general over a span of hours some connections can be broken. To account
for this you should validate the connection after retrieving it from the
connection pool. Then if you get ORA-03114 or ORA-03113, you can just open
a new connection. To validate your connection, send a cheap command back to
the server. I recommend this one:
alter session set NLS_DATE_FORMAT='yyyy-mm-dd HH24:mi:ss'
Which kills two birds, because you don't have to use Oracle's silly default
date format.
David
David