From patchwork Wed May 4 18:16:14 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Goffredo Baroncelli X-Patchwork-Id: 754442 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p44IGXoW018121 for ; Wed, 4 May 2011 18:16:33 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755333Ab1EDSQT (ORCPT ); Wed, 4 May 2011 14:16:19 -0400 Received: from smtp207.alice.it ([82.57.200.103]:55153 "EHLO smtp207.alice.it" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755150Ab1EDSQR (ORCPT ); Wed, 4 May 2011 14:16:17 -0400 Received: from [192.168.7.27] (87.6.216.161) by smtp207.alice.it (8.5.124.08) (authenticated as kreijack@alice.it) id 4DB13887013BEA42; Wed, 4 May 2011 20:16:12 +0200 Message-ID: <4DC197EE.1030600@libero.it> Date: Wed, 04 May 2011 20:16:14 +0200 From: Goffredo Baroncelli Reply-To: kreijack@inwind.it User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.15) Gecko/20110402 Iceowl/1.0b2 Icedove/3.1.9 MIME-Version: 1.0 To: Lubos Kolouch , Chris Mason CC: linux-btrfs@vger.kernel.org Subject: Re: Cannot resize btrfs volume References: In-Reply-To: X-Enigmail-Version: 1.1.2 Sender: linux-btrfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-btrfs@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Wed, 04 May 2011 18:16:33 +0000 (UTC) Hi, several time ago I posted a patch which addressed this lack of documentation [1]. Unfortunately when I revised this patch I missed this chunk, and now Chris merged the last (uncompleted) revision. So now I am publish a new patch which address this issue. Chris, if you want you can pull it from http://cassiopea.homelinux.net/git/btrfs-progs-unstable.git or browse it at "http://cassiopea.homelinux.net/git/?p=btrfs-progs-unstable.git;a=summary". Below the patch. Regards G.Baroncelli If the prefix \fI+\fR or \fI\-\fR is present the size is increased or decreased @@ -164,6 +164,9 @@ The \fBresize\fR command \fBdoes not\fR manipulate the size partition. If you wish to enlarge/reduce a filesystem, you must make sure you can expand the partition before enlarging the filesystem and shrink the partition after reducing the size of the filesystem. + + is the ID of the device which was enlarged or which will be reduced. +To know the ID of a device use the command \fBbtrfs filesystem show\fR. .TP \fBbtrfs\fP \fBfilesystem label\fP\fI [newlabel]\fP @@ -188,7 +191,7 @@ Show the btrfs filesystem with some additional info. If no U passed, \fBbtrfs\fR show info of all the btrfs filesystem. .TP -\fBdevice balance\fR \fI\fR +\fBfilesystem balance\fR \fI\fR Balance the chunks of the filesystem identified by \fI\fR across the devices. .TP @@ -199,6 +202,7 @@ Add device(s) to the filesystem identified by \fI\fR. \fBdevice delete\fR\fI [..] \fR Remove device(s) from a filesystem identified by \fI\fR. + .PP .SH EXIT STATUS ---- [1] email "Re: [PATCH][btrfs progs] Update/clean up btrfs help and man page" on 10/9/2010 On 05/04/2011 10:41 AM, Lubos Kolouch wrote: > Hello again, > > OK I found it (randomly) on the wiki: > btrfs filesystem resize 3:max /home > > Seems like btrfs help is not up-to-date and the wiki is... > > Thank you again > > Lubos > > Lubos Kolouch, Wed, 04 May 2011 08:31:30 +0000: > >> Hello, >> >> I added a new disk into our RAID5 array, it looks like this: >> >> md2 : active raid5 sdd4[3] sde4[4] sda4[0] sdc4[2] sdb4[1] >> 3767274240 blocks level 5, 64k chunk, algorithm 2 [5/5] [UUUUU] >> >> # btrfs fi sh >> Label: none uuid: 5534d2e7-be31-49c7-8ab7-90c5ab8afe18 >> Total devices 1 FS bytes used 2.24TB >> devid 3 size 2.63TB used 2.63TB path /dev/md2 >> >> # mount >> ... >> /dev/md2 on /home type btrfs (rw,noatime,compress) >> >> # btrfs filesystem resize max /home >> Resize '/home' of 'max' >> ERROR: unable to resize '/home' >> >> # umount /home/ >> # btrfs filesystem resize max /dev/md2 Resize '/dev/md2' of 'max' >> ERROR: unable to resize '/dev/md2' >> >> # tail /var/log/messages >> May 4 10:28:57 localhost kernel: resizer unable to find device 1 >> >> 2.6.38-gentoo-r3, latest git btrfs-progs >> >> Can you please advice what to do? >> >> Thank you >> >> Lubos > > > -- > To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html > . > --- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/man/btrfs.8.in b/man/btrfs.8.in index 6f92f91..220bcbd 100644 --- a/man/btrfs.8.in +++ b/man/btrfs.8.in @@ -147,7 +147,7 @@ Force a sync for the filesystem identified by \fI\fR. .\" Some wording are extracted by the resize2fs man page .\" -\fBfilesystem resize\fR\fI [+/\-][gkm]|max \fR +\fBfilesystem resize\fR\fI [:][+/\-][gkm]|max \fR Resize a filesystem identified by \fI\fR. The \fI\fR parameter specifies the new size of the filesystem.