cancel
Showing results for 
Search instead for 
Did you mean: 

bin Files are not deleted from contentstore

itayh
Champ in-the-making
Champ in-the-making
Hi,

During the past few months we used alfresco with 2 different configuration of the contentStoreCleaner bean, One with the deletedContentBackupListener and one without (according to the Wiki at http://wiki.alfresco.com/wiki/Content_Store_Configuration).
Since we notice that the size of the contentstore (not contentstore.deleted) getting big we start to investigate. We found very old binaries under contentstore that should have been deleted (I can see them as deleted in the audit, in the alf_node table the protocol column is archive and I can not find them in the web client).
We are using version 2.1
Do we need something to configure? Is it a bug? is there a work around?

Thanks in advance
9 REPLIES 9

itayh
Champ in-the-making
Champ in-the-making
One more important question, how can we permanently delete those archive files?

rogier_oudshoor
Champ in-the-making
Champ in-the-making
Hi itayh,

Alfresco (by default) archives deleted items into its archivestore. You can turn this off as shown here: http://wiki.alfresco.com/wiki/Disabling_Document_Archival. Alternatively, under your User Profile, there's a Managed Delete Items section where you can manually decide what to do. At least, that's there in my (3.0) version …

Cheers,

Rogier

itayh
Champ in-the-making
Champ in-the-making
Thanks Rogier,

Any Idea how to permanently delete all the already archived files? We switch off the archive flag  but we still want to delete all our archives.

thanks,
Itay

rogier_oudshoor
Champ in-the-making
Champ in-the-making
Assuming you cannot acces the "managed deleted items" in your version, you could create some Java code to clean the store: create a spring bean, get the nodeArchiveService from spring injection, do a search inside the archivestore for all nodes, and use the nodeArchiveService to purge them all.

itayh
Champ in-the-making
Champ in-the-making
Thanks Rogier,

The nodeArchiveService actually delete all the archive items from the DB but it did not delete themfrom the contentstore (the binaries are still in the file system). Any Idea how to delete them?

Thanks,
  Itay

rogier_oudshoor
Champ in-the-making
Champ in-the-making
The move of binaries from the contentstore to contentstore.deleted is done by a backgroundjob on a daily basis (every afternoon at 4 o' clock I believe). Try waiting 24 hours and checking again Smiley Wink

itayh
Champ in-the-making
Champ in-the-making
thanks Rogier Smiley Happy

itayh
Champ in-the-making
Champ in-the-making
Hi Rogier,

When running nodeArchiveService.purgeAllArchivedNodes I get the next error:
Caused by: com.mysql.jdbc.exceptions.MySQLIntegrityConstraintViolationException: Cannot delete or update a parent row: a foreign key constraint fails (`alfresco/alf_node_status`, CONSTRAINT `FK71C2002B7F2C8017` FOREIGN KEY (`node_id`) REFERENCES `alf_node` (`id`))

Any Idea?

robinflow
Champ in-the-making
Champ in-the-making
Check these links to purge deleted, but still existing files in contentstore:
Cleaning up Orphaned Content (Purge)  - http://wiki.alfresco.com/wiki/Content_Store_Configuration#Cleaning_up_Orphaned_Content_.28Purge.29
Eager Content Cleanup - http://wiki.alfresco.com/wiki/Content_Store_Configuration#Eager_Content_Cleanup