1

Whenever, we delete a file in Alfresco Document library that file moves to Trashcan and the files are marked as archived in DB (moved to archived store).

If the user deletes the file in Trashcan then after 14 days the file will be moved from contenStore to contentStore.deleted folder. Then Sys admin can delete the file from the file system. But file's metadata and other data related to that file is still in DB and are still marked as archived and not deleted from the DB.

How should I delete the achieved DB entries. I saw few blogs stating those entries will be deleted after 30 days or something. But I do not see anything like that in my Alfresco set up. What properties I have to change or configure to delete old DB entries? and how should I run it manually?

sabtharishi
  • 3,141
  • 5
  • 24
  • 27

1 Answers1

3

this article explains very good what happens behind the scenes for the Alfresco document lifecyle.

In short:

nodeServiceCleanupJobDetail is registered in alfresco/WEB-INF/classes/alfresco/scheduled-jobs-context.xmlto be run at 9:00 pm every day to remove the nodes and obsolete transactions in the repository database if contentStoreCleaner was successful running 14 days after removing content from the trash at 4:00 am (defined in the orphan-cleaner scheduled job).

Heiko Robert
  • 2,488
  • 11
  • 12
  • If the job is not running: is your alfresco running at 9:00 pm? Out of the box you can only define a custom spring bean registering this job on a different point of time. Starting manually requires coding. – Heiko Robert Apr 01 '16 at 14:46
  • Useful document like the one I want to see . Thanks for Sharing. The document says something like this **_After 30 days from when the ‘node_deleted’ field was set to ‘1’, this process considers it safe to truly delete the node with a call to the DAO service purge._** Where is the 30 days configuration and how can I change it? Also in which table we will have "node_deleted" column? – sabtharishi Apr 01 '16 at 17:10
  • I searched the entire DB for **node_deleted** column but it does not found. I am using Alfresco 4.2.2. – sabtharishi Apr 01 '16 at 17:47
  • This is the correct answer. Don't mess around in the database. Look at alfresco/WEB-INF/classes/alfresco/scheduled-jobs-context.xml, you'll see where it's configured. I've made it run more frequently and put it in debug without any negative repercussions. – matthew p. Apr 05 '16 at 15:49