Ask Questions and Find Answers
Important:
Ask is now read-only. You can review any existing questions and answers, but not add anything new.
But - don't panic! While ask is no more, we've replaced it with discuss - the new Liferay Discussion Forum! Read more here here or just visit the site here:
discuss.liferay.com
RE: Liferay 7 file Preview content wrong displaying
Hi All,I am using liferay 7 GA5 and uploading the files in document library nearly 3 MB files and above but the preview of files and thumbnails generating content is wrong and not exactly as file.here i am using java-1.8.0-openjdk-1.8.0.222-2.i am facing issue in windows and Ubuntu.
i set the image magic and ghost-scripts like below.
imagemagick.enabled=true
imagemagick.global.search.path[windows]=C:\\Program Files\\gs\\gs9.19\\bin;C:\\Program Files\\ImageMagick-7.0.2-Q16imagemagick.global.search.path[unix]=/usr/bin:/usr/share/fonts/type1/gsfonts
as per properties file from src imagemagick.global.search.path[unix]=/usr/local/bin:/usr/local/share/ghostscript/fonts:/usr/local/share/fonts/urw-fonts --- here i did not find the urw-fonts do we need to install separatly urw-fonts?
i set the image magic and ghost-scripts like below.
imagemagick.enabled=true
imagemagick.global.search.path[windows]=C:\\Program Files\\gs\\gs9.19\\bin;C:\\Program Files\\ImageMagick-7.0.2-Q16imagemagick.global.search.path[unix]=/usr/bin:/usr/share/fonts/type1/gsfonts
as per properties file from src imagemagick.global.search.path[unix]=/usr/local/bin:/usr/local/share/ghostscript/fonts:/usr/local/share/fonts/urw-fonts --- here i did not find the urw-fonts do we need to install separatly urw-fonts?
Hi Srini --
I think you have two questions here. With the issue regarding the font, I did a quick google search and found a few (other) forum threads where people are reporting the same issue. This one, seems to have a solution. I know it is for centos, but you -should be able to install an RPM in ubuntu as well.
For your OTHER question, the one referred to in the subject, I did come across something like this recently, though it was for an older version of Liferay -- 6.2 in fact. Couple of questions for you --
1. Are any of the files generating previews? for example, JPGs are fine, but PDFs never seem to work
2. Are you working in a clustered environment? ... I have seen cases where the preview shows up on one server, but not the other and it is related to the environment configuration (eg. each node configured with a different document store)
3. On the subject of document store - can you share with us which Document storage type you have configured?
There are also a whole pile of properties that are associated with the preview generation. Some of them are just to control the output of course, but others are used to toggle it on and off -- and there are dependencies on other properties as well. Here are the default values, but I would suggest using the control panel to see what values are in place in your runtime
Lastly, though I am not sure it would help, there is a 7.0 GA6 -- have you tried possibly upgrading to the latest version to see if there is a fix that solves your problem?
I think you have two questions here. With the issue regarding the font, I did a quick google search and found a few (other) forum threads where people are reporting the same issue. This one, seems to have a solution. I know it is for centos, but you -should be able to install an RPM in ubuntu as well.
For your OTHER question, the one referred to in the subject, I did come across something like this recently, though it was for an older version of Liferay -- 6.2 in fact. Couple of questions for you --
1. Are any of the files generating previews? for example, JPGs are fine, but PDFs never seem to work
2. Are you working in a clustered environment? ... I have seen cases where the preview shows up on one server, but not the other and it is related to the environment configuration (eg. each node configured with a different document store)
3. On the subject of document store - can you share with us which Document storage type you have configured?
There are also a whole pile of properties that are associated with the preview generation. Some of them are just to control the output of course, but others are used to toggle it on and off -- and there are dependencies on other properties as well. Here are the default values, but I would suggest using the control panel to see what values are in place in your runtime
## Set the maximum file size for preview and thumbnail generation. Files# larger than the value specified in this property will not result in the# execution of a processor that generates a preview. A value of -1 indicates# that all files will be processed. A value of 0 indicates that no files# will be processed. The default maximum size is 100 megabytes.#dl.file.entry.previewable.processor.max.size=104857600
## Set the values related to preview and thumbnail generation for document# library files. The classes enabled under "dl.file.entry.processors" will# utilize these parameters to generate the necessary files.## Some parameters are applied universally across all processors (e.g.,# dl.file.entry.thumbnail.max.height) while others are specific to certain# types of generation, as specified (e.g.,# dl.file.entry.preview.document.depth).## If the property "dl.file.entry.preview.video.height" or the property# "dl.file.entry.preview.video.width" is set to 0, then respective height# and width of the video file will be used.## See the properties "imagemagick.enabled", "openoffice.server.enabled", and# "xuggler.enabled".#dl.file.entry.preview.enabled=truedl.file.entry.preview.document.depth=8dl.file.entry.preview.document.dpi=300dl.file.entry.preview.document.max.height=0dl.file.entry.preview.document.max.width=1000dl.file.entry.preview.video.height=360dl.file.entry.preview.video.width=640Lastly, though I am not sure it would help, there is a 7.0 GA6 -- have you tried possibly upgrading to the latest version to see if there is a fix that solves your problem?
Andrew Jardine:
Hi Srini --
I think you have two questions here. With the issue regarding the font, I did a quick google search and found a few (other) forum threads where people are reporting the same issue. This one, seems to have a solution. I know it is for centos, but you -should be able to install an RPM in ubuntu as well.
For your OTHER question, the one referred to in the subject, I did come across something like this recently, though it was for an older version of Liferay -- 6.2 in fact. Couple of questions for you --
1. Are any of the files generating previews? for example, JPGs are fine, but PDFs never seem to work
2. Are you working in a clustered environment? ... I have seen cases where the preview shows up on one server, but not the other and it is related to the environment configuration (eg. each node configured with a different document store)
3. On the subject of document store - can you share with us which Document storage type you have configured?
There are also a whole pile of properties that are associated with the preview generation. Some of them are just to control the output of course, but others are used to toggle it on and off -- and there are dependencies on other properties as well. Here are the default values, but I would suggest using the control panel to see what values are in place in your runtime## Set the maximum file size for preview and thumbnail generation. Files# larger than the value specified in this property will not result in the# execution of a processor that generates a preview. A value of -1 indicates# that all files will be processed. A value of 0 indicates that no files# will be processed. The default maximum size is 100 megabytes.#dl.file.entry.previewable.processor.max.size=104857600## Set the values related to preview and thumbnail generation for document# library files. The classes enabled under "dl.file.entry.processors" will# utilize these parameters to generate the necessary files.## Some parameters are applied universally across all processors (e.g.,# dl.file.entry.thumbnail.max.height) while others are specific to certain# types of generation, as specified (e.g.,# dl.file.entry.preview.document.depth).## If the property "dl.file.entry.preview.video.height" or the property# "dl.file.entry.preview.video.width" is set to 0, then respective height# and width of the video file will be used.## See the properties "imagemagick.enabled", "openoffice.server.enabled", and# "xuggler.enabled".#dl.file.entry.preview.enabled=truedl.file.entry.preview.document.depth=8dl.file.entry.preview.document.dpi=300dl.file.entry.preview.document.max.height=0dl.file.entry.preview.document.max.width=1000dl.file.entry.preview.video.height=360dl.file.entry.preview.video.width=640
Lastly, though I am not sure it would help, there is a 7.0 GA6 -- have you tried possibly upgrading to the latest version to see if there is a fix that solves your problem?
Hi Andrew,
Thanks for your Quick reply.most of the properties i keep it same as default except below property
dl.file.entry.previewable.processor.max.size=-1 -- here i given -1 because all size files will preview.
dl.file.entry.processors i did not tuch any thing because i am uploading .docx files and by default it will support.
7.0 GA 6 i did not tried it still but will try it.i am using here open-jdk it will any impact on converting to preview file?
Hi Srini,
Ok, good to know that you're using the stock settings. I'm still wondering about the different file types though. You mentioned docx files, but are you seeing this behaviour for ALL files? or just certain file types?
Ok, good to know that you're using the stock settings. I'm still wondering about the different file types though. You mentioned docx files, but are you seeing this behaviour for ALL files? or just certain file types?
Andrew Jardine:
Hi Srini,
Ok, good to know that you're using the stock settings. I'm still wondering about the different file types though. You mentioned docx files, but are you seeing this behaviour for ALL files? or just certain file types?
Hi Andrew,
I am seeing only for .docx files. in this files also only heading with numbers place i am facing issue example below here 2.1 place some time it will get different number and some times that number won't display. in windows i am not getting numbers but in ubuntu box i am getting 1.1 like that. tested in GA6 also same issue.
Even i am tested with 7.2.0-ga1 version same issue i am facing.
Attachments: