On Sat, Feb 16, 2019 at 4:39 AM John Klann <jk7255@gmail.com> wrote:
> I was able to test the patch without issue and it appears to have worked see below. Let me know if there is further
testingI can do or logging you would like.
Thanks. So that leaves the question for the list: should we accept
this as a bug and consider back-patching it? Our relationship with
fsync() is ... complicated at the moment. Considering that we already
tolerated EBADF for directories on some other (forgotten?) operating
system, I think I would vote +1 for doing that ... if I didn't know
that they'd fixed this on the Linux side, and I see now that they've
back-patched that even to long term kernel 3.16:
https://cdn.kernel.org/pub/linux/kernel/v3.x/ChangeLog-3.16.60
You mentioned that you were on RHEL 7.5, which ships with a 3.10
kernel. When you eventually move to RHEL 8 (4.x) or even install an
alternative newer kernel for 7.x, the problem will hopefully go away
by itself. Considering that, the lack of other complaints, and the
availability of a workaround (--no-sync followed by "sync"), I'm not
so sure it's worth committing this.
PS I found an earlier discussion of this topic that didn't go
anywhere: https://www.postgresql.org/message-id/flat/E1RhkjA-0005bq-B6%40wrigleys.postgresql.org
--
Thomas Munro
http://www.enterprisedb.com