Skip to content

Redfs ubuntu noble writethrough split#183

Closed
hbirth wants to merge 3 commits into
DDNStorage:redfs-ubuntu-noble-6.8.0-58.60from
hbirth:redfs-ubuntu-noble-writethrough-split
Closed

Redfs ubuntu noble writethrough split#183
hbirth wants to merge 3 commits into
DDNStorage:redfs-ubuntu-noble-6.8.0-58.60from
hbirth:redfs-ubuntu-noble-writethrough-split

Conversation

@hbirth

@hbirth hbirth commented Jun 15, 2026

Copy link
Copy Markdown
Collaborator

No description provided.

Signed-off-by: Horst Birthelmer <hbirthelmer@ddn.com>
@hbirth hbirth requested review from bsbernd, cding-ddn and yongzech June 15, 2026 06:01
Comment thread fs/fuse/file.c Outdated
bsbernd
bsbernd previously approved these changes Jun 15, 2026
@hbirth hbirth force-pushed the redfs-ubuntu-noble-writethrough-split branch from c844190 to 88aaf07 Compare June 15, 2026 07:54
Comment thread fs/fuse/file.c
* for them. Unaligned writes keep using the writeback cache, where they
* can merge with neighbouring data.
*/
static bool fuse_use_writeback_cache(struct fuse_conn *fc, struct kiocb *iocb,

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about for the small aligned write, such as 4K, 8K, what if we have a threshold, which is our bucket size (2M), if aligned, but less than 2M, still do write-back cache?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes ... still writeback... in the hope that more writes will be done and we can write alogned later. If during this delay, we get a flush or invalidate, than we haven't lost anything

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

when fc->big_writes will true?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is a parameter from the fuse server

@hbirth hbirth Jun 15, 2026

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if it is false FUSE will write every page separately

hbirth added 2 commits June 15, 2026 12:14
Writes that already match the alignment advertised via
FUSE_ALIGN_PG_ORDER gain nothing from the writeback cache and can
degrade into page-sized WRITE requests under dirty throttling.  Send
them through fuse_perform_write() instead, which packs requests up to
max_write and keeps them stripe-aligned for the backend.  They create
no dirty pages, so no DLM write lock needs to be cached for them.
Unaligned writes keep using the writeback cache.

Also clarify in the uapi header that align_page_order is the log2 of
the alignment in bytes, not in pages.

Signed-off-by: Horst Birthelmer <hbirthelmer@ddn.com>
Add a per-connection size threshold, settable via fusectl as
writethrough_threshold, that sends buffered writes >= threshold
through fuse_perform_write() regardless of alignment.

The knob is off by default (0 == disabled) and leaves the existing
alignment-based decision in place for writes below the threshold.

Signed-off-by: Horst Birthelmer <hbirthelmer@ddn.com>
@hbirth hbirth force-pushed the redfs-ubuntu-noble-writethrough-split branch from 88aaf07 to c1b073f Compare June 15, 2026 11:09
@hbirth hbirth closed this Jun 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants