core icon indicating copy to clipboard operation
core copied to clipboard

libreoffice preview for smb mounted files does not work

Open tastle73 opened this issue 12 years ago • 6 comments

Steps to reproduce

  1. oo or lo file exists on smb mount
  2. libreoffice preview installed and configed
  3. click on the item

Expected behaviour

a preview of the doc should appear

Actual behaviour

Tell us what happens instead get the message : Loading /owncloud/index.php/apps/documents/ajax/download.php?path=/sysadmin/inventory/switches.ods...

in the document frame but the preview never appears

Server configuration

Operating system: ubuntu 12.10

Web server: apache2 Database: mysql PHP version: 5.3.10 ownCloud version: (see ownCloud admin page) 6.0.2 Updated from an older ownCloud or fresh install: updated List of activated apps: Activity, contacts, deleted files, documents, external storage support, first run wizard, full text search, LDAP backend, owncloud dependencies info, pdf viewer, pictures, share files, text editor updater, versions, video viewer The content of config/config.php:

$CONFIG = array (
  'instanceid' => 'oc24e5689b8d',
  'passwordsalt' => '',
  'datadirectory' => '/var/www/owncloud/data',
  'dbtype' => 'mysql',
  'version' => '6.0.2.2',
  'dbname' => 'owncloud',
  'dbhost' => 'localhost',
  'dbtableprefix' => 'oc_',
  'dbuser' => 'owncloud',
  'dbpassword' => '',
  'installed' => true,
  'ldapIgnoreNamingRules' => false,
  'loglevel' => '0',
  'forcessl' => false,
  'theme' => '',
  'maintenance' => false,
'enable_previews' => true,
'preview_max_x' => null,
'preview_max_y' => null,
'preview_max_scale_factor' => 10,
'preview_libreoffice_path' => '/usr/bin/libreoffice',
'mail_domain' => 'pcc.com',
'mail_smtpdebug' => true,
'mail_smtpmode' => 'smtp',
'mail_smtphost' => 'zimbra.pcc.com',
'mail_smtpport' => 25,
'mail_smtpsecure' => '',
);

Are you using external storage, if yes which one: local/smb/sftp/... smb Are you using encryption: yes/no no

Client configuration

Browser: firefox Operating system: windows 7, macos 10.9

Logs

Web server error log

Insert your webserver log here

no errors in error.log

ownCloud log (data/owncloud.log)

{"app":"OC\\Files\\Cache\\Scanner","message":"!!! No reuse of etag for '' !!! \ncache: Array\n(\n    [fileid] => 351
\n    [storage] => smb::tom@zurg\/\/sysadmin\/\/\n    [path] => \n    [parent] => -1\n    [name] => \n    [mimetype]
 => httpd\/unix-directory\n    [mimepart] => httpd\n    [size] => 45135547\n    [mtime] => 1396472809\n    [storage_
mtime] => 1396472809\n    [encrypted] => \n    [unencrypted_size] => 0\n    [etag] => 533d40e250857\n)\n \ndata: Arr
ay\n(\n    [mimetype] => httpd\/unix-directory\n    [mtime] => 1396875792\n    [size] => -1\n    [etag] => 5342afce2
bac3\n    [storage_mtime] => 1396875792\n)\n","level":0,"time":"2014-04-07T14:01:50+00:00"}
{"app":"OC\\Files\\Cache\\Scanner","message":"!!! No reuse of etag for 'inventory' !!! \ncache: Array\n(\n    [filei
d] => 357\n    [storage] => smb::tom@zurg\/\/sysadmin\/\/\n    [path] => inventory\n    [parent] => 351\n    [name]
=> inventory\n    [mimetype] => httpd\/unix-directory\n    [mimepart] => httpd\n    [size] => 185852\n    [mtime] =>
 1396385436\n    [storage_mtime] => 1396385436\n    [encrypted] => \n    [unencrypted_size] => 0\n    [etag] => 533c
