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

Improper lock usage leads to inode overflow in LockLocalStorage implementation #1975

Open
somnoynadno opened this issue Dec 3, 2023 · 0 comments

Comments

@somnoynadno
Copy link

Summary

Behaviour of fasteners.InterProcessLock is pretty weird: class creates a lockfile by provided path, if it doesn't exist, but not manage to remove it after lock is released.

It may lead to uncontrolled lockfiles spam in /tmp folder just because libcloud local driver is not removing this lockfile either.

Detailed Information

This issue encountered in cassandra-medusa v0.15 and lower, which was using apache-libcloud<3.4.0,>=3.3.0 as a dependency.

Please see thelastpickle/cassandra-medusa#528 for more details.


Seems like the lightweight fix is to run

                with contextlib.suppress(FileNotFoundError):
                    os.remove(filename)

just right in the exit method.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant