Skip to content

Uploading to shared public upload-only Folder fails: Could not rename part file to final file #8942

@gnunicorn

Description

@gnunicorn

Steps to reproduce

  1. create a folder, share it via link, on upload-only
  2. open the link in a second, private browser session and try to upload any file

Expected behaviour

The file should be uploaded and made available in the directory.

Actual behaviour

The error-message "File could not be uploaded" appears.

Additional Information

It works if I put the sharing on 'upload and edit', but I don't people to be able to edit.

Server configuration detail

Operating system: Linux 4.4.0-21-generic #37-Ubuntu SMP Mon Apr 18 18:33:37 UTC 2016 x86_64

Webserver: nginx/1.13.7 (fpm-fcgi)

Database: pgsql PostgreSQL 10.3 (Debian 10.3-1.pgdg90+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 6.3.0-18+deb9u1) 6.3.0 20170516, 64-bit

PHP version: 7.1.15
Modules loaded: Core, date, libxml, openssl, pcre, sqlite3, zlib, ctype, curl, dom, fileinfo, filter, ftp, hash, iconv, json, mbstring, SPL, PDO, session, posix, readline, Reflection, standard, SimpleXML, pdo_sqlite, Phar, tokenizer, xml, xmlreader, xmlwriter, mysqlnd, cgi-fcgi, apcu, exif, gd, intl, ldap, mcrypt, memcached, mysqli, pcntl, pdo_mysql, pdo_pgsql, pgsql, redis, zip, Zend OPcache

Nextcloud version: 13.0.1 - 13.0.1.1

Updated from an older Nextcloud/ownCloud or fresh install:

Where did you install Nextcloud from: docker

Signing status

Array

List of activated apps
Enabled:
 - admin_audit: 1.3.0
 - admin_notifications: 1.0.1
 - announcementcenter: 3.2.1
 - apporder: 0.4.1
 - bruteforcesettings: 1.0.3
 - calendar: 1.6.1
 - caniupdate: 0.1.2
 - comments: 1.3.0
 - contacts: 2.1.2
 - dav: 1.4.6
 - encryption: 2.0.0
 - federatedfilesharing: 1.3.1
 - federation: 1.3.0
 - files: 1.8.0
 - files_frommail: 0.1.0
 - files_markdown: 2.0.4
 - files_pdfviewer: 1.2.0
 - files_sharing: 1.5.0
 - files_texteditor: 2.5.1
 - files_trashbin: 1.3.0
 - files_versions: 1.6.0
 - files_videoplayer: 1.2.0
 - firstrunwizard: 2.2.1
 - groupfolders: 1.2.0
 - issuetemplate: 0.3.0
 - logreader: 2.0.0
 - lookup_server_connector: 1.1.0
 - metadata: 0.6.0
 - nextcloud_announcements: 1.2.0
 - notes: 2.3.2
 - notifications: 2.1.2
 - oauth2: 1.1.0
 - onlyoffice: 1.2.0
 - ownbackup: 17.5.0
 - passman: 2.1.4
 - password_policy: 1.3.0
 - piwik: 0.3.2
 - polls: 0.8.1
 - provisioning_api: 1.3.0
 - serverinfo: 1.3.0
 - sharebymail: 1.3.0
 - survey_client: 1.1.0
 - systemtags: 1.3.0
 - theming: 1.4.1
 - twofactor_backupcodes: 1.2.3
 - updatenotification: 1.3.0
 - workflowengine: 1.3.0
Disabled:
 - activity
 - external
 - files_accesscontrol
 - files_clipboard
 - files_external
 - gallery
 - ldapcontacts
 - ldaporg
 - quota_warning
 - rainloop
 - registration
 - twofactor_totp
 - unsplash
 - user_external
 - user_ldap

