When inserting an image on a page, a view file macro is used instead

Still need help?

The Atlassian Community is here for you.

Ask the community

Problem

When inserting an image on a page, a view file macro is inserted instead of an image. This may cause different rendering of the image to what you expect, for example it may look pixelated.

The logs specified that Confluence unable to create either the following directory inside the Confluence_Home folder: 

  • dcl-thumbnail
  • thumbnails

The following appears in the atlassian-confluence.log

2015-10-09 07:13:28,121 WARN [http-nio-8686-exec-19] [persistence.dao.filesystem.HierarchicalContentFileSystemHelper] createDirectoryHierarchy Failed to create directory at CONFLUENCE_HOME/thumbnails/##/#/#########
 -- referer: BASE_URL/pages/createpage.action?spaceKey=SPACEKEY | url: /rest/prototype/1/attachment/#########.json | userName: username
2015-10-09 07:13:28,137 WARN [http-nio-8686-exec-19] [plugins.rest.manager.DefaultRestAttachmentManager] setThumbnailInfo Thumbnail not set, cannot render thumbnail for Attachment: image.jpg v.1 (#########) username
 -- referer: BASE_URL/pages/createpage.action?spaceKey=SPACEKEY | url: /rest/prototype/1/attachment/#########.json | userName: username

or

2015-09-15 20:15:50,011 WARN [http-bio-8443-exec-38] [persistence.dao.filesystem.HierarchicalContentFileSystemHelper] createDirectoryHierarchy Failed to create directory at CONFLUENCE_HOME/dcl-thumbnail/##/#/#########

Cause

When inserting an image, if a thumbnail does not exist, Confluence will instead use a view file macro. Normally Confluence creates a thumbnail for you to browse images when inserting, however if for some reason thumbnail creation fails, this can happen.

Some reasons why this could fail:

  • Not enough permissions for the Confluence users to create the thumbnail file or directory
  • Some filesystem limit might have been hit, for example by default on Linux directories are limited to 31999 subdirectories per directory for ext2/ext3/ext4 filesystems

Resolution

  • If there is a permission issue, you will need to ensure that the Confluence user is able to write to the thumbnails directory.

  • If you have hit the Linux filesystem subdirectory limit, then you can clear out the thumbnails directory and allow it to be regenerated as needed.

Last modified on Oct 23, 2017

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.