Hanging SQL Queries

I have an application running version 7.2.8. We have a redundant setup of ignition servers and a separate MS SQL Server for history data. Every couple of weeks we have to restart the Ignition service because we accumulate enough hanging queries that we max out our number of active connections. Here is a screen shot of the DB Connection monitor so you can see what I mean:

This image only shows 2 hanging queries right now, but these connections will stay open for over a week. These hanging connections will just accumulate at a rate of 1 every 2-3 days until there are 8 of them. At that point all trending breaks and we have to restart the gateway service in order to restore functionality.

Any idea why I would have queries that hang for days on end?

Is this a case where the connection testing under the connection configuration would be useful? I have looked for documentation about the idle connection evictor but have come up empty handed in the forum and the online documentation.

I had that issue with 7.2.8 as well, it was fixed in the newer versions. You should try and install a newer version. I think 7.2.9 fixed this issue.

Also, it’s important to check what version of Java you’re using, as Java 6 update 29 had a problem that could cause this (although, as far as I’m aware, I’m pretty sure you wouldn’t be able to get this far if that were the case). Still, you should check by taking a look at the first status page when you go to “Config” in the gateway.

The next thing to check would be whether SQL Server thinks the queries are still running. I believe you can do this from the SQL Server Profiler tool that is included with the server (you should also be able to check with a query, such as described at this site). If the server doesn’t show the query, it would indicate a problem on our side, which may have already been fixed.

Hope this helps,

Thanks for the help.

The update wound up fixing the issue. The system has been running for a couple of weeks now with no hanging/stalled queries.