21d9eed35\n)\n \ndata: Array\n(\n    [mimetype] => httpd\/unix-directory\n    [mtime] => 1396547648\n    [size] => -
1\n    [etag] => 5342afce2ee8f\n    [storage_mtime] => 1396547648\n)\n","level":0,"time":"2014-04-07T14:01:50+00:00"
}
{"app":"OC\\Files\\Cache\\Scanner","message":"!!! No reuse of etag for 'passwords' !!! \ncache: Array\n(\n    [filei
d] => 371\n    [storage] => smb::tom@zurg\/\/sysadmin\/\/\n    [path] => passwords\n    [parent] => 351\n    [name]
=> passwords\n    [mimetype] => httpd\/unix-directory\n    [mimepart] => httpd\n    [size] => 57051\n    [mtime] =>
1396472809\n    [storage_mtime] => 1396472809\n    [encrypted] => \n    [unencrypted_size] => 0\n    [etag] => 533d4
0e257b08\n)\n \ndata: Array\n(\n    [mimetype] => httpd\/unix-directory\n    [mtime] => 1396875792\n    [size] => -1
\n    [etag] => 5342afce32fde\n    [storage_mtime] => 1396875792\n)\n","level":0,"time":"2014-04-07T14:01:50+00:00"}
{"app":"PHP","message":"json_encode(): Invalid UTF-8 sequence in argument at \/var\/www\/owncloud\/lib\/private\/log
\/owncloud.php#73","level":3,"time":"2014-04-07T14:01:51+00:00"}
{"app":"core","message":null,"level":0,"time":"2014-04-07T14:01:51+00:00"}
{"app":"core","message":"OC_Image->loadFromBase64, couldn't load","level":0,"time":"2014-04-07T14:01:51+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() No readable file path set.","level":0,"time":"2014-04-07T14:01:5
1+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() Orientation: -1","level":0,"time":"2014-04-07T14:01:51+00:00"}
{"app":"PHP","message":"json_encode(): Invalid UTF-8 sequence in argument at \/var\/www\/owncloud\/lib\/private\/log
\/owncloud.php#73","level":3,"time":"2014-04-07T14:01:51+00:00"}
{"app":"core","message":null,"level":0,"time":"2014-04-07T14:01:51+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() No readable file path set.","level":0,"time":"2014-04-07T14:01:5
1+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() Orientation: -1","level":0,"time":"2014-04-07T14:01:56+00:00"}
{"app":"PHP","message":"json_encode(): Invalid UTF-8 sequence in argument at \/var\/www\/owncloud\/lib\/private\/log\/owncloud.php#73","level":3,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":null,"level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() No readable file path set.","level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() Orientation: -1","level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"PHP","message":"json_encode(): Invalid UTF-8 sequence in argument at \/var\/www\/owncloud\/lib\/private\/log\/owncloud.php#73","level":3,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":null,"level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() No readable file path set.","level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() Orientation: -1","level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"PHP","message":"json_encode(): Invalid UTF-8 sequence in argument at \/var\/www\/owncloud\/lib\/private\/log\/owncloud.php#73","level":3,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":null,"level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() No readable file path set.","level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() Orientation: -1","level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"PHP","message":"json_encode(): Invalid UTF-8 sequence in argument at \/var\/www\/owncloud\/lib\/private\/log\/owncloud.php#73","level":3,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":null,"level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":"OC_Image->loadFromBase64, couldn't load","level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() No readable file path set.","level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() Orientation: -1","level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"PHP","message":"json_encode(): Invalid UTF-8 sequence in argument at \/var\/www\/owncloud\/lib\/private\/log\/owncloud.php#73","level":3,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":null,"level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() No readable file path set.","level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() Orientation: -1","level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"PHP","message":"json_encode(): Invalid UTF-8 sequence in argument at \/var\/www\/owncloud\/lib\/private\/log\/owncloud.php#73","level":3,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":null,"level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() No readable file path set.","level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() Orientation: -1","level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"PHP","message":"json_encode(): Invalid UTF-8 sequence in argument at \/var\/www\/owncloud\/lib\/private\/log\/owncloud.php#73","level":3,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":null,"level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() No readable file path set.","level":0,"time":"2014-04-07T14:01:57+00:00"}
{"app":"core","message":"OC_Image->fixOrientation() Orientation: -1","level":0,"time":"2014-04-07T14:01:57+00:00"}

Browser log

Insert your browser log here, this could for example include:

a) The javascript console log
b) The network log 
c) ...

tastle73 avatar Apr 07 '14 14:04 tastle73

@georgehrke can you have a look ? I believe that the preview code calls getLocalFile() which would download the file to a temp dir and then run the preview generator.

@tastle73 do photo previews work on your SMB mount ?

PVince81 avatar Apr 08 '14 08:04 PVince81

@tastle73 Does ownCloud generate previews for libreOffice files not stored on any file mount?

georgehrke avatar Apr 08 '14 09:04 georgehrke

sorry, I left that out. yes, it does work on local files.

tastle73 avatar Apr 08 '14 12:04 tastle73

@georgehrke any idea?

karlitschek avatar Dec 05 '14 20:12 karlitschek

@georgehrke any idea?

No, was never able to reproduce this.

georgehrke avatar Dec 07 '14 22:12 georgehrke

We dropped support for the libreoffice preview backend -> closing

georgehrke avatar Dec 07 '14 22:12 georgehrke