# Attachment broken link even though attachment still exist in file system

**URL:** <https://forum.xwiki.org/t/attachment-broken-link-even-though-attachment-still-exist-in-file-system/4720>\
**Category:** Help / Discuss\
**Tags:** attachments\
**Created:** [March 28, 2019, 10:55pm UTC](https://forum.xwiki.org/t/attachment-broken-link-even-though-attachment-still-exist-in-file-system/4720 "2019-03-28T22:55:09Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![kevinyu](https://forum.xwiki.org/letter_avatar_proxy/v4/letter/k/35a633/32.png) [@kevinyu](https://forum.xwiki.org/u/kevinyu)\
**Post date:** [March 28, 2019, 10:55pm UTC](https://forum.xwiki.org/t/attachment-broken-link-even-though-attachment-still-exist-in-file-system/4720/1 "2019-03-28T22:55:10Z")

</div>

I run into this issue, which has happened a few times but I cannot reproduce.

After I attached a file to a page for a while, it would become broken link and seems like xwiki cannot find it anymore. However, the attachment is still in the file system.

![Screenshot%20from%202019-03-28%2014-40-02](https://discourse.xwiki.org/uploads/default/original/2X/5/54320dbd65d18ff219b7c1118e446f8ce48b9f77.png)

---

<div class="post-metadata">

**Author:** ![kevinyu](https://forum.xwiki.org/letter_avatar_proxy/v4/letter/k/35a633/32.png) [@kevinyu](https://forum.xwiki.org/u/kevinyu)\
**Post date:** [March 28, 2019, 10:56pm UTC](https://forum.xwiki.org/t/attachment-broken-link-even-though-attachment-still-exist-in-file-system/4720/2 "2019-03-28T22:56:27Z")

</div>

Just to show the file is in the file system

![Screenshot%20from%202019-03-28%2014-37-11](https://discourse.xwiki.org/uploads/default/original/2X/b/b170968f36fbc0581d5c306d77464da47d2456cc.png)

---

<div class="post-metadata">

**Author:** ![tmortagne](https://forum.xwiki.org/user_avatar/forum.xwiki.org/tmortagne/32/4930_2.png) [@tmortagne](https://forum.xwiki.org/u/tmortagne)\
**Post date:** [March 29, 2019, 3:06pm UTC](https://forum.xwiki.org/t/attachment-broken-link-even-though-attachment-still-exist-in-file-system/4720/3 "2019-03-29T15:06:12Z")

</div>

If you click on the attachment (to access that file directly in your browser) you should get a more detailed error I think. Any error in the log ?

---

<div class="post-metadata">

**Author:** ![kevinyu](https://forum.xwiki.org/letter_avatar_proxy/v4/letter/k/35a633/32.png) [@kevinyu](https://forum.xwiki.org/u/kevinyu)\
**Post date:** [March 29, 2019, 5:17pm UTC](https://forum.xwiki.org/t/attachment-broken-link-even-though-attachment-still-exist-in-file-system/4720/4 "2019-03-29T17:17:22Z")

</div>

When I click in the link, it redirects to the xwiki’s customised ‘not found’ page and says cannot find the page and then shows a bunch of suggestions of other pages.

In the log, the only line related to this is

 ![Screenshot%20from%202019-03-29%2010-14-52](https://forum.xwiki.org/uploads/default/original/2X/0/0c33c179ffd126a0351af1f59b696340280e8c7d.png)

But I don’t think this is the problem, as I see this warning for other pictures too. In my Nginx access.log, I see this:

access.log.1:172.18.25.90 - - [28/Mar/2019:14:35:07 -0700] “GET /bin/download/QualityManagement/QMS/QualityManagementDoc10065/WebHome/SoftwareLifeCycle.gif HTTP/1.1” 404 5636 “[https://quality.corp.fortinet.com/bin/view/QualityManagement/QMS/QualityManagementDoc10065/](https://quality.corp.fortinet.com/bin/view/QualityManagement/QMS/QualityManagementDoc10065/)” “Mozilla/5.0 (X11; Linux x86\_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36”

---

<div class="post-metadata">

**Author:** ![tmortagne](https://forum.xwiki.org/user_avatar/forum.xwiki.org/tmortagne/32/4930_2.png) [@tmortagne](https://forum.xwiki.org/u/tmortagne)\
**Post date:** [March 29, 2019, 8:29pm UTC](https://forum.xwiki.org/t/attachment-broken-link-even-though-attachment-still-exist-in-file-system/4720/5 "2019-03-29T20:29:54Z")

</div>

This is weird, 404 is supposed to mean that the attachment is not listed in the document but it’s listed for you obviously. If it was failing to load it for some reason you should get an error 500.

Yes the log you pasted is not linked to the 404.

And you have this issue only for specific attachments ? Not all ?
