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

elevate privileges when calling clonepath #41

Closed
trapexit opened this issue Jan 28, 2015 · 0 comments
Closed

elevate privileges when calling clonepath #41

trapexit opened this issue Jan 28, 2015 · 0 comments
Labels

Comments

@trapexit
Copy link
Owner

The setting of euid and egid happens before any business logic to make sure all system calls run within the context of the caller (if mergerfs is running as root). When calling clonepath however we need to elevate those privileges back to root so we can properly create the destination path.

If it's not running as root then certain calls may fail depending on the permissions of the directories. Not much can be done there. One partial solution is to attempt to clone the path to another mount when an error occurs. The chance of inconsistency however still exists.

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

No branches or pull requests

1 participant