Problems to preview attachments in Confluence, Error rendering macro 'view-file'

お困りですか?

アトラシアン コミュニティをご利用ください。

コミュニティに質問

プラットフォームについて: Server および Data Center のみ。この記事は、Server および Data Center プラットフォームのアトラシアン製品にのみ適用されます。

Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Fisheye および Crucible は除く

  

要約

Attachments aren't displayed on the page and preview isn't working. Using the View File macro may error out with Error rendering macro 'view-file':

環境

This problem was identified in Confluence server and datacenter version 7.11.0 but, due to the nature of the problem, it can affect most versions of Confluence.


診断

Attachments can't be previewed and aren't displayed on pages. It's possible to find more about the problem by analyzing the file atlassian-confluence.log and looking for the following errors:

com.atlassian.confluence.pages.AttachmentDataNotFoundException: Problem while getting attachment stream
ERROR [http-nio-8090-exec-16] [[Standalone].[localhost].[/].[noop]] log Servlet.service() for servlet [noop] in context with path [] threw exception
java.io.FileNotFoundException: /data/confluence/sharedhome/dcl-thumbnail/11/11/44536111/118956102_8 (Permission denied)
WARN [http-nio-8090-exec-4] [atlassian.confluence.pages.DefaultAttachmentManager] getAttachmentData Could not find data for attachment: Attachment: filename test - java.io.FileNotFoundException: /data/confluence/sharedhome/attachments/ver003/111/111/45383611/11/11/44536111/118956111/1 (Permission denied)


原因

The root cause reported in this KB is related to Permission denied to the folder where the attachments reside as seen in the aforementioned errors. By not having the correct permissions, Confluence won't be able to retrieve the attachment from the file system to be displayed in its UI. 

It's also possible that the attachments are actually missing from the file system. In this case, refer to How to resolve missing attachments in Confluence.


ソリューション

File system permissions depend on the operational system, we recommend following How to set file system permissions for Confluence to resolve this problem.


Last modified on Mar 29, 2021

この内容はお役に立ちましたか?

はい
いいえ
この記事についてのフィードバックを送信する
Powered by Confluence and Scroll Viewport.