Images Missing After Recent Discourse Upgrade (Post-XenForo Migration)

AI-generated summary

After migrating from XenForo to Discourse and performing a recent upgrade, user sniper756 noticed that some images in older posts were missing. The issue appeared after the upgrade, with broken image links like ![image_1758326972601.jpg|1356x1946](upload://mqCFZoHUyjyxAah049QAmvq9cMH.jpeg). The system is running Discourse v2025.12.0-latest +291, with local uploads and no CDN or S3. Running rake posts:missing_uploads revealed 2061 missing uploads affecting 738 of 3542 posts. The user resolved the issue by executing rake uploads: recover and rake posts:rebake, after which pfaffman commended the fix.

Hi everyone,

We recently migrated our forum from XenForo to Discourse, and everything was working fine — including all attachment images in posts.

However, after a recent Discourse admin upgrade (via the web interface), some images in older posts are no longer displaying. For example, in one post, the image that was previously visible is now showing as broken or missing.

Example image markdown that is no longer working:

![image_1758326972601.jpg|1356x1946](upload://mqCFZoHUyjyxAah049QAmvq9cMH.jpeg)

System info:

  • Discourse version: v2025.12.0-latest +291

  • Not using S3

  • Not using CDN

  • Images were uploaded locally and were displaying fine before the upgrade

Has anyone experienced this issue before? Could this be related to the automatic cleanup of unused uploads, or something else introduced in a recent update?

We’d appreciate any guidance on how to troubleshoot or restore these missing images.

Thanks in advance!

root@jerry-app:/var/www/discourse# rake posts:missing_uploads
Looking for missing uploads on: default

2061 post uploads are missing.

2050 uploads are missing.
738 of 3542 posts are affected.
./launcher enter app
rake uploads:recover
rake posts:rebake

It is OK

Nice work! Glad you figured it out!