Unable to connect to database for 1 of many reports

  • Hi all,

    Our report server (SSRS 2008 R2) has about a dozen reports. All but 1 work fine. The one that doesn't shows this in Even Viewer: Microsoft.ReportingServices.Library.ReportServerDatabaseUnavailableException:

    Complaining that it cannot connect to the ReportServer database.

    The report server is then hosed until it's restarted. Why just this one report (which used to work just fine, and hasn't been changed for the past 6 weeks)? What should I be looking for, or where should I look for more information?

    This is a new report server folder, being set up for product demos. The reports were deployed via Visual Studio. The database is small.

    Regards,

    Tom

  • I would suggest deleting both the report and the data source from the Report server and then redeploying.

    If you need some additional information about the exact nature of the error you can look at the Report server log files on the server:

    \Program Files\Microsoft SQL Server\MSRS10.MSSQLSERVER\Reporting Services\LogFiles

  • That (the error log) is where I got the exception information from. It wasn't very informative. And any thoughts on why only the 1 report would cause problems?

  • Deleting the report and data source didn't help.

  • Does this help any? The first error says error may be due to connection failure, timeout, or low disk condition. There are only 10 or so user connections to the database, and about 8 GB space available. The query that returns the buld of the data only returns 219 rows. And just to repeat, other reports running on the same server run just fine. Using Sql Profiler to follow the database activity, it appears that the data for the report is retrieved successfully, and the problem occurs during report rendering. I'm at a loss, and this is a blocker to releasing the next version of our product to production.

    library!ReportServer_0-2!13d0!04/13/2012-08:47:18:: e ERROR: Throwing Microsoft.ReportingServices.Diagnostics.Utilities.ReportServerStorageException: , An error occurred within the report server database. This may be due to a connection failure, timeout or low disk condition within the database.;

    session!ReportServer_0-2!13d0!04/13/2012-08:47:18:: e ERROR: Error in GetSnapshotData: Microsoft.ReportingServices.Diagnostics.Utilities.ReportServerStorageException: An error occurred within the report server database. This may be due to a connection failure, timeout or low disk condition within the database. ---> System.Data.SqlClient.SqlException: Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding.

    at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)

    at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)

    at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)

    at System.Data.SqlClient.SqlDataReader.ConsumeMetaData()

    at System.Data.SqlClient.SqlDataReader.get_MetaData()

    at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)

    at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async)

    at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result)

    at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)

    at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)

    at System.Data.SqlClient.SqlCommand.ExecuteReader()

    at Microsoft.ReportingServices.Library.InstrumentedSqlCommand.<ExecuteReader>b__1()

    at Microsoft.ReportingServices.Library.SqlBoundaryWithReturn`1.Invoke(Method m)

    --- End of inner exception stack trace ---

    at Microsoft.ReportingServices.Library.Storage.WrapAndThrowKnownExceptionTypes(Exception e)

    at Microsoft.ReportingServices.Library.SqlBoundaryWithReturn`1.Invoke(Method m)

    at Microsoft.ReportingServices.Library.InstrumentedSqlCommand.ExecuteReader()

    at Microsoft.ReportingServices.Library.DatabaseSessionStorage.GetSessionData(String sessionId, UserContext userContext, ConnectionManager connMgr)

    processing!ReportServer_0-2!60c!04/13/2012-08:48:11:: An error has occurred during data evaluation of the GaugePanel 'GaugePanel1'.

    reportrendering!ReportServer_0-2!60c!04/13/2012-08:48:11:: e ERROR: Throwing Microsoft.ReportingServices.ReportProcessing.RenderingObjectModelException: , Microsoft.ReportingServices.ReportProcessing.RenderingObjectModelException: An error has occurred during data evaluation of the GaugePanel 'GaugePanel1'.;

  • That's a good log!

    I have weird problems rendering but only when using those new fancy Dundas-esque controls. Is the failing report using any of those new fancy 2008 R2 controls? Do you see anything about this failing report's controls / gadgetry that is different from the working reports? Are you open to removing controls 1 by 1 and re-rendering with each until you get an acceptable render?

    Do any of the working reports use that same query that only returns 219 rows? Perhaps in preparing the report data the report server consumes enough resources so that when it moves on the render there's little left to render with.

  • mikeg 31960 (4/13/2012)


    That's a good log!

    I have weird problems rendering but only when using those new fancy Dundas-esque controls. Is the failing report using any of those new fancy 2008 R2 controls? Do you see anything about this failing report's controls / gadgetry that is different from the working reports? Are you open to removing controls 1 by 1 and re-rendering with each until you get an acceptable render?

    Do any of the working reports use that same query that only returns 219 rows? Perhaps in preparing the report data the report server consumes enough resources so that when it moves on the render there's little left to render with.

    The only "fancy" control is a guage panel. There is a bit of code that creates a "bar chart" by setting text box fill color for 9 adjacent columns. That's all the fancy stuff.

    And I've begun the exercise of removing columns 1 by 1. Removing both the guage panel and the "bar chart" have had no effect.

    Another oddity: this report renders just fine on my local report server (using the same database server as the QA/test server, so the data is the same).

  • Your thoughtful reply, the windows event entry "cannot connect to the ReportServer database", the fact that it works on your Dev Report Server but not on QA/Prod all lead me to suspect it is environmental.

    Is the company using the SQL network protocol TCP/IP on all machines involved? Perhaps Dev, where it works, is strictly TCP/IP while QA/Prod is both TCP/IP NamedPipes. If then my next thought would be to disable Named Pipes everywhere.

    What kind of data source is this report using?

  • mikeg 31960 (4/13/2012)


    Your thoughtful reply, the windows event entry "cannot connect to the ReportServer database", the fact that it works on your Dev Report Server but not on QA/Prod all lead me to suspect it is environmental.

    Is the company using the SQL network protocol TCP/IP on all machines involved? Perhaps Dev, where it works, is strictly TCP/IP while QA/Prod is both TCP/IP NamedPipes. If then my next thought would be to disable Named Pipes everywhere.

    What kind of data source is this report using?

    TCP/IP/Named Pipes configured the same on all machines.

    The report is using a shared data source, type is Microsoft Sql Server

    Please keep those cards and letters coming 🙂

  • So, if I remove about 2/3 of the columns in the report, it will render. This report was first deployed about 6 months ago, and was working fine. Now :crying:

  • Is it possible to have too many columns that depend on custom code for rendering? This report has, among other columns, 13 columns (a gauge panel, three numeric columns, and 9 columns formatted as a bar chart) that all depend on custom code for setting their values, fonts, and background color. Can this maybe just overwhelm the report processor?

    It turns out that this report runs on version 2.1 of the database schema, but fails on version 2.2. The differences between the two schemas are in tables that this report does NOT use, or added columns that this report does NOT reference.

    I have finally managed to get the report running by completely rewriting it from scratch, without most of the custom code (involved figuring out some pretty wild nested IIF expressions). Unfortunately I do not know the underlying reason(s) that the report failed.

Viewing 11 posts - 1 through 10 (of 10 total)

You must be logged in to reply to this topic. Login to reply