> On Feb 4, 2022, at 3:55 PM, Patrick Goetz <pgoetz@xxxxxxxxxxxxxxx> wrote: > > > > On 2/2/22 13:55, Chuck Lever III wrote: >>> On Feb 1, 2022, at 8:41 PM, Simon Kirby <sim@xxxxxxxxxx> wrote: >>> >>> How far off would we be from write delegations happening here? >> We are tracking a "feature request" for write delegation support >> in the Linux NFS server: >> https://bugzilla.linux-nfs.org/show_bug.cgi?id=348 >> At this point the effort is not resourced. It's not clear how >> much benefit it would be. > > First shock is I thought write delegation was already supported. WRITE delegation and READ delegation are both supported on the Linux NFS client. The Linux NFS server offers only READ delegations. > But especially for users who have NFS mounted home directories, how could there not be a major performance benefit? To cite one example that has been a problem before (in particular, on Mac OSX clients with NFSv3 home directories mounted from a linux fileserver), facilitating the firefox "awesome" bar, which writes to a SQLlite database in ~/.mozilla/fireworks with alarming frequency in order to keep up the awesomeness. I might be missing something, but if SQlite is using fsync() then there isn't much choice for the NFS client but to push dirty data to the server and see that the data is committed. The purpose of that fsync() is to ensure the written data is robust against client or server failure. WRITE delegation would probably not have much impact on that. It's purpose is to enable the client to cache more aggressively in cases where immediate data persistence is not needed. The fact that there is only one client reading and updating that database is beside the point. > This flat out didn't work previously unless you went to about:config and set > > storage.nfs_filesystem = true > > Not at all sure how this changed the execution of firefox though. > > >> That said, it seems to me that your use case might benefit if >> the Linux NFS server offered a READ delegation for the SQLite >> database file even when it is open R/W. It might be appropriate >> if the server offered such a delegation when there are no other >> clients that have the file open for write or that hold write >> delegations. >> Patches and performance data are, as always, welcome. >> -- >> Chuck Lever -- Chuck Lever