- This topic has 7 replies, 3 voices, and was last updated 3 years, 3 months ago by
David.
-
AuthorPosts
-
November 23, 2022 at 3:23 pm #2430094
James
Hello,
We have a number of images that exceed the big_image_size_threshold and so have been resized by WordPress and have “-scaled” appended to the image file name. (https://make.wordpress.org/core/2019/10/09/introducing-handling-of-big-images-in-wordpress-5-3/)
I can’t understand why, but for some reason the thumbnails and the original file are today missing when yesterday they were physically on the server. This first happened on 8 Nov 22 and again today (23 nov 22). I worked around this last time by duplicating the scaled images, removing the “-scaled” text from the copy and using wpcli to regenerate the thumbnails. Given that this solution lasted for only 15 days I’m now trying to understand why this is happening. It does seem to correlate with the release of GeneratePress 3.2.2 and GeneratePress 3.2.3.
I have included some samples in the private information section to help with debugging. Really hope we can work together to isolate this issue.
Fingers crossed!
November 23, 2022 at 3:41 pm #2430108Ying
StaffCustomer SupportHi there,
GP doesn’t have control over the image files, it’s 100% controlled by WP.
Do you have any plugins that do image optimizations?
November 25, 2022 at 8:08 am #2433390James
I’m not aware of any active plugins that do image optimisations, as I said before updating to GeneratePress 3.2.2 and GeneratePress 3.2.3 seems to be a related trigger for the ‘-scaled’ images to vanish.
I’ve managed to regenerate the thumbnails using the ‘wp media regenerate’ command in wpcli but am still very keen to understand why this has happened twice – are you able to escalate this?
November 25, 2022 at 8:36 am #2433449David
StaffCustomer SupportHi there,
i have asked amongst my colleagues and none of them has experienced this kind issue before.
We can categorically state that it is not a theme or GP Premium related issue.
None of our code interferes with the way WordPress saves or generates media attachments.It would either be a database issue, and perhaps your host can check the logs to see what caused them to be deleted.
Or a plugin issue, looking at your plugin list, i see:Enable Media Replace– which reading its description is a plugin that does write to the media library, so maybe its support could answer whether this is a risk.November 25, 2022 at 9:51 am #2433633James
Thank you David for the rapid response and for helping to rule out GeneratePress.
I disabled Enable Media Replace (EMR) after the first incident on 8 Nov 22 thinking the same as you that it writes to the media library (it should have shown as inactive in the list I shared privately). That said there was an update to EMR from version 4.0.0 to 4.0.1 which I installed on on the same day as GeneratePress 3.2.3 … but it was updated in a deactivated state so I had ruled it out in my mind.
In any case I will now delete EMR completely and wait and see if the issue reoccurs.
I understand that general debugging is outside the scope of GP support but when you say ‘a database issue’ are you able to give any more of a steer on keywords that I should be Googling for to continue debugging this. I have already spoken with my host (Kinsta) and they are unwilling to help debug this because they don’t believe infrastructure is the cause.
Thanks again!
November 25, 2022 at 10:30 am #2433885David
StaffCustomer SupportKinsta should be able scan the database to check if any issues. It may not be a conclusive – here is your problem – but it may show up some things that need repairing.
Otherwise you would need to monitor database activity looking for
post_type = 'attachment'entries to see what is writing to that table. Again its not conclusive but may point to whats changing.There are some plugins that monitor database activity like this one:
December 16, 2022 at 5:57 am #2464084James
Working with Kinsta we haven’t found any issues with the database. In the end I have manually renamed the image files to remove ‘-scaled’ from the URL and search-replace the database references. Seems to be working so far, hopefully this fix is permanent.
Thank you for confirming that it is not a theme or GP Premium related issue, helpful to narrow this down!
(For reference, this stack exchange explains why ‘-scaled’ is added: https://wordpress.stackexchange.com/questions/353845/how-to-disable-the-suffix-scaled-which-is-being-added-at-the-end-of-each-uplo)
December 16, 2022 at 6:48 am #2464149David
StaffCustomer SupportGlad to hear you’re making some progress with the issue. Hopefully the search and replace will work and its permanent !
-
AuthorPosts
- You must be logged in to reply to this topic.