On Fri, Nov 10, 2017 at 11:10 AM, Raphael Hertzog <raphael@xxxxxxxxx> wrote: > Hi Amir, > > Le mercredi 08 novembre 2017, Amir Goldstein a écrit : >> The problem reported by Raphael is that new PostgreSQL 10.0 with a >> database in overlayfs where lower layer in squashfs fails to start. >> The failure is due to fsync error, when PostgreSQL does fsync on all >> existing db directories on startup and a specific directory exists >> lower layer with no changes. > > I confirm that this patch is enough to fix my issue. > > Tested-by: Raphaël Hertzog <hertzog@xxxxxxxxxx> Thanks for testing! > > I wonder if we can have a similar problem with a file. Is it possible to > fsync a file opened in read-only mode? Even if it's possible, I assume > this is really rare. > We do have the same problem with file. It is not rare at all. the command "sync <file>" will do just that. Only difference is that the fix is not a one liner and I believe hijacking file operations for regular file is already on Miklos' plans. > And when you open a file with read-write permissions, when does the > copy-up happen? If it's immediately, then fsync on such a file is safe as > well. > Yes, copy up happens on open for write. Amir. -- To unsubscribe from this list: send the line "unsubscribe linux-unionfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html