Re: [PATCH] Btrfs: fix deadlock with nested trans handles

2014-03-20 Thread Rich Freeman
On Sat, Mar 15, 2014 at 7:51 AM, Duncan 1i5t5.dun...@cox.net wrote: 1) Does running the snapper cleanup command from that cron job manually trigger the problem as well? As you can imagine I'm not too keen to trigger this often. But yes, I just gave it a shot on my SSD and cleaning a few days

Re: [PATCH] Btrfs: fix deadlock with nested trans handles

2014-03-20 Thread Duncan
Rich Freeman posted on Thu, 20 Mar 2014 22:13:51 -0400 as excerpted: However, I am my snapshots one at a time at a rate of one every 5-30 minutes, and while that is creating surprisingly high disk loads on my ssd and hard drives, I don't get any panics. I figured that having only one

Re: [PATCH] Btrfs: fix deadlock with nested trans handles

2014-03-17 Thread Josef Bacik
On 03/14/2014 06:40 PM, Rich Freeman wrote: On Wed, Mar 12, 2014 at 12:34 PM, Rich Freeman r-bt...@thefreemanclan.net wrote: On Wed, Mar 12, 2014 at 11:24 AM, Josef Bacik jba...@fb.com wrote: On 03/12/2014 08:56 AM, Rich Freeman wrote: After a number of reboots the system became stable,

Re: [PATCH] Btrfs: fix deadlock with nested trans handles

2014-03-15 Thread Duncan
Rich Freeman posted on Fri, 14 Mar 2014 18:40:25 -0400 as excerpted: And some more background. I had more reboots over the next two days at the same time each day, just after my crontab successfully completed. One of the last thing it does is runs the snapper cleanups which delete a bunch

Re: [PATCH] Btrfs: fix deadlock with nested trans handles

2014-03-14 Thread Rich Freeman
On Wed, Mar 12, 2014 at 12:34 PM, Rich Freeman r-bt...@thefreemanclan.net wrote: On Wed, Mar 12, 2014 at 11:24 AM, Josef Bacik jba...@fb.com wrote: On 03/12/2014 08:56 AM, Rich Freeman wrote: After a number of reboots the system became stable, presumably whatever race condition btrfs was

Re: [PATCH] Btrfs: fix deadlock with nested trans handles

2014-03-12 Thread Rich Freeman
On Thu, Mar 6, 2014 at 7:25 PM, Zach Brown z...@redhat.com wrote: On Thu, Mar 06, 2014 at 07:01:07PM -0500, Josef Bacik wrote: Zach found this deadlock that would happen like this And this fixes it. It's run through a few times successfully. I'm not sure if my issue is related to this or

Re: [PATCH] Btrfs: fix deadlock with nested trans handles

2014-03-12 Thread Josef Bacik
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 03/12/2014 08:56 AM, Rich Freeman wrote: On Thu, Mar 6, 2014 at 7:25 PM, Zach Brown z...@redhat.com wrote: On Thu, Mar 06, 2014 at 07:01:07PM -0500, Josef Bacik wrote: Zach found this deadlock that would happen like this And this fixes it.

Re: [PATCH] Btrfs: fix deadlock with nested trans handles

2014-03-12 Thread Rich Freeman
On Wed, Mar 12, 2014 at 11:24 AM, Josef Bacik jba...@fb.com wrote: On 03/12/2014 08:56 AM, Rich Freeman wrote: After a number of reboots the system became stable, presumably whatever race condition btrfs was hitting followed a favorable path. I do have a 2GB btrfs-image pre-dating my

[PATCH] Btrfs: fix deadlock with nested trans handles

2014-03-06 Thread Josef Bacik
Zach found this deadlock that would happen like this btrfs_end_transaction - reduce trans-use_count to 0 btrfs_run_delayed_refs btrfs_cow_block find_free_extent btrfs_start_transaction - increase trans-use_count to 1 allocate chunk btrfs_end_transaction -

Re: [PATCH] Btrfs: fix deadlock with nested trans handles

2014-03-06 Thread Zach Brown
On Thu, Mar 06, 2014 at 07:01:07PM -0500, Josef Bacik wrote: Zach found this deadlock that would happen like this btrfs_end_transaction - reduce trans-use_count to 0 btrfs_run_delayed_refs btrfs_cow_block find_free_extent btrfs_start_transaction - increase trans-use_count