Skip to content
  • Vyacheslav Dubeyko's avatar
    nilfs2: fix issue with flush kernel thread after remount in RO mode because of... · 8c26c4e2
    Vyacheslav Dubeyko authored
    nilfs2: fix issue with flush kernel thread after remount in RO mode because of driver's internal error or metadata corruption
    
    The NILFS2 driver remounts itself in RO mode in the case of discovering
    metadata corruption (for example, discovering a broken bmap).  But
    usually, this takes place when there have been file system operations
    before remounting in RO mode.
    
    Thereby, NILFS2 driver can be in RO mode with presence of dirty pages in
    modified inodes' address spaces.  It results in flush kernel thread's
    infinite trying to flush dirty pages in RO mode.  As a result, it is
    possible to see such side effects as: (1) flush kernel thread occupies
    50% - 99% of CPU time; (2) system can't be shutdowned without manual
    power switch off.
    
    SYMPTOMS:
    (1) System log contains error message: "Remounting filesystem read-only".
    (2) The flush kernel thread occupies 50% - 99% of CPU time.
    (3) The system can't be shutdowned without manual power switch off.
    
    REPRODUCTION PATH:
    (1) Create volume group with name "unencrypted" by ...
    8c26c4e2