Unix atomic actions, or how to replace an executable or library
Unix atomic actions, or how to replace an executable or library
Posted Aug 26, 2021 16:05 UTC (Thu) by davecb (subscriber, #1574)In reply to: Unix atomic actions, or how to replace an executable or library by davecb
Parent article: The shrinking role of ETXTBSY
If so, that suggests that Linux could have the same "you're about to mess up one of your processes" warning if someone inadvertently attempted to use cp or rsync to update an in-use library, just like an in-use program.
Posted Sep 12, 2021 18:51 UTC (Sun)
by nix (subscriber, #2304)
[Link]
No. I'm fairly sure there is no way to do so: there was, but that was MAP_DENYWRITE, which, well, see this article... glibc is still careful to mmap its libraries with MAP_DENYWRITE, which the kernel then ignores :(
Unix atomic actions, or how to replace an executable or library
