SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Report Execution Has Expired or Cannot Be Found


Report Execution Has Expired or Cannot Be Found

Author
Message
Courtney12345
Courtney12345
SSC Rookie
SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)

Group: General Forum Members
Points: 36 Visits: 36
I wrote a python program to bulk download ssrs reports.
The program sends a url to the browser to download an SSRS report, which it then renames and moves to specified directory for each key in a dictionary holding parameter values for the report.
For the parameters I've been testing each time I run my program I hit the same SSRS report 63 times.
The problem is that during development, I notice that after a while SSRS stops responding with the error
"The report server execution yhsoj1vs4bjdyqn4c4nw4k55 has expired or cannot be found. (rsExecutionNotFound)".
Then I cannot even manually run the report. The problem usually resolves itself within an hour but how do I prevent this from happening?
Sue_H
Sue_H
SSC-Dedicated
SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)

Group: General Forum Members
Points: 33642 Visits: 9596
Courtney12345 - Monday, May 1, 2017 6:01 PM
I wrote a python program to bulk download ssrs reports.
The program sends a url to the browser to download an SSRS report, which it then renames and moves to specified directory for each key in a dictionary holding parameter values for the report.
For the parameters I've been testing each time I run my program I hit the same SSRS report 63 times.
The problem is that during development, I notice that after a while SSRS stops responding with the error
"The report server execution yhsoj1vs4bjdyqn4c4nw4k55 has expired or cannot be found. (rsExecutionNotFound)".
Then I cannot even manually run the report. The problem usually resolves itself within an hour but how do I prevent this from happening?


It could be the parameters or it could be session timeout or it could be just draining too much of the memory. Is that how it's going to run in production - you hit the same report 63 times? And is that just continually hitting that report? When it stops responding "after awhile" its that with breaks or continually hitting the report?
Have you looked in the Reporting Services log as well as the execution log view in the ReportServer database for other issues, errors when this happens?

Sue



Courtney12345
Courtney12345
SSC Rookie
SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)

Group: General Forum Members
Points: 36 Visits: 36
Sue_H - Monday, May 1, 2017 7:32 PM
Courtney12345 - Monday, May 1, 2017 6:01 PM
I wrote a python program to bulk download ssrs reports.
The program sends a url to the browser to download an SSRS report, which it then renames and moves to specified directory for each key in a dictionary holding parameter values for the report.
For the parameters I've been testing each time I run my program I hit the same SSRS report 63 times.
The problem is that during development, I notice that after a while SSRS stops responding with the error
"The report server execution yhsoj1vs4bjdyqn4c4nw4k55 has expired or cannot be found. (rsExecutionNotFound)".
Then I cannot even manually run the report. The problem usually resolves itself within an hour but how do I prevent this from happening?


It could be the parameters or it could be session timeout or it could be just draining too much of the memory. Is that how it's going to run in production - you hit the same report 63 times? And is that just continually hitting that report? When it stops responding "after awhile" its that with breaks or continually hitting the report?
Have you looked in the Reporting Services log as well as the execution log view in the ReportServer database for other issues, errors when this happens?

Sue

I don't think the parameters that I am passing is the issue because I can pass those same parameters when the report is working without a problem. And the report normally renders very quickly (generally under 5 seconds) since it is based on a very simple query. In production we will need to hit the same report 63 times because as far as I am aware SSRS doesn't have an option to run the same report with multiple parameter selection but to download as distinct files with customized file names on demand. When I say the server "stops responding after a while" I mean that I run my program during development several times successfully but after the 6th or 7th or 10th run for example when I visit the url, I see the "rsExecutionNotFound" error. The number of times I can run my program before the report server stops responding varies. It has stopped responding after just 2 runs, but sometimes I can run my program 20 times before the server stops responding. I checked the Reporting Services log as well as the execution log view in the ReportServer database and nothing seems out of the ordinary.

Sue_H
Sue_H
SSC-Dedicated
SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)

Group: General Forum Members
Points: 33642 Visits: 9596


If the only error is rsExecutionNotFound that could be different than the "report server execution xxxx has expired or cannot be found". I'm guessing you just shortened things - it is a pain to type of the full error message.

Either way, it will be in the Reporting services log which would give you more information. And there is some information in the Execution Log views to help you track things down. You just need to know what to look at. You could increase timeout values but that can also have some side effects. I would probably want to monitor that session and see if it actually hit a timeout.

When/if you get the error, report server execution xxxx has expired, check for that xxx value in the ReportServerTempDB database in the SessionData table. That is the SessionID. That can be correlated back to the ExecutionLog3 and the ExecutionID.

Just from there you can find a lot of what is going on. Are you using the same sessionid on each hit to the report or different ones on each request. Normally it's different sessionids but in some scenarios you can be using the same one each time. So if that runs over the session timeout periods, that would explain things.
Did you really hit a timeout with that sessionid? You can tell by the first start time in the Executionlog view or you get more details if the sessionid is still in the SessionData table in ReportServerTempDB. So you can tell a lot by just checking these things.

And you can find the timeout values if you query the ConfigurationInfo table.
At at the system level, the SystemReportTimeout is the same as what you have if you go to the Report Manager URL, go to site settings and the general page on the right has the Report Timeout Settings.
At the session level, you have session timeout and SessionAccess Timeout (usually depends on what version of SSRS for the Session Access value). These are in the properties for SSRS in SSMS if you connect to the ReportServer, on the server name do properties and go to advanced.

