From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from syrinx.knorrie.org ([82.94.188.77]:41236 "EHLO syrinx.knorrie.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758418AbcLANwB (ORCPT ); Thu, 1 Dec 2016 08:52:01 -0500 Subject: Re: Metadata balance fails ENOSPC To: Andrei Borzenkov , Stefan Priebe - Profihost AG References: <04e767a6-ff6f-95ba-f2f9-6061035dcd10@profihost.ag> Cc: Chris Murphy , "linux-btrfs@vger.kernel.org" From: Hans van Kranenburg Message-ID: Date: Thu, 1 Dec 2016 14:51:57 +0100 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Sender: linux-btrfs-owner@vger.kernel.org List-ID: On 12/01/2016 09:12 AM, Andrei Borzenkov wrote: > On Thu, Dec 1, 2016 at 10:49 AM, Stefan Priebe - Profihost AG > wrote: > ... >> >> Custom 4.4 kernel with patches up to 4.10. But i already tried 4.9-rc7 >> which does the same. >> >> >>>> # btrfs filesystem show /ssddisk/ >>>> Label: none uuid: a69d2e90-c2ca-4589-9876-234446868adc >>>> Total devices 1 FS bytes used 305.67GiB >>>> devid 1 size 500.00GiB used 500.00GiB path /dev/vdb1 >>>> >>>> # btrfs filesystem usage /ssddisk/ >>>> Overall: >>>> Device size: 500.00GiB >>>> Device allocated: 500.00GiB >>>> Device unallocated: 1.05MiB >>> >>> Drive is actually fully allocated so if Btrfs needs to create a new >>> chunk right now, it can't. However, >> >> Yes but there's lot of free space: >> Free (estimated): 193.46GiB (min: 193.46GiB) >> >> How does this match? >> >> >>> All three chunk types have quite a bit of unused space in them, so >>> it's unclear why there's a no space left error. >>> > > I remember discussion that balance always tries to pre-allocate one > chunk in advance, and I believe there was patch to correct it but I am > not sure whether it was merged. http://www.spinics.net/lists/linux-btrfs/msg56772.html >>> Try remounting with enoscp_debug, and then trigger the problem again, >>> and post the resulting kernel messages. >> >> With enospc debug it says: >> [39193.425682] BTRFS warning (device vdb1): no space to allocate a new >> chunk for block group 839941881856 >> [39193.426033] BTRFS info (device vdb1): 1 enospc errors during balance -- Hans van Kranenburg