Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Files vanish #41922

Closed
4 of 8 tasks
Tracked by #3888
ChristophWurst opened this issue Nov 30, 2023 · 11 comments
Closed
4 of 8 tasks
Tracked by #3888

[Bug]: Files vanish #41922

ChristophWurst opened this issue Nov 30, 2023 · 11 comments
Assignees
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap 28-feedback bug high regression ❄️ 2023-Winter

Comments

@ChristophWurst
Copy link
Member

ChristophWurst commented Nov 30, 2023

⚠️ This issue respects the following points: ⚠️

Bug description

For the last few weeks I've had files vanish from my test users' home storage. I took it for a testing side effect but @kesselb and @miaulalala reported the same. This also happens on our demo instance.

Steps to reproduce

  1. Have files
  2. ???

Expected behavior

I still have my files

Installation method

None

Nextcloud Server version

29

Operating system

None

PHP engine version

None

Web server

None

Database engine version

None

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

None

Are you using the Nextcloud Server Encryption module?

None

What user-backends are you using?

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

Configuration report

No response

List of activated Apps

No response

Nextcloud Signing status

No response

Nextcloud Logs

No response

Additional info

No response

@ChristophWurst ChristophWurst added bug high 0. Needs triage Pending check for reproducibility or if it fits our roadmap regression 28-feedback labels Nov 30, 2023
@ChristophWurst
Copy link
Member Author

Possibly related: I can not upload to the root directory of users with vanished files. I get

{
  "reqId": "mowY6PTqVU0WI3ZYxYLB",
  "level": 0,
  "time": "2023-11-29T16:41:42+00:00",
  "remoteAddr": "127.0.0.1",
  "user": "admin",
  "app": "webdav",
  "method": "PUT",
  "url": "/remote.php/dav/files/admin/Nextcloud_Log.txt",
  "message": "Exception thrown: Sabre\\DAV\\Exception\\Forbidden",
  "userAgent": "Mozilla/5.0 (X11; Linux x86_64; rv:120.0) Gecko/20100101 Firefox/120.0",
  "version": "29.0.0.2",
  "exception": {
    "Exception": "Sabre\\DAV\\Exception\\Forbidden",
    "Message": "",
    "Code": 0,
    "Trace": [
      {
        "file": "/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php",
        "line": 1098,
        "function": "createFile",
        "class": "OCA\\DAV\\Connector\\Sabre\\Directory",
        "type": "->",
        "args": [
          "*** sensitive parameters replaced ***"
        ]
      },
      {
        "file": "/nextcloud/3rdparty/sabre/dav/lib/DAV/CorePlugin.php",
        "line": 504,
        "function": "createFile",
        "class": "Sabre\\DAV\\Server",
        "type": "->",
        "args": [
          "*** sensitive parameters replaced ***"
        ]
      },
      {
        "file": "/nextcloud/3rdparty/sabre/event/lib/WildcardEmitterTrait.php",
        "line": 89,
        "function": "httpPut",
        "class": "Sabre\\DAV\\CorePlugin",
        "type": "->",
        "args": [
          [
            "Sabre\\HTTP\\Request"
          ],
          [
            "Sabre\\HTTP\\Response"
          ]
        ]
      },
      {
        "file": "/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php",
        "line": 472,
        "function": "emit",
        "class": "Sabre\\DAV\\Server",
        "type": "->",
        "args": [
          "method:PUT",
          [
            [
              "Sabre\\HTTP\\Request"
            ],
            [
              "Sabre\\HTTP\\Response"
            ]
          ]
        ]
      },
      {
        "file": "/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php",
        "line": 253,
        "function": "invokeMethod",
        "class": "Sabre\\DAV\\Server",
        "type": "->",
        "args": [
          [
            "Sabre\\HTTP\\Request"
          ],
          [
            "Sabre\\HTTP\\Response"
          ]
        ]
      },
      {
        "file": "/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php",
        "line": 321,
        "function": "start",
        "class": "Sabre\\DAV\\Server",
        "type": "->",
        "args": []
      },
      {
        "file": "/nextcloud/apps/dav/lib/Server.php",
        "line": 370,
        "function": "exec",
        "class": "Sabre\\DAV\\Server",
        "type": "->",
        "args": []
      },
      {
        "file": "/nextcloud/apps/dav/appinfo/v2/remote.php",
        "line": 35,
        "function": "exec",
        "class": "OCA\\DAV\\Server",
        "type": "->",
        "args": []
      },
      {
        "file": "/nextcloud/remote.php",
        "line": 172,
        "args": [
          "/nextcloud/apps/dav/appinfo/v2/remote.php"
        ],
        "function": "require_once"
      }
    ],
    "File": "/nextcloud/apps/dav/lib/Connector/Sabre/Directory.php",
    "Line": 127,
    "message": "",
    "exception": {},
    "CustomMessage": "Exception thrown: Sabre\\DAV\\Exception\\Forbidden"
  }
}

