According to ianlancetaylor in the golang issue thread, that will reduce but not eliminate the probability of corruption.
Asynchronous preemption was introduced in Go 1.14, and that does the right dance to trigger the kernel issue. Golang mitigation for the kernel issue in the form of mlock
ing the signal stack was introduced in Go 1.14. Due to issues with it, it was disabled for Ubuntu 5.4 in Go 1.15 and removed entirely for Go 1.16.
Because I experienced the corruption on 1.15, not on Ubuntu, I can think of a few things:
- The mitigation incorrectly detected my OS or kernel version and was not enabled
- The mitigation is broken/ineffective on my system
- The mitigation did not cover all cases, perhaps something specific to
restic
- This is not the bug we are looking for
For others that could be experiencing this issue, “This bug was introduced in Linux 5.2 and fixed in 5.3.15, 5.4.2 and all 5.5 and later kernels. The fix was also back-ported by major distros.” - Ref
After some pain I upgraded to kernel 5.4.80-2-lts and am running tests. Thus far things look good, but it’s too early to call it.