No picture previews in nextcloud 11.0.1

migrated from OC to NC yesterday and see errors in the logs, additionally I can’t get any pics shown in the browser.
Tried to install preview-generator (wasn’t there in the beginning), gives no output even when run on the shell.
permissions look ok to me.

This is a gentoo linux server.
I copied the config.php from OC.

nextcloud log contains lines like:

{“reqId”:"/wczM5Sclc8xzZeEfbXw",“remoteAddr”:"",“app”:“PHP”,“message”:“fopen(/var/www/localhost/htdocs/owncloud/data/sgw/files/documents/admin.txt): failed to open stream: No such file or directory at /var/www/localhost/htdocs/nextcloud/lib/private/Files/Storage/Local.php#287”,“level”:3,“time”:“2017-02-06T08:46:56+00:00”,“method”:"–",“url”:"–",“user”:"–",“version”:“11.0.1.2”}
{“reqId”:"/wczM5Sclc8xzZeEfbXw",“remoteAddr”:"",“app”:“PHP”,“message”:“stream_get_contents() expects parameter 1 to be resource, boolean given at /var/www/localhost/htdocs/nextcloud/lib/private/Preview/TXT.php#49”,“level”:3,“time”:“2017-02-06T08:46:56+00:00”,“method”:"–",“url”:"–",“user”:"–",“version”:“11.0.1.2”}
{“reqId”:"/wczM5Sclc8xzZeEfbXw",“remoteAddr”:"",“app”:“PHP”,“message”:“fopen(/var/www/localhost/htdocs/owncloud/data/sgw/files/sun.txt): failed to open stream: No such file or directory at /var/www/localhost/htdocs/nextcloud/lib/private/Files/Storage/Local.php#287”,“level”:3,“time”:“2017-02-06T08:46:59+00:00”,“method”:"–",“url”:"–",“user”:"–",“version”:“11.0.1.2”}
{“reqId”:"/wczM5Sclc8xzZeEfbXw",“remoteAddr”:"",“app”:“PHP”,“message”:“stream_get_contents() expects parameter 1 to be resource, boolean given at /var/www/localhost/htdocs/nextcloud/lib/private/Preview/TXT.php#49”,“level”:3,“time”:“2017-02-06T08:46:59+00:00”,“method”:"–",“url”:"–",“user”:"–",“version”:“11.0.1.2”}

Compare to Previewgenerator App 1.0.1 is not working

been there. “-vvv” shows nothing:

$ sudo -u apache php /var/www/localhost/htdocs/nextcloud/occ preview:generate-all -vvv
The process control (PCNTL) extensions are required in case you want to interrupt long running commands - see http://php.net/manual/en/book.pcntl.php

runs for a few seconds, no output, no previews generated.

logs generated:

{“reqId”:“fUaMoAEBe1eRSWnIAsmB”,“remoteAddr”:"",“app”:“PHP”,“message”:“fread() expects parameter 1 to be resource, boolean given at /var/www/localhost/htdocs/nextcloud/lib/private/Files/Storage/Local.php#217”,“level”:3,“time”:“2017-02-06T13:05:23+00:00”,“method”:"–",“url”:"–",“user”:"–",“version”:“11.0.1.2”}
{“reqId”:“fUaMoAEBe1eRSWnIAsmB”,“remoteAddr”:"",“app”:“PHP”,“message”:“fclose() expects parameter 1 to be resource, boolean given at /var/www/localhost/htdocs/nextcloud/lib/private/Files/Storage/Local.php#218”,“level”:3,“time”:“2017-02-06T13:05:23+00:00”,“method”:"–",“url”:"–",“user”:"–",“version”:“11.0.1.2”}
{“reqId”:“fUaMoAEBe1eRSWnIAsmB”,“remoteAddr”:"",“app”:“PHP”,“message”:“imagecreatefromstring(): Empty string or invalid image at /var/www/localhost/htdocs/nextcloud/lib/private/legacy/image.php#597”,“level”:3,“time”:“2017-02-06T13:05:23+00:00”,“method”:"–",“url”:"–",“user”:"–",“version”:“11.0.1.2”}
{“reqId”:“fUaMoAEBe1eRSWnIAsmB”,“remoteAddr”:"",“app”:“PHP”,“message”:“fopen(/var/www/localhost/htdocs/owncloud/data/sgw/files/Public/sambabtrfs.txt): failed to open stream: No such file or directory at /var/www/localhost/htdocs/nextcloud/lib/private/Files/Storage/Local.php#287”,“level”:3,“time”:“2017-02-06T13:05:23+00:00”,“method”:"–",“url”:"–",“user”:"–",“version”:“11.0.1.2”}
{“reqId”:“fUaMoAEBe1eRSWnIAsmB”,“remoteAddr”:"",“app”:“PHP”,“message”:“stream_get_contents() expects parameter 1 to be resource, boolean given at /var/www/localhost/htdocs/nextcloud/lib/private/Preview/TXT.php#49”,“level”:3,“time”:“2017-02-06T13:05:23+00:00”,“method”:"–",“url”:"–",“user”:"–",“version”:“11.0.1.2”}
{“reqId”:“fUaMoAEBe1eRSWnIAsmB”,“remoteAddr”:"",“app”:“PHP”,“message”:“fopen(/var/www/localhost/htdocs/owncloud/data/sgw/files/Sport/Klettern/Langenstein.txt): failed to open stream: No such file or directory at /var/www/localhost/htdocs/nextcloud/lib/private/Files/Storage/Local.php#287”,“level”:3,“time”:“2017-02-06T13:05:23+00:00”,“method”:"–",“url”:"–",“user”:"–",“version”:“11.0.1.2”}
{“reqId”:“fUaMoAEBe1eRSWnIAsmB”,“remoteAddr”:"",“app”:“PHP”,“message”:“stream_get_contents() expects parameter 1 to be resource, boolean given at /var/www/localhost/htdocs/nextcloud/lib/private/Preview/TXT.php#49”,“level”:3,“time”:“2017-02-06T13:05:23+00:00”,“method”:"–",“url”:"–",“user”:"–",“version”:“11.0.1.2”}

(and more lines like that)

thanks

I saw this PCNTL error already here: Nextcloud Box Problems
related with nextcloud box. Seems to occur in some systems for occ command.

According to the preview issue: As you are coming from owncloud, I would try to clean the config.php by every entry related to previews. Could you provide your config.php content and more details about your system, webserver, php etc. versions?

Also check webserver, database and php logs.

my config.php does not contain preview-related settings afaik:

(edited for secrecy:)

<?php $CONFIG = array ( 'instanceid' => 'oc...ff92b', 'passwordsalt' => '3681f40f9ef.....e695cca0', 'trusted_domains' => array ( 0 => 'oc.my.tld', ), 'datadirectory' => '/var/www/localhost/htdocs/owncloud/data', 'overwrite.cli.url' => 'http://oc.my.tld/owncloud', 'dbtype' => 'mysql', 'version' => '11.0.1.2', 'dbname' => 'owncloud', 'dbhost' => 'localhost', 'dbtableprefix' => 'oc_', 'dbuser' => 'oc_sgw', 'dbpassword' => '24a6...43f0c', 'installed' => true, 'user_backends' => array( array( 'class' => 'OC_User_IMAP', 'arguments' => array('{localhost:993/imap/ssl/novalidate-cert}INBOX') ) ), 'theme' => '', 'secret' => 'LfEcY14tT49UTDvsjJOFBk0TH6ka.fJDgjIRiAwpRt1bPjYQ', 'mail_smtpmode' => 'php', 'forcessl' => true, 'mail_from_address' => 'oc', 'mail_domain' => 'oc.my.tld', 'maintenance' => false, 'loglevel' => 2, 'trashbin_retention_obligation' => 'auto', 'htaccess.RewriteBase' => '/owncloud', ); ... I didn't change anything, just copied it from owncloud. apache 2.4.25, php 5.6.30, gentoo 64bit, uptodate mostly.

SOLVED: the files-subdir hasn’t been moved over to the new nc-directory … sorry for the noise, thanks.