You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While trying to delete a folder without permissions to delete the content of the folder fs.rm takes huge amounts of RAM with potential OOM-Exceptions down the road.
Steps to reproduce:
Create a complex folder tree (see following script as an example)
Ensure user that executes fs.rm has permission to delete rootfolder but does not have permissions to delete content of the rootfolder.
Execute Deletion Script
The testscript did not result in an OOM-exception for me (it stopped at ~8gb RAM usage). You can just create more files to run into an OOM eventually (it broke in production with an OOM for us).
How often does it reproduce? Is there a required condition?
As long as enough files/folders are in the to be deleted folder and corresponding permission issues exists the bug reproduces.
What is the expected behavior? Why is that the expected behavior?
Trying to delete a folder should not result in an OOM. Here: it should fail because of permission issues.
What do you see instead?
Huge memory consumption until OOM eventually (with enough content in the folder)
Additional information
No response
The text was updated successfully, but these errors were encountered:
aduh95
changed the title
fs.rm recursive on a huge directory-tree with missing permissions can result in OOMfs.promises.rm recursive on a huge directory-tree with missing permissions can result in OOM
Jan 2, 2025
Version
22.11.0
Platform
Subsystem
FS
What steps will reproduce the bug?
While trying to delete a folder without permissions to delete the content of the folder fs.rm takes huge amounts of RAM with potential OOM-Exceptions down the road.
Steps to reproduce:
The testscript did not result in an OOM-exception for me (it stopped at ~8gb RAM usage). You can just create more files to run into an OOM eventually (it broke in production with an OOM for us).
Create data folder:
Executing Deletion:
How often does it reproduce? Is there a required condition?
As long as enough files/folders are in the to be deleted folder and corresponding permission issues exists the bug reproduces.
What is the expected behavior? Why is that the expected behavior?
Trying to delete a folder should not result in an OOM. Here: it should fail because of permission issues.
What do you see instead?
Huge memory consumption until OOM eventually (with enough content in the folder)
Additional information
No response
The text was updated successfully, but these errors were encountered: