1

The overlayfs documentation states that "if the underlying filesystem is changed, the behavior of the overlay is undefined, though it will not result in a crash or deadlock."

And, indeed, I've observed that when I make changes to the lowerdir in an overlay mount, strange stuff happens. However, if I remount afterwards, the problems seem to be fixed.

If I ignore the documentation's advice and modify the underlying filesystem online, will mount -oremount merged necessarily fix any issues caused by doing so?

(Yes, yes, I know the documentation says "changes to the underlying filesystems while part of a mounted overlay filesystem are not allowed" (emphasis mine), but I've heard otherwise.)

RobertR
  • 127
  • 1
    Just a word of caution with regard to "undefined behaviour": even if you find the actual behaviour works for you, this is still dangerous. Undefined behaviour can change between minor versions of a module with zero warning. Even without a code change it can work 999 times and fail catastrophically on the thousandth. – Philip Couling Jul 27 '20 at 23:02
  • Yes, this is why I asked. If it weren't for having heard remounting will fix any inconsistencies, I would have just listened to the documentation. – RobertR Jul 28 '20 at 03:15

0 Answers0