jbd2_mark_journal_empty(9)
π
jbd2_mark_journal_empty(9) β a Kernel API Manual moment π
okay so bestie, welcome to the Kernel API Manual β¨ and today's main character is literally a function that tells the whole filesystem "yeah the journal? empty. nothing in it. we're clean." iconic behavior tbh π«Ά
πΈ NAME πΈ
jbd2_mark_journal_empty β Mark on disk journal as empty. no cap, that's the whole vibe π
β¨ SYNOPSIS β¨
void jbd2_mark_journal_empty (journal_t *journal , blk_opf_t write_flags
);
it returns void btw β it does the thing and dips, no receipts π
π¦ ARGUMENTS π¦
journalβ The journal to update. this is the one getting the glow-up πwrite_flagsβ Flags for the journal sb write operation. yk, the superblock write config π
π DESCRIPTION π
so what does it actually do? it updates a journal's dynamic superblock fields to show that the journal is empty π§ lowkey important, highkey cute.
then it writes that updated superblock to disk, and β and this is the part that matters β it waits for IO to complete π like it's not just fire-and-forget, it's committed to the bit. it sits there until the write actually lands. main character energy fr fr πβ¨
π SEE ALSO π
the source lives in the kernel file ./fs/jbd2/journal.c π and here's the whole friend group of sibling functions, all of them serving π
:
jbd2_journal_force_commit_nested(9)jbd2_journal_force_commit(9)jbd2_journal_shrink_scan(9)jbd2_journal_shrink_count(9)jbd2_journal_init_dev(9)jbd2_journal_init_inode(9)jbd2_journal_update_sb_log_tail(9)__jbd2_journal_erase(9)jbd2_journal_update_sb_errno(9)jbd2_journal_load(9)jbd2_journal_destroy(9)jbd2_journal_check_used_features(9)jbd2_journal_check_available_features(9)jbd2_journal_set_features(9)jbd2_journal_flush(9)jbd2_journal_wipe(9)jbd2_journal_abort(9)jbd2_journal_errno(9)jbd2_journal_clear_err(9)jbd2_journal_ack_err(9)
bestie reminder: this page is filed under./fs/jbd2, dated October 2026, and it's officiallyjbd2_mark_journal_empty(9)β iykyk πβ¨ go forth and mark things empty, queen ππ¦
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms