[thelist] (apparently) Unclosed database connections
Bruce MacKay
b.mackay at massey.ac.nz
Fri Jul 18 22:20:44 CDT 2003
Hi folks,
Hope this is not too off-track.
I run a IIS server running 15 separate sites, all running the same VLE
(virtual learning environment) ASP application. Each site uses a separate
Access database as its backend.
For the past 1.5 years, the system has worked flawlessly, but over the last
4 weeks, we have started encountering faults on all the sites - database
connections do not appear to be closing. The end result is that any site
function involving a database call results in an error and the site becomes
unusable.
While we have checked the code and cannot find any page which opens a
connection but doesn't subsequently close it, it is quite possible we have
missed something. As a type of shotgun approach, we are thinking of
calling the following function at the very bottom of each page....
sub Destroy
On error Resume Next
If (Not (rs Is Nothing)) Then
If (rs.State = adStateOpen) Then
rs.Close
set rs=nothing
end if
end if
If (Not (conn Is Nothing)) Then
If (rs.State = adStateOpen) Then
conn.Close
set conn=nothing
end if
end if
End sub
Does anyone have any other suggestions of what we might do? Changing the
database is not on our list - any one of our sites has only 10-15 students
on at any given time, with 20-50 students per site per day. Access has
coped with this "load" without any problems thus far. The databases are
regularly compacted and currently range from 8-24 MB in size.
The sysop added Norton AntiVirus about 3 weeks ago - given its known
problems with the FSO object, I had him later remove it hoping that it was
the source of the problem - unfortunately we weren't able to restore normal
behaviour.
If there is another list to which I should be directing this question,
please let me know.
Cheers,
Bruce
More information about the thelist
mailing list