External storage > local NFS drive > Folder size not accurate

Steps to reproduce

  1. Add external storage, select local type, use a NFS mounted storage drive as the oc-data location.
  2. Add files to OwnCloud on that external storage just created.
  3. Check folder size reported in OwnCloud and compare against the original folder size. If the numbers don’t match, that is the issue here.

Expected behaviour

Folder size reported on owncloud should match the actual folder size.

Actual behaviour

Folder size reported on owncloud tends to be 10-20% smaller than the actual size.

Server configuration

Operating system:

Ubuntu 14.04

Web server:

Apache

Database:

MySQL

PHP version:

PHP 7.0.21-1~ubuntu14.04.1+deb.sury.org+1 (cli) (built: Jul 6 2017 09:38:10) ( NTS )

ownCloud version: (see ownCloud admin page)

10.0.4.4

Updated from an older ownCloud or fresh install:

I perform regular upgrades.
The original install was 9.x.

Where did you install ownCloud from:

I forget.

Signing status (ownCloud 9.0 and above):

The content of config/config.php:

{
    "system": {
        "instanceid": "oc00zt3t7bwy",
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "owncloud.xxx.xxx",
            "owncloud.xxx.xxx"
        ],
        "datadirectory": "\/cache\/data",
        "overwrite.cli.url": "https:\/\/owncloud.xxx.xxx",
        "htaccess.RewriteBase": "\/",
        "dbtype": "mysql",
        "version": "10.0.4.4",
        "dbname": "owncloud",
        "dbhost": "localhost",
        "dbtableprefix": "oc_",
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "logtimezone": "UTC",
        "installed": true,
        "loglevel": 0,
        "ldapIgnoreNamingRules": false,
        "files_external_allow_create_new_local": "true",
        "memcache.local": "\\OC\\Memcache\\APCu",
        "memcache.locking": "\\OC\\Memcache\\Redis",
        "redis": {
            "host": "localhost",
            "port": 6379
        },
        "appstore.experimental.enabled": true,
        "enable_previews": "true",
        "preview_libreoffice_path": "\/usr\/bin\/libreoffice",
        "quota_include_external_storage": false,
        "maintenance": false,
        "appcodechecker": false,
        "trashbin_retention_obligation": "1,1",
        "enabledPreviewProviders": [
            "OC\\Preview\\PNG",
            "OC\\Preview\\JPEG",
            "OC\\Preview\\GIF",
            "OC\\Preview\\BMP",
            "OC\\Preview\\XBitmap",
            "OC\\Preview\\MP3",
            "OC\\Preview\\TXT",
            "OC\\Preview\\DCM",
            "OC\\Preview\\MarkDown",
            "OC\\Preview\\Illustrator",
            "OC\\Preview\\Postscript",
            "OC\\Preview\\Photoshop",
            "OC\\Preview\\TIFF"
        ],
        "mail_smtpmode": "smtp",
        "mail_smtphost": "smtp.sendgrid.net",
        "mail_smtpauth": 1,
        "mail_smtpauthtype": "LOGIN",
        "mail_from_address": "ted.strauss",
        "mail_domain": "mcgill.ca",
        "mail_smtpport": "465",
        "mail_smtpsecure": "ssl",
        "mail_smtpname": "***REMOVED SENSITIVE VALUE***",
        "mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
        "integrity.excluded.files": [
            "core\/css\/header.css",
            "core\/img\/favicon.ico",
            "core\/img\/background.jpg",
            "core\/img\/logo.svg",
            "core\/img\/logo-icon.svg",
            "core\/img\/favicon.svg",
            "updater\/vendor\/autoload.php",
            "updater\/vendor\/composer\/autoload_real.php",
            "updater\/vendor\/composer\/autoload_static.php"
        ],
        "debug": true,
        "theme": ""
    }
}

List of activated apps:

Enabled:
  - activity: 2.4.1
  - audioplayer: 2.5.0
  - checksum: 0.3.5
  - comments: 0.3.0
  - configreport: 0.1.1
  - customgroups: 0.4.0
  - dav: 0.3.2
  - diagnostics: 0.1.4
  - external: true
  - federatedfilesharing: 0.3.1
  - federation: 0.1.0
  - files: 1.5.1
  - files_clipboard: 0.7.1
  - files_external: 0.7.1
  - files_external_ftp: 0.2.0
  - files_pdfviewer: 0.10.0
  - files_sharing: 0.10.1
  - files_texteditor: 2.3.0
  - files_trashbin: 0.9.1
  - files_versions: 1.3.0
  - files_videoplayer: 0.9.8
  - gallery: 16.1.1
  - impersonate: 0.4.0
  - market: 0.2.5
  - notifications: 0.3.2
  - systemtags: 0.3.0
  - templateeditor: 0.3
  - user_ldap: 0.10.0
Disabled:
  - encryption
  - firstrunwizard
  - provisioning_api
  - theme-example
  - updatenotification
  - user_external

Are you using external storage, if yes which one: local/smb/sftp/…

yes, Local.

Are you using encryption: yes/no

No

Are you using an external user-backend, if yes which one:

yes, LDAP

LDAP configuration (delete this part if not used)

Private

Client configuration

Browser:

Multiple

Operating system:

Multiple

Logs

Web server error log

Insert your webserver log here

ownCloud log (data/owncloud.log)

Insert your ownCloud log here

Browser log

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

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

Double-check the size in the NFS storage, in the server and the one shown by ownCloud.
As far as I know, ownCloud doesn’t manipulate the size outside of the usual unit conversion. If the server tells ownCloud that the file has 1 million bytes, ownCloud will show 1 million bytes. It might not be accurate due to rounding when the bytes are converted to kilobytes, megabytes or whatever.

1 Like