server icon indicating copy to clipboard operation
server copied to clipboard

[Bug]: content of shared folder disappears randomly

Open whitehat2810 opened this issue 1 year ago • 6 comments

⚠️ This issue respects the following points: ⚠️

  • [X] This is a bug, not a question or a configuration/webserver/proxy issue.
  • [X] This issue is not already reported on Github (I've searched it).
  • [X] Nextcloud Server is up to date. See Maintenance and Release Schedule for supported versions.
  • [X] Nextcloud Server is running on 64bit capable CPU, PHP and OS.
  • [X] I agree to follow Nextcloud's Code of Conduct.

Bug description

After upgrade to NC 26.0.0 I face the follwing symptom in "Files App":

  1. Used storage is shown as 1,2MB (should be something like 10GB)
  2. opening a file from the "recently modified" section results in error message (file does not exist) - note that this file is shared with my account
  3. when I try to browse the loaction of that shared file, I klick on "shared" folder, this is empty
  4. then I reload the page several times, suddenly the "shared" folder contains the expected sub-folders
  5. also I have noticed that when browsing through the folder structure under "shared" I get kicked out to root of my files randomly

So all in all, the content of my "shared" folder seems to disappear and appear randomly.

Nextcloud log has no entries, apache log shows 404 / 207 for the same file:

1.2.3.4 - - [20/Apr/2023:14:42:49 +0200] "PROPFIND /remote.php/dav/files/user1/Shared/Uploads/MyPhone/IMG_20230419_152524.jpg HTTP/1.1" 404 986 "-" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/112.0"
1.2.3.4 - - [20/Apr/2023:14:43:04 +0200] "PROPFIND /remote.php/dav/files/user1/Shared/Uploads/MyPhone/IMG_20230419_152524.jpg HTTP/1.1" 207 1396 "-" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/112.0"

Steps to reproduce

  1. open "shared" folder

Expected behavior

Sometimes content is missing, should not be the case

Installation method

Community Docker image

Nextcloud Server version

26

Operating system

Debian/Ubuntu

PHP engine version

PHP 8.1

Web server

Apache (supported)

Database engine version

MySQL

Is this bug present after an update or on a fresh install?

Updated to a major version (ex. 22.2.3 to 23.0.1)

Are you using the Nextcloud Server Encryption module?

Encryption is Disabled

What user-backends are you using?

  • [X] Default user-backend (database)
  • [ ] LDAP/ Active Directory
  • [ ] SSO - SAML
  • [ ] Other

Configuration report

{
    "system": {
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "cloud.example.com",
            "cloud.example.com"
        ],
        "datadirectory": "***REMOVED SENSITIVE VALUE***",
        "dbtype": "mysql",
        "version": "26.0.0.11",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbtableprefix": "oc_",
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "installed": true,
        "forcessl": true,
        "mail_smtpmode": "smtp",
        "logtimezone": "Europe\/Berlin",
        "log_authfailip": true,
        "theme": "",
        "maintenance": false,
        "filelocking.enabled": true,
        "secret": "***REMOVED SENSITIVE VALUE***",
        "custom_csp_policy": "default-src 'self'; script-src 'self' 'unsafe-inline' 'unsafe-eval'; style-src 'self' 'unsafe-inline'; frame-src *; img-src *; font-src 'self' data:; media-src *",
        "loglevel": 2,
        "trashbin_retention_obligation": "auto",
        "updater.release.channel": "stable",
        "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
            }
        ],
        "overwrite.cli.url": "https:\/\/cloud.example.com",
        "overwriteprotocol": "https",
        "trusted_proxies": "***REMOVED SENSITIVE VALUE***",
        "mail_from_address": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpauthtype": "LOGIN",
        "mail_domain": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpauth": 1,
        "mail_smtpsecure": "ssl",
        "mail_smtphost": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpport": "465",
        "mail_smtpname": "***REMOVED SENSITIVE VALUE***",
        "mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
        "htaccess.RewriteBase": "\/",
        "twofactor_enforced": "false",
        "twofactor_enforced_groups": [],
        "twofactor_enforced_excluded_groups": [
            "Nutzer",
            "Consila",
            "Mobile",
            "THW",
            "admin",
            "ccp"
        ],
        "app_install_overwrite": [
            "calendar",
            "mindmaps",
            "twofactor_yubikey",
            "githubmergetracker",
            "drawio",
            "ransomware_detection",
            "user_ispconfig",
            "onlyoffice",
            "keeweb",
            "timetracker",
            "files_markdown",
            "spreed",
            "suspicious_login",
            "ransomware_protection",
            "bruteforcesettings",
            "gpxedit",
            "mood"
        ],
        "has_rebuilt_cache": true,
        "mysql.utf8mb4": true,
        "allow_local_remote_servers": true,
        "updater.secret": "***REMOVED SENSITIVE VALUE***"
    }
}

List of activated Apps