@szaimen
Copy link
Contributor

szaimen commented Nov 30, 2023

cc @nextcloud/server

@ChristophWurst
Copy link
Member Author

Apparently there is an issue with usernames that have spaces. Then the webdav lib breaks.

For my local user admin that shouldn't be the case.

@szaimen
Copy link
Contributor

szaimen commented Nov 30, 2023

I think this shiuld have been fixed with #41782, no?

@ChristophWurst
Copy link
Member Author

For my local user admin that shouldn't be the case.

yeah

@AndyScherzinger
Copy link
Member

@ChristophWurst - so still happening for you?

@AndyScherzinger AndyScherzinger moved this to 📄 To do (~10 entries) in 📁 Files team Dec 5, 2023
@AndyScherzinger AndyScherzinger added this to the Nextcloud 28 milestone Dec 5, 2023
@ChristophWurst
Copy link
Member Author

I haven't worked with files in the last few days so I can't say tbh

@nullspoon
Copy link
Contributor

nullspoon commented Dec 8, 2023

I just upgraded my instance to RC3 and started experiencing this issue with one of my users. Its username has no space, but another username with no spaces works fine.

Some more details on the behavior, I get a code 500 on PROPFIND for /remote.php/dav/files/username/. I did notice that if I click on favorites on the left side and one of my subdirectories there (Notes), everything loads fine. I can also navigate around subdirectories from the Dashboard recently updated files as well. It's just the root level directory (All Files) for the user that fails.

Checking the nextcloud logs, I notice the last line of the json has this:

"File":"...pathstuff/apps/encryption/lib/Crypto/Encryption.php","Line":352,"Hint":"Cannot decrypt this file, probably this is a shared file. Please ask the file owner to reshare the file with you.","message":"Cannot decrypt this file, probably this is a shared file. Please ask the file owner to reshare the file with you.","exception":{},"CustomMessage":"Cannot decrypt this file, probably this is a shared file. Please ask the file owner to reshare the file with you."}}

I've seen the above error a bunch of times in the past with text and video files and resolved it by re-upoading all the files for the given user (ugh). One peculiar thing above the above error though is that the path listed earlier in the message is the user's home directory, not a file. Might be unrelated to the bug reported here since I have encryption turned on.

On a hunch that this may be related to a missing README.md file at the top of my user's home dir, in File settings I unchecked Show folder description, refreshed, and all of my files at root loaded. I re-checked show folder description, reloaded, and my files at root disappeared again. With that unchecked and the page loading fine again, the PROPFIND request now returns a 207 and the above error message no longer shows up in my logs.

I'll try to dig deeper later tonight or tomorrow if I have time.

@miaulalala
Copy link
Contributor

Could this also be down to sabre-io/dav#1060 ?

@sorbaugh
Copy link
Contributor

Since this bug sounds reall nasty but also really hard to reproduce, obligatory "are you still experiencing this" question.

Any further infos you can share to zero in on the prpblem?

@ChristophWurst
Copy link
Member Author

It hasn't happened on my dev env recently. We can close this.

@sorbaugh sorbaugh moved this from 📄 To do (~10 entries) to ☑️ Done in 📁 Files team Jan 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap 28-feedback bug high regression ❄️ 2023-Winter
Projects
Archived in project
Development

No branches or pull requests

7 participants