Error when trying to empty the recycle bin

Vote:
 

I am having problems emptying the recycle bin in Episerver. I have approximately 16,000 items in the bin, and I receive a timeout error whenever I try and empty this. I have tried on several occasions to do this, but I receive the same error each time.

Is there another way to do this to get around the error?

#163916
Oct 24, 2016 9:58
Vote:
 

Hi Sam,

Have you tried to run a scheduled job "Automatic Emptying of Trash"? It shouldn't time out.

#164182
Oct 24, 2016 11:57
Vote:
 

When I tried running the scheduled task, it came up with the following error 'Connect failed'. I've been trying to work out of there is a SQL query that I can run directly on the database, but wanted to make sure that I don't leave loads of orphaned data in the DB.

#164183
Oct 24, 2016 12:14
Vote:
 

Hi, Sam,

In case of many content items in the recycle bin, I'd suggest going to DB directly (Do back it up first). The timeout can be increased, however, if it's that many items, you'd need to increase it too much and it's valid for any other queries Epi executes.

So, instead, backup and run a SP called editDeleteChilds with page ID of recycle bin (usually 2).

Then, make sure to set up the scheduled job to get executed regularily :)

BR,
Marija

#170690
Oct 26, 2016 15:56
Vote:
 

Hi Sam,

Agree with Marija but before that it is good idea to run this query " SELECT pkId, COUNT(*) FROM tblWorkPage GROUP BY pkID ORDER BY 2 DESC" and then from the sql result run editDeleteChilds with id of the page .. remember there is argument for editDeleteChilds for ForceDelete which if you pass "1" it will deleted even it is linked!

#170707
Oct 27, 2016 6:24
Vote:
 

Thanks Marija and  Aria for your replies. I've just got my DBA to run the SP and although it did delete some items (around 1000), we are now receiving a constrainst error. When we try and re-run again, no further items are deleted.

Do we need to stop the main episerver service to get this to work?

#171197
Nov 02, 2016 14:06
Vote:
 

In case anyone comes across this topic, there is an article here on this issue and how to resolve

https://support.optimizely.com/hc/en-us/articles/360002082371-Unable-to-empty-Episerver-trash-due-to-corrupt-files-or-excessive-files

#330614
Sep 27, 2024 16:10
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.