At this point, if you don't have a good idea or want to test the different settings, the easiest one would be the Site Settings and just set the Report Timeout to Do Not Timeout. And see if you get the error.
I can't tell how you are actually running your program to test but I would first guess it's a session timeout setting. In the SSRS server properties in SSMS, I would increase that to something more than 10 mins which is the default 600 secs. You don't want to go overboard with that since it can increase the time things are left in the ReportServerTempDB and consequently affect the size. The SessionAccessTimeout should be a different error in the Reporting Services log - I think the timeout shows up with a call to GetSessionData, can't remember for sure. But I would guess that's not the issue.

All of that should give you enough info to check into what's going on and change whatever timeout values you may need to change. Hope that helps - please post back on if you get it resolved or still have problems or questions.

Sue



Courtney12345
Courtney12345
SSC Rookie
SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)SSC Rookie (36 reputation)

Group: General Forum Members
Points: 36 Visits: 36
Sue_H - Tuesday, May 2, 2017 9:08 AM


If the only error is rsExecutionNotFound that could be different than the "report server execution xxxx has expired or cannot be found". I'm guessing you just shortened things - it is a pain to type of the full error message.

Either way, it will be in the Reporting services log which would give you more information. And there is some information in the Execution Log views to help you track things down. You just need to know what to look at. You could increase timeout values but that can also have some side effects. I would probably want to monitor that session and see if it actually hit a timeout.

When/if you get the error, report server execution xxxx has expired, check for that xxx value in the ReportServerTempDB database in the SessionData table. That is the SessionID. That can be correlated back to the ExecutionLog3 and the ExecutionID.

Just from there you can find a lot of what is going on. Are you using the same sessionid on each hit to the report or different ones on each request. Normally it's different sessionids but in some scenarios you can be using the same one each time. So if that runs over the session timeout periods, that would explain things.
Did you really hit a timeout with that sessionid? You can tell by the first start time in the Executionlog view or you get more details if the sessionid is still in the SessionData table in ReportServerTempDB. So you can tell a lot by just checking these things.

And you can find the timeout values if you query the ConfigurationInfo table.
At at the system level, the SystemReportTimeout is the same as what you have if you go to the Report Manager URL, go to site settings and the general page on the right has the Report Timeout Settings.
At the session level, you have session timeout and SessionAccess Timeout (usually depends on what version of SSRS for the Session Access value). These are in the properties for SSRS in SSMS if you connect to the ReportServer, on the server name do properties and go to advanced.

At this point, if you don't have a good idea or want to test the different settings, the easiest one would be the Site Settings and just set the Report Timeout to Do Not Timeout. And see if you get the error.
I can't tell how you are actually running your program to test but I would first guess it's a session timeout setting. In the SSRS server properties in SSMS, I would increase that to something more than 10 mins which is the default 600 secs. You don't want to go overboard with that since it can increase the time things are left in the ReportServerTempDB and consequently affect the size. The SessionAccessTimeout should be a different error in the Reporting Services log - I think the timeout shows up with a call to GetSessionData, can't remember for sure. But I would guess that's not the issue.

All of that should give you enough info to check into what's going on and change whatever timeout values you may need to change. Hope that helps - please post back on if you get it resolved or still have problems or questions.

Sue

I double-checked in the SessionData table in ReportServerTempDB, for each time my program runs the report a distinct SessionID is used, so I don't think it is a timeout issue, unless I am overlooking something?
Here is the full error from the reporting services log:
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.;
ERROR: Throwing Microsoft.ReportingServices.Diagnostics.Utilities.ExecutionNotFoundException: , Microsoft.ReportingServices.Diagnostics.Utilities.ExecutionNotFoundException: The report execution yhsoj1vs4bjdyqn4c4nw4k55 has expired or cannot be found.;
These are the 2 error I see when the report stops responding.
At this point we think it as a memory issue. We are thinking of just letting the people who will eventually be running my program to due so at off hours.
Thank you for all your help Sue!

jpratt-797544
jpratt-797544
Mr or Mrs. 500
Mr or Mrs. 500 (532 reputation)Mr or Mrs. 500 (532 reputation)Mr or Mrs. 500 (532 reputation)Mr or Mrs. 500 (532 reputation)Mr or Mrs. 500 (532 reputation)Mr or Mrs. 500 (532 reputation)Mr or Mrs. 500 (532 reputation)Mr or Mrs. 500 (532 reputation)

Group: General Forum Members
Points: 532 Visits: 80
I have just encountered a similar error and symptoms after deploying Power BI Report Server October 2017 GA on a SQL Server 2016 Enterprise server. I had been running SSRS 2016 (and multiple versions before that) without issue. The same URL and report have been working for years, so the only known change was PBIRS. The error was occurring when clicking a URL link in a web page to run an SSRS/paginated report and generate it as a PDF so the user can save it to disk. Based on other posts I found, I added "&rs:ClearSession=True" to the URL and it worked immediately just by refreshing the web page containing the URL (no server-side resets). I've had to use that parameter before with SSRS reports embedded in an iFrame.
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum








































































































































































SQLServerCentral


Search