[lkml]   [2001]   [Apr]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    Patch in this message
    Subject[patch] linux likes to kill bad inodes

    I had a temporary disk failure (played with acpi too much). What
    happened was that disk was not able to do anything for five minutes
    or so. When disk recovered, linux happily overwrote all inodes it
    could not read while disk was down with zeros -> massive disk

    Solution is not to write bad inodes back to disk.

    [Thanx to Jan Kara]

    --- clean/fs/inode.c Wed Apr 4 23:58:04 2001
    +++ linux/fs/inode.c Sun Apr 22 14:04:46 2001
    @@ -179,7 +179,7 @@

    static inline void write_inode(struct inode *inode, int sync)
    - if (inode->i_sb && inode->i_sb->s_op && inode->i_sb->s_op->write_inode)
    + if (inode->i_sb && inode->i_sb->s_op && inode->i_sb->s_op->write_inode && !is_bad_inode(inode))
    inode->i_sb->s_op->write_inode(inode, sync);

    I'm "In my country we have almost anarchy and I don't care."
    Panos Katsaloulis describing me w.r.t. patents at
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    More majordomo info at
    Please read the FAQ at
     \ /
      Last update: 2005-03-22 13:28    [W:0.020 / U:21.168 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site