Configuration (config/config.php)
{
    "memcache.local": "\\OC\\Memcache\\APCu",
    "apps_paths": [
        {
            "path": "\/var\/www\/html\/apps",
            "url": "\/apps",
            "writable": false
        },
        {
            "path": "\/var\/www\/html\/custom_apps",
            "url": "\/custom_apps",
            "writable": true
        }
    ],
    "instanceid": "***REMOVED SENSITIVE VALUE***",
    "passwordsalt": "***REMOVED SENSITIVE VALUE***",
    "secret": "***REMOVED SENSITIVE VALUE***",
    "trusted_domains": [
        "wolke.bewegung.jetzt"
    ],
    "datadirectory": "***REMOVED SENSITIVE VALUE***",
    "overwrite.cli.url": "https:\/\/wolke.bewegung.jetzt",
    "dbtype": "pgsql",
    "version": "13.0.1.1",
    "dbname": "***REMOVED SENSITIVE VALUE***",
    "dbhost": "***REMOVED SENSITIVE VALUE***",
    "dbport": "",
    "dbtableprefix": "oc_",
    "dbuser": "***REMOVED SENSITIVE VALUE***",
    "dbpassword": "***REMOVED SENSITIVE VALUE***",
    "installed": true,
    "mail_smtpmode": "smtp",
    "mail_smtpauthtype": "LOGIN",
    "mail_from_address": "***REMOVED SENSITIVE VALUE***",
    "mail_domain": "***REMOVED SENSITIVE VALUE***",
    "mail_smtphost": "***REMOVED SENSITIVE VALUE***",
    "mail_smtpport": "25",
    "mail_smtptimeout": 30,
    "ldapIgnoreNamingRules": false,
    "ldapProviderFactory": "\\OCA\\User_LDAP\\LDAPProviderFactory",
    "maintenance": false,
    "updater.release.channel": "stable",
    "mail_smtpauth": 1,
    "mail_smtpname": "***REMOVED SENSITIVE VALUE***",
    "mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
    "theme": "",
    "loglevel": 0,
    "updater.secret": "***REMOVED SENSITIVE VALUE***"
}

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

Are you using encryption: no

Client configuration

Browser: Mozilla/5.0 (X11; Linux x86_64; rv:59.0) Gecko/20100101 Firefox/59.0

Operating system: Arch Linux

Logs

Nextcloud logged Error
Insert your Nextcloud log here

Fatal | webdav | Sabre\DAV\Exception: Could not rename part file to final file/var/www/html/apps/dav/lib/Connector/Sabre/Directory.php - line 151:  OCA\DAV\Connector\Sabre\File->put(Resource id #15)/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php - line 1096:  OCA\DAV\Connector\Sabre\Directory->createFile('hand-middle.png', Resource id #15)/var/www/html/3rdparty/sabre/dav/lib/DAV/CorePlugin.php - line 525:  Sabre\DAV\Server->createFile('hand-middle.png', Resource id #15, NULL)[internal function] Sabre\DAV\CorePlugin->httpPut(Object(Sabre\HTTP\Request), Object(Sabre\HTTP\Response))/var/www/html/3rdparty/sabre/event/lib/EventEmitterTrait.php - line 105:  call_user_func_array(Array, Array)/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php - line 479:  Sabre\Event\EventEmitter->emit('method PUT', Array)/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php - line 254:  Sabre\DAV\Server->invokeMethod(Object(Sabre\HTTP\Request), Object(Sabre\HTTP\Response))/var/www/html/apps/dav/appinfo/v1/publicwebdav.php - line 107:  Sabre\DAV\Server->exec()/var/www/html/public.php - line 79:  require_once('/var/www/html/a...'){main} | 2018-03-22T12:25:17+0100
-- | -- | -- | --
Error | webdav | renaming part file to final file failed ($run: true, $renameOkay: false, $fileExists: false) | 2018-03-22T12:25:17+0100


HTTP Response The console tells me the server responds with a Internal Server Error 500: ``` Sabre\DAV\Exception Could not rename part file to final file ```

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions