JBD2: print io_block if check data block checksum failed when do recovery
v2 cover JBD2: print io_block if check data block checksum failed when do recovery
Diff v2 vs v1:
Modify print information for the first patch according to Jan Kara's suggestion.
Ye Bin (2):
JBD2: print io_block if check data block checksum failed when do
recovery
JBD2: fix printk format type for 'io_block' in do_one_pass()
fs/jbd2/recovery.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
Signature · 1 line
2.31.1
PATCH v2 1/2 JBD2: print io_block if check data block checksum failed when do recovery
Now, if check data block checksum failed only print data's block number then skip write data. However, one data block may in more than one transaction. In some scenarios, offline analysis is inconvenient. As a result, it is difficult to locate the areas where data is faulty.
So print 'io_block' if check data block checksum failed.
--- fs/jbd2/recovery.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
fs/jbd2/recovery.c +2 -1
@@ -661,7 +661,8 @@ static int do_one_pass(journal_t *journal,printk (KERN_ERR "JBD2: Invalid " "checksum recovering " "data block %llu in " -"log\n" , blocknr); +"journal block %lu\n" , + blocknr, io_block); block_error =1 ; goto skip_write; }
Signature · 1 line
2.31.1
PATCH v2 2/2 JBD2: fix printk format type for 'io_block' in do_one_pass()
In reply to Ye Bin'io_block' is unsinged long but print it by '%ld'.
--- fs/jbd2/recovery.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/jbd2/recovery.c +1 -1
@@ -632,7 +632,7 @@ static int do_one_pass(journal_t *journal, success = err;printk (KERN_ERR "JBD2: IO error %d recovering " -"block %ld in log\n" , +"block %lu in log\n" , err, io_block); }else {unsigned long long blocknr;
Signature · 1 line
2.31.1
Quoted 9 lines · Ye Bin
Diff v2 vs v1:
Modify print information for the first patch according to Jan Kara's suggestion.Ye Bin (2):
JBD2: printio_blockif check data block checksum failed when do
recovery
JBD2: fix printk format type for 'io_block' indo_one_pass()[...]
Applied, thanks!
[1/2] JBD2: print io_block if check data block checksum failed when do recovery
commit: 71cd5a5aa0607073adba3852739b7f8c22bc7b50
[2/2] JBD2: fix printk format type for 'io_block' in do_one_pass()
commit: 8b6b562121f1981315e76b6ae1f8a5cbbcf14bd7Best regards,
Signature · 1 line
Theodore Ts'o <[email protected]>