You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've noticed that PDF files don't have a preview generated. It just shows a PDF icon.
Besides that, I wanted to use Nextcloud as a replacement for Office 365, however I can't edit docx, pptx, and xls files in the browser either.
I'm mentioning these errors in the same issue, because I think they're caused by the same problem, which is ImageMagick.
In general, there are 2 different errors, which are below in the 'log' section.
One is basically an error, saying ImageMagick failed to read the file (which is a really common one) and a more rare error is ImageMagick saying they're unable to open the delegates.xml file.
Now I have zero knowledge about ImageMagick, so I don't know what any of this really means, or how to fix this.
I think a possible solution would be to completely get rid of Imagick, as was discussed in #13099, but I don't know how difficult it is, since I'm not very knowledgeable about the Nextcloud codebase.
Steps to reproduce
Upload a PDF
Generate a preview
See error
Expected behavior
I expected Nextcloud to generate PDFs and to open office documents like it's supposed to
Installation method
Manual installation
Operating system
Other
PHP engine version
PHP 7.4
Web server
Apache (supported)
Database engine version
MySQL
Is this bug present after an update or on a fresh install?
No response
Are you using the Nextcloud Server Encryption module?
The 'Imagick can't read the file' error:{"reqId":"HKjgGQGb4E1nKPv4K2JI","level":3,"time":"2022-04-26T19:43:43+00:00","remoteAddr":"xx.xx.xx.xxx","user":"JVT038","app":"core","method":"GET","url":"/core/preview?fileId=8&c=4df36753a5660db347d2e3de74ff9667&x=250&y=250&forceIcon=0&a=0","message":"File: /JVT038/files/Documents/Nextcloud flyer.pdf Imagick says:","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:99.0) Gecko/20100101 Firefox/99.0","version":"23.0.4.1","exception":{"Exception":"ImagickException","Message":"Failed to read the file","Code":1,"Trace":[{"file":"/volume1/web/nextcloud/lib/private/Preview/Bitmap.php","line":86,"function":"readimage","class":"Imagick","type":"->","args":["/volume1/Streaming/Nextcloud/JVT038/files/Documents/Nextcloud flyer.pdf[0]"]},{"file":"/volume1/web/nextcloud/lib/private/Preview/Bitmap.php","line":49,"function":"getResizedPreview","class":"OC\\Preview\\Bitmap","type":"->","args":["/volume1/Streaming/Nextcloud/JVT038/files/Documents/Nextcloud flyer.pdf",4096,4096]},{"file":"/volume1/web/nextcloud/lib/private/Preview/GeneratorHelper.php","line":62,"function":"getThumbnail","class":"OC\\Preview\\Bitmap","type":"->","args":[{"__class__":"OC\\Files\\Node\\File"},4096,4096]},{"file":"/volume1/web/nextcloud/lib/private/Preview/Generator.php","line":245,"function":"getThumbnail","class":"OC\\Preview\\GeneratorHelper","type":"->","args":[{"__class__":"OC\\Preview\\PDF"},{"__class__":"OC\\Files\\Node\\File"},4096,4096]},{"file":"/volume1/web/nextcloud/lib/private/Preview/Generator.php","line":140,"function":"getMaxPreview","class":"OC\\Preview\\Generator","type":"->","args":[{"__class__":"OC\\Files\\SimpleFS\\SimpleFolder"},{"__class__":"OC\\Files\\Node\\File"},"application/pdf",""]},{"file":"/volume1/web/nextcloud/lib/private/Preview/Generator.php","line":109,"function":"generatePreviews","class":"OC\\Preview\\Generator","type":"->","args":[{"__class__":"OC\\Files\\Node\\File"},[{"width":250,"height":250,"crop":true,"mode":"fill"}],"application/pdf"]},{"file":"/volume1/web/nextcloud/lib/private/PreviewManager.php","line":212,"function":"getPreview","class":"OC\\Preview\\Generator","type":"->","args":[{"__class__":"OC\\Files\\Node\\File"},250,250,true,"fill",null]},{"file":"/volume1/web/nextcloud/core/Controller/PreviewController.php","line":169,"function":"getPreview","class":"OC\\PreviewManager","type":"->","args":[{"__class__":"OC\\Files\\Node\\File"},250,250,true,"fill"]},{"file":"/volume1/web/nextcloud/core/Controller/PreviewController.php","line":142,"function":"fetchPreview","class":"OC\\Core\\Controller\\PreviewController","type":"->","args":[{"__class__":"OC\\Files\\Node\\File"},250,250,false,false,"fill"]},{"file":"/volume1/web/nextcloud/lib/private/AppFramework/Http/Dispatcher.php","line":217,"function":"getPreviewByFileId","class":"OC\\Core\\Controller\\PreviewController","type":"->","args":[8,250,250,false,false,"fill"]},{"file":"/volume1/web/nextcloud/lib/private/AppFramework/Http/Dispatcher.php","line":126,"function":"executeController","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->","args":[{"__class__":"OC\\Core\\Controller\\PreviewController"},"getPreviewByFileId"]},{"file":"/volume1/web/nextcloud/lib/private/AppFramework/App.php","line":157,"function":"dispatch","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->","args":[{"__class__":"OC\\Core\\Controller\\PreviewController"},"getPreviewByFileId"]},{"file":"/volume1/web/nextcloud/lib/private/Route/Router.php","line":302,"function":"main","class":"OC\\AppFramework\\App","type":"::","args":["OC\\Core\\Controller\\PreviewController","getPreviewByFileId",{"__class__":"OC\\AppFramework\\DependencyInjection\\DIContainer"},{"_route":"core.Preview.getPreviewByFileId"}]},{"file":"/volume1/web/nextcloud/lib/base.php","line":1008,"function":"match","class":"OC\\Route\\Router","type":"->","args":["/core/preview"]},{"file":"/volume1/web/nextcloud/index.php","line":36,"function":"handleRequest","class":"OC","type":"::","args":[]}],"File":"/volume1/web/nextcloud/lib/private/Preview/Bitmap.php","Line":86,"CustomMessage":"File: /JVT038/files/Documents/Nextcloud flyer.pdf Imagick says:"},"id":"62684c2838b99"}The delegates error:{"reqId":"dXuf1ugFGhpc9Eqzqk6T","level":3,"time":"2022-04-26T19:34:13+00:00","remoteAddr":"xx.xx.xx.xxx","user":"JVT038","app":"core","method":"GET","url":"/core/preview?fileId=139124&c=93465a86a84498b74a77123920bd4e57&x=250&y=250&forceIcon=0&a=0","message":"File: /JVT038/files/Documents/pdffile.pdf Imagick says:","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:99.0) Gecko/20100101 Firefox/99.0","version":"23.0.4.1","exception":{"Exception":"ImagickException","Message":"UnableToOpenConfigureFile `delegates.xml' @ warning/configure.c/GetConfigureOptions/681","Code":395,"Trace":[{"file":"/volume1/web/nextcloud/lib/private/Preview/Bitmap.php","line":86,"function":"readimage","class":"Imagick","type":"->","args":["/volume1/Streaming/Nextcloud/JVT038/files/Documents/pdffile.pdf[0]"]},{"file":"/volume1/web/nextcloud/lib/private/Preview/Bitmap.php","line":49,"function":"getResizedPreview","class":"OC\\Preview\\Bitmap","type":"->","args":["/volume1/Streaming/Nextcloud/JVT038/files/Documents/pdffile.pdf",4096,4096]},{"file":"/volume1/web/nextcloud/lib/private/Preview/GeneratorHelper.php","line":62,"function":"getThumbnail","class":"OC\\Preview\\Bitmap","type":"->","args":[{"__class__":"OC\\Files\\Node\\File"},4096,4096]},{"file":"/volume1/web/nextcloud/lib/private/Preview/Generator.php","line":245,"function":"getThumbnail","class":"OC\\Preview\\GeneratorHelper","type":"->","args":[{"__class__":"OC\\Preview\\PDF"},{"__class__":"OC\\Files\\Node\\File"},4096,4096]},{"file":"/volume1/web/nextcloud/lib/private/Preview/Generator.php","line":140,"function":"getMaxPreview","class":"OC\\Preview\\Generator","type":"->","args":[{"__class__":"OC\\Files\\SimpleFS\\SimpleFolder"},{"__class__":"OC\\Files\\Node\\File"},"application/pdf",""]},{"file":"/volume1/web/nextcloud/lib/private/Preview/Generator.php","line":109,"function":"generatePreviews","class":"OC\\Preview\\Generator","type":"->","args":[{"__class__":"OC\\Files\\Node\\File"},[{"width":250,"height":250,"crop":true,"mode":"fill"}],"application/pdf"]},{"file":"/volume1/web/nextcloud/lib/private/PreviewManager.php","line":212,"function":"getPreview","class":"OC\\Preview\\Generator","type":"->","args":[{"__class__":"OC\\Files\\Node\\File"},250,250,true,"fill",null]},{"file":"/volume1/web/nextcloud/core/Controller/PreviewController.php","line":169,"function":"getPreview","class":"OC\\PreviewManager","type":"->","args":[{"__class__":"OC\\Files\\Node\\File"},250,250,true,"fill"]},{"file":"/volume1/web/nextcloud/core/Controller/PreviewController.php","line":142,"function":"fetchPreview","class":"OC\\Core\\Controller\\PreviewController","type":"->","args":[{"__class__":"OC\\Files\\Node\\File"},250,250,false,false,"fill"]},{"file":"/volume1/web/nextcloud/lib/private/AppFramework/Http/Dispatcher.php","line":217,"function":"getPreviewByFileId","class":"OC\\Core\\Controller\\PreviewController","type":"->","args":[139124,250,250,false,false,"fill"]},{"file":"/volume1/web/nextcloud/lib/private/AppFramework/Http/Dispatcher.php","line":126,"function":"executeController","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->","args":[{"__class__":"OC\\Core\\Controller\\PreviewController"},"getPreviewByFileId"]},{"file":"/volume1/web/nextcloud/lib/private/AppFramework/App.php","line":157,"function":"dispatch","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->","args":[{"__class__":"OC\\Core\\Controller\\PreviewController"},"getPreviewByFileId"]},{"file":"/volume1/web/nextcloud/lib/private/Route/Router.php","line":302,"function":"main","class":"OC\\AppFramework\\App","type":"::","args":["OC\\Core\\Controller\\PreviewController","getPreviewByFileId",{"__class__":"OC\\AppFramework\\DependencyInjection\\DIContainer"},{"_route":"core.Preview.getPreviewByFileId"}]},{"file":"/volume1/web/nextcloud/lib/base.php","line":1008,"function":"match","class":"OC\\Route\\Router","type":"->","args":["/core/preview"]},{"file":"/volume1/web/nextcloud/index.php","line":36,"function":"handleRequest","class":"OC","type":"::","args":[]}],"File":"/volume1/web/nextcloud/lib/private/Preview/Bitmap.php","Line":86,"CustomMessage":"File: /JVT038/files/Documents/pdffile.pdf Imagick says:"},"id":"62684c2839511"}
Additional info
I'm using Nextcloud on my Synology NAS (DS918+) and I've manually installed it by extracting a zip file into the web folder and to set up a virtual host in the web station app of Synology.
It uses Apache 2.4, and redis, apcu, imagemagick and everything required is enabled.
I access my Nextcloud instance through a reverse proxy, and for this I'm using the NGINX Proxy Manager. If it's necessary, I can supply the NGINX information as well.
The text was updated successfully, but these errors were encountered:
As this seems to be a setup issue I would like to ask you to raise your question in the forums: https://help.nextcloud.com
If you wish support with setup issues from Nextcloud GmbH we offer this as part of the Nextcloud subscription. Learn more about this at https://nextcloud.com/enterprise/
Bug description
I've noticed that PDF files don't have a preview generated. It just shows a PDF icon.
Besides that, I wanted to use Nextcloud as a replacement for Office 365, however I can't edit docx, pptx, and xls files in the browser either.
I'm mentioning these errors in the same issue, because I think they're caused by the same problem, which is ImageMagick.
In general, there are 2 different errors, which are below in the 'log' section.
One is basically an error, saying ImageMagick failed to read the file (which is a really common one) and a more rare error is ImageMagick saying they're unable to open the
delegates.xml
file.Now I have zero knowledge about ImageMagick, so I don't know what any of this really means, or how to fix this.
I think a possible solution would be to completely get rid of Imagick, as was discussed in #13099, but I don't know how difficult it is, since I'm not very knowledgeable about the Nextcloud codebase.
Steps to reproduce
Expected behavior
I expected Nextcloud to generate PDFs and to open office documents like it's supposed to
Installation method
Manual installation
Operating system
Other
PHP engine version
PHP 7.4
Web server
Apache (supported)
Database engine version
MySQL
Is this bug present after an update or on a fresh install?
No response
Are you using the Nextcloud Server Encryption module?
Encryption is Disabled
What user-backends are you using?
Configuration report
List of activated Apps
Nextcloud Signing status
Nextcloud Logs
Additional info
I'm using Nextcloud on my Synology NAS (DS918+) and I've manually installed it by extracting a zip file into the web folder and to set up a virtual host in the web station app of Synology.
It uses Apache 2.4, and redis, apcu, imagemagick and everything required is enabled.
I access my Nextcloud instance through a reverse proxy, and for this I'm using the NGINX Proxy Manager. If it's necessary, I can supply the NGINX information as well.
The text was updated successfully, but these errors were encountered: