# btrfs scrub freezes the system

## comio

Hi,

I'm running the last 4.7.2 linux kernel. I noticed that my nightly "btrfs scrub start -B" freezes the system and I need to hard reset with the power up button on the morning. The system is headless and I have not any crashdump from console (and system log is empty). Running via remote console I had the same issue (system lost).

Has anyone experienced the same issue? I will continue the investigation and I will try to attach a monitor to see any kernel message on the console.

best regards,

luigi

----------

## The_Great_Sephiroth

Have you tried it without the -B parameter? I ask because I have BTRFS on MANY systems and I do not use -B when I scrub. You can nALWAYS get the result of the last scrub by doing "btrfs scrub status <part/subvol/etc>", so you may not need it anyway. Beyond that, I do not know. Check SMART with smartctl?

----------

## comio

 *The_Great_Sephiroth wrote:*   

> Have you tried it without the -B parameter? I ask because I have BTRFS on MANY systems and I do not use -B when I scrub. You can nALWAYS get the result of the last scrub by doing "btrfs scrub status <part/subvol/etc>", so you may not need it anyway. Beyond that, I do not know. Check SMART with smartctl?

 

I need to came back at home because the gentoobox is still frozen and I need to hard-reset the machine.

I'm using -B flag in order to send the scrub results to my mailbox, but at this point I will try without this option to verify if there's any difference. I will also attach a monitor in order to see the kernel crashdump. 

Furthermore, I noticed that a new btrfs-progs has been released (4.7.2).

ciao

luig

----------

## Ant P.

That shouldn't happen. I've got `btrfs scrub start -B /` running from cron on 4 different machines and they all stay usable during and after.

In the meantime, you might want to see if your computer has a hardware watchdog chip (many do, even if it's not obvious) in case it hangs again. Even setting the kernel "panic timeout" option would be better than nothing.

----------

## Nortis

I had the same problem. I solved unchecking in the kernel menu File system - Btrfs with integrity check tool compiled in (DANGEROUS). Or you can change .config with # CONFIG_BTRFS_FS_CHECK_INTEGRITY

----------

