We are currently using a dev hub to perform various bits of Salesforce integration testing. Part of this testing involves changing the Chatter profile picture and creating posts/comments etc.

I suspect that every time a new profile photo is uploaded, the old one is still left in the system somewhere and not deleted, which has resulted in our dev hub using up all of its 20MB File Storage. When I check the Storage Usage tab in Settings, I can see a few MB under "Photos" (and thousands of records) for some of our users, but when you check the content library for these users the old profile files are not there.

How do I delete these records from the system?

  • Can you do query of ContentDocument -- select Id, Title FROM ContentDocument in dev console and see if there are any records? those could be deleted (And they are not shown in library )
    – kurunve
    Apr 9 '21 at 12:41
  • ContentDocument is only showing 9 records in workbench, so unfortunately does not seem to include these thousands of orphaned photos.
    – Charlie
    Apr 9 '21 at 12:56

Based on similar ask on developer forum (https://developer.salesforce.com/forums/?id=9062I000000Xu1OQAS) in the past, clearing of photo storage or backend recalculation of storage requires Salesforce support's intervention.

Please consider logging a case with Salesforce support to resolve this conflict.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.