Amazon S3 orphan images not removing


(Vikas Dangi) #1

Remove orphan unreferenced uploads is checked in my forum but still the orphan images are not removing automatically.

To check this I have uploaded a images yesterday to my forum but still it is accessible.

defenceforum-img-s3.s3-ap-south-1.amazonaws.com/original/1X/b2597229c427eead298ccb553a44ce92c2190e28.jpg


(Jeff Atwood) #2

I don’t think we remove from S3, just local.


(Vikas Dangi) #3

Then how can I protect my s3 from illegal hosting


(Régis Hanol) #4

Cleaning up orphan uploads should work for both local and S3 storages.

The only difference between the local and S3 storages is that the cleanup of the tombstone is automatically handled by S3 via a policy.

@Vikas_Dangi have you enabled the clean_up_uploads site setting? Are you sure that image isn’t used somewhere else (avatar, user profile, category image, etc…)?


(Vikas Dangi) #5

Yes the clean up upload is enabled and the grace period hours is set to 1. But the images are still not removing.

I have uploaded the image to just check the functionality, so i have not used the image in any post, avatar or other.


(Mittineague) #6

I’m not understanding. You uploaded but didn’t use?
How did you upload it?


(Vikas Dangi) #7

I have uploaded it through upload button. But didn’t posted it in the topic, so it became orphan image. But my problem is that the orphaned imaged not removing automatically.


(Mittineague) #8

Correct me if I’m wrong.

  • you opened the composer
  • you uploaded the image via the upload icon
  • then canceled the post

i.e. The image is not being removed from the Draft


(Vikas Dangi) #9

Yes your 3 points are correct. But the image is not removing from the s3 server.


(Vikas Dangi) #10

now its working thanks.