datto / dattobd

kernel module for taking block-level snapshots and incremental backups of Linux block devices
GNU General Public License v2.0
561 stars 120 forks source link

Kernel panic in cow_read_mapping #286

Closed lishuai-ujs closed 1 year ago

lishuai-ujs commented 1 year ago

centos 7.6.1810 3.10.0-957.el7.x86_64

图片

图片

图片

copy snapshot of /dev/vdc,kernel panic

图片

图片

图片

nickchen-cpu commented 1 year ago

please try xfs_repair it and then try again.

lishuai-ujs commented 1 year ago

I add flow print code in cow_read_mapping and find the pos is out of bound of array when kernel panic. 图片 图片

lishuai-ujs commented 1 year ago

accord to the vmcore, cow_read_mapping is called from snap_read_bio_get_mode 图片 图片

I add flow trace code and find the curr_end_bytes is uncorrect in second cycle of while loop, curr_end_bytes shound minus the bytes have read in first cycle. 图片 图片

dakotarwilliams commented 1 year ago

Resolved #287