-
-
Notifications
You must be signed in to change notification settings - Fork 346
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
Updating repositories fails on Linux if /tmp/CdFileMgr is non-writable #1685
Comments
Seems like a simple solution. I can't think of a reason it would fail. Only issue is that I can't find a string "CdFileMgr" anywhere in the CKAN code, so maybe that's in Mono system code. |
The temp file name appears to come from the Source of the file is here |
This comment was marked as outdated.
This comment was marked as outdated.
Probably should re-open, no indication it's been fixed? |
This is likely an intended feature of the file transaction library. There are many forks of it, but the second link here is the package we are referencing when building CKAN: I think this is an upstream issue, and this library isn't being actively maintained that I can tell. |
Is there something we could do to release the temp working directory so it gets deleted? |
Sure, we could do something like that, but devil's advocate - we are now writing code into CKAN that makes "ChinDo.Transactions" a hardcoded dependency because the "CdFileMgr" name comes straight from their source and is a unique issue when combining an old lib with an edge case in Mono. As of right now I don't like this lib just because it doesn't seem designed with Linux/Mono in mind despite it seeming like the primary platform for this app. Since it hasn't been updated since 2013 why would it have though... so my opinion is moving to a newer version of this library like this one would resolve the issue without any other changes required. I can get into this further in a few days based on team thoughts. |
That rsevil fork looks like it was all set up for replacing the copy on Nuget, but has clearly never been accepted by the upstream project, and hasn't had any updates since that short flurry of mostly refactoring and doco changes in Dec 2014. It does indeed appear to be an abandoned project. I suppose our options come down to
I'd want a pretty serious code review of the rsevil or other fork if we take that route. Taking our own fork of the codebase would let us prevent future malicious changes, but mean we have to handle the complexities. My quick Google search finds absolutely no alternates for the latter option. |
The original project shows recent signs of life (8 commits in the past 2 weeks), and no longer seems to contain the string "CdFileMgr": Might be worth updating our nuget dependency from ChinhDo.Transactions.FileManager to TxFileManager. |
Hmm, dead end?
1.3.0 looks OK though... except it still creates |
As of #4102, temp files are no longer used for repo updates. |
CKAN Version
1.16.1-0-g2e91715
(current master) or1.16.1
(tried both) - building and running withmono
.Operating System
Arch Linux 64-bit (although expect to happen on all GNU/Linux variants).
The issue
A previous run of CKAN by a different user left the temporary directory, and the permissions on it disallow another user from writing
master.tar.gz
.How to recreate this issue
user1
and exit.user2
.Workarounds
Either of:
user2
.Proposed fix
The text was updated successfully, but these errors were encountered: