Summary: | portage does not merge package symlinks atomically (util.movefile claims to be atomic but is not) | ||
---|---|---|---|
Product: | Portage Development | Reporter: | SpanKY <vapier> |
Component: | Core | Assignee: | Portage team <dev-portage> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | gentoo, sam |
Priority: | Normal | Keywords: | InVCS |
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | 837899 | ||
Bug Blocks: | 563614, 835380 |
Description
SpanKY
2022-03-30 07:21:14 UTC
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/proj/portage.git/commit/?id=fa82725ba03ffa5edf0b82db7307c87fc97e83f2 commit fa82725ba03ffa5edf0b82db7307c87fc97e83f2 Author: Mike Frysinger <vapier@chromium.org> AuthorDate: 2022-03-30 06:32:07 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2022-04-15 02:46:19 +0000 movefile: merge symlinks atomically Since POSIX allows renaming symlinks with symlinks, use that to get atomic updates. This is faster and less flaky to parallel processes: removing a live symlink and then recreating it leaves a small window where other things might try to use it but fail. [sam: cherry-picked from chromiumos' third_party/portage_tool repo] (cherry picked from commit cherry-pick 80ed2dac95db81acac8043e6685d0a853a08d268) Bug: https://bugs.gentoo.org/836400 Signed-off-by: Sam James <sam@gentoo.org> Closes: https://github.com/gentoo/portage/pull/816 Signed-off-by: Sam James <sam@gentoo.org> lib/portage/util/movefile.py | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) |