Enabled:
  - activity: 2.18.0
  - admin_audit: 1.16.0
  - bruteforcesettings: 2.6.0
  - calendar: 4.3.3
  - cloud_federation_api: 1.9.0
  - comments: 1.16.0
  - contacts: 5.2.0
  - contactsinteraction: 1.7.0
  - dashboard: 7.6.0
  - dav: 1.25.0
  - drawio: 2.1.1
  - federatedfilesharing: 1.16.0
  - files: 1.21.1
  - files_markdown: 2.3.6
  - files_pdfviewer: 2.7.0
  - files_rightclick: 1.5.0
  - files_sharing: 1.18.0
  - files_trashbin: 1.16.0
  - files_versions: 1.19.1
  - impersonate: 1.13.0
  - integration_openai: 1.0.4
  - keeweb: 0.6.12
  - logreader: 2.11.0
  - lookup_server_connector: 1.14.0
  - mail: 3.1.1
  - maps: 1.0.2
  - nextcloud_announcements: 1.15.0
  - notes: 4.7.2
  - notifications: 2.14.0
  - oauth2: 1.14.0
  - onlyoffice: 7.8.0
  - password_policy: 1.16.0
  - phonetrack: 0.7.4
  - photos: 2.2.0
  - privacy: 1.10.0
  - provisioning_api: 1.16.0
  - quota_warning: 1.16.0
  - recommendations: 1.5.0
  - serverinfo: 1.16.0
  - settings: 1.8.0
  - sharebymail: 1.16.0
  - spreed: 16.0.3
  - support: 1.9.0
  - survey_client: 1.14.0
  - tasks: 0.14.5
  - text: 3.7.2
  - theming: 2.1.1
  - twofactor_admin: 4.1.9
  - twofactor_backupcodes: 1.15.0
  - twofactor_totp: 8.0.0-alpha.0
  - unsplash: 2.2.0
  - updatenotification: 1.16.0
  - user_status: 1.6.0
  - viewer: 1.10.0
  - weather_status: 1.6.0
  - workflowengine: 2.8.0
Disabled:
  - circles: 26.0.0 (installed 26.0.0)
  - diary: 0.0.9 (installed 0.0.9)
  - encryption: 2.14.0
  - federation: 1.16.0 (installed 1.16.0)
  - files_external: 1.18.0 (installed 1.9.0)
  - firstrunwizard: 2.15.0 (installed 1.0)
  - gpxedit: 0.0.14 (installed 0.0.14)
  - gpxmotion: 0.1.0 (installed 0.1.0)
  - gpxpod: 5.0.10 (installed 5.0.10)
  - integration_whiteboard: 0.0.14 (installed 0.0.14)
  - ransomware_protection: 1.14.0 (installed 1.14.0)
  - related_resources: 1.1.0-alpha1 (installed 1.1.0-alpha1)
  - shifts: 1.8.6 (installed 1.8.6)
  - suspicious_login: 4.4.0 (installed 4.2.1)
  - systemtags: 1.16.0 (installed 1.16.0)
  - twofactor_u2f: 6.3.1 (installed 6.3.1)
  - twofactor_yubikey: 0.4.1 (installed 0.4.1)
  - user_ldap: 1.16.0

Nextcloud Signing status

No errors have been found.

Nextcloud Logs

no log output at all when issue happens

Additional info

No response

whitehat2810 avatar Apr 20 '23 13:04 whitehat2810

This happens to me with one particular user and not with the others. I'm using Hansson IT VM. I've installed it some time ago, about version 24, and been upgrading it since then up to 26.0.1.

In my case, I'm trying to grant access to a user for a Temp folder (an SMB share). Other two users already have access to it and can access it without problem. But recently I wanted to give Temp access to a new user and when I login with the that user and thy to access the Temp folder, the Firefox console shows:

XHRPROPFIND https://cloud.mysite.com/remote.php/dav/files/casa/temp [HTTP/2 404 Not Found 46ms]

I tried three different ways to grant access and the results were the same: 1-Grant access to the already created SMB share 2-Create a new SMB share for the new user 3-Share the folder from another user with access

None of the 3 methods worked. The symptoms are the same described by @whitehat2810 in points 2 and 5.

muchachagrande avatar Apr 24 '23 14:04 muchachagrande

TL;DR: I am seeing the same symptoms on my self-hosted Nextcloud v26.0.1 instance

I started noticing the same issue this week. A user shared a folder with me and I kept randomly getting "File no longer exists" error when accessing files at random. Even reloading the page listing the contents of the shared folder would sometimes redirect back to the home folder. I saw the same thing happen on the android app.

I just now tried accessing a shared folder that I have had access to for over a year with no problem and now I am seeing the same behavior.

Galbar avatar Apr 29 '23 10:04 Galbar

In my case I don't have problems with folders to which I had access before. The access problems are only on new shares and new external folders.

muchachagrande avatar Apr 29 '23 21:04 muchachagrande

i have the same problem. Before 26 the folder worked for all users. Now one user has the same problem with multiple shared files & folders. Same client with a different Server(also Version 26) worked without problems.

LeopoldVInfinite avatar May 03 '23 16:05 LeopoldVInfinite

I also have the same issue with NC 26.01 - but I think I do not have any external folders. Someone knows how I might check if I have some external folders in my space I forgot about?

steglicd avatar May 10 '23 03:05 steglicd

@whitehat2810 What is the underlying shared folder? And for the party that shared it with you, but is it? A local file? An External Storage mount? Etc.

If you're seeing 404 in your web server, the corresponding entry for the transaction in your Nextcloud logs may not show up unless you temporarily change your loglevel.

joshtrichards avatar Jun 16 '23 00:06 joshtrichards