From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1LlM9I-0000Go-ES for garchives@archives.gentoo.org; Sun, 22 Mar 2009 11:47:28 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 04523E07F9; Sun, 22 Mar 2009 11:47:27 +0000 (UTC) Received: from ey-out-1920.google.com (ey-out-1920.google.com [74.125.78.147]) by pigeon.gentoo.org (Postfix) with ESMTP id B2415E07F9 for ; Sun, 22 Mar 2009 11:47:26 +0000 (UTC) Received: by ey-out-1920.google.com with SMTP id 4so221212eyg.10 for ; Sun, 22 Mar 2009 04:47:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:subject:date :user-agent:references:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:message-id; bh=tCn+qpnIR8r+2o9AGWoqJeXgSKBG7pREXqFRbMs/XXc=; b=igQZNLvn6njuUIE1aQbhtisBl3iLV5WYjBJnLIjXp6YQ9PR9enEnRn6l8cxSZFObkO 88b07DfRTwHdSup0AtOCumrAV/eLN/4PvFPSLVcJZWh4zFSwTxIfkePLiJ+mOM3G4mbc qrHLeJQyZpHYeBPoZVpM1QXC9Q9qZ/hg8PPuQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:subject:date:user-agent:references:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :message-id; b=eBy8/na/EjGhziV9koaDKWBWRMydYaBQ5s4NNgYMUzem60NS+rZ8Ns6Kh0yApH+NmS ktyMYXpo5bEf/NgZ31dWD6AcOpsTPEiaMgop8qH8UVx48o2fCynl1DMHbrLSGjEg4vHQ wfG5TIZP19tT3YbMCs1yS84PNjQ2e6ncnDDY0= Received: by 10.210.53.1 with SMTP id b1mr3830357eba.92.1237722446082; Sun, 22 Mar 2009 04:47:26 -0700 (PDT) Received: from nazgul.localnet (196-210-153-139-rrdg-esr-2.dynamic.isadsl.co.za [196.210.153.139]) by mx.google.com with ESMTPS id 10sm4505583eyz.19.2009.03.22.04.47.25 (version=SSLv3 cipher=RC4-MD5); Sun, 22 Mar 2009 04:47:25 -0700 (PDT) From: Alan McKinnon To: gentoo-user@lists.gentoo.org Subject: Re: [gentoo-user] extending /usr partition... Date: Sun, 22 Mar 2009 13:45:56 +0200 User-Agent: KMail/1.11.1 (Linux/2.6.28-gentoo-r3; KDE/4.2.1; x86_64; ; ) References: <49C52C76.4030609@gmail.com> <200903221033.00497.dirk.heinrichs@online.de> <49C61A03.6050800@gmail.com> In-Reply-To: <49C61A03.6050800@gmail.com> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200903221345.56656.alan.mckinnon@gmail.com> X-Archives-Salt: 10b26024-e961-4f19-83bb-e4c146d3ca1e X-Archives-Hash: d7eac623056170dfc63d2d3a33a49254 On Sunday 22 March 2009 12:59:15 Jarry wrote: > Are you sure? man resize2fs says: > > "...The resize2fs program will resize ext2 or ext3 file systems. > It can be used to enlarge or shrink an unmounted file system > located on device. If the filesystem is mounted, it can be used > to expand the size of the mounted filesystem, assuming the kernel > supports on-line resizing..." > > If I understand correctly, you can only extend ext3-partition > with it. But shrinking must be done off-line, on unmounted fs... Yes, and this is true for *any* filesystem. Some mature filesystems out there don't support resizing at all in any form. Enlarging a filesystems on line is easy. Make the device holding it bigger, add new inodes, add inodes to the inode tree and Hey Presto! filesystem is bigger. It's quick as you are *guaranteed* that the new inodes are not in use until the resize ends. Reducing is entirely different. You have to take inodes in use at the end of the filesystem, move them to somewhere else, fix the pointers in other inodes that point to them, repeat for all other inodes that will have to go away after the resize. Yuck. Tricky code :-) You are going to have this problem with any inode-based filesystem, not just ext3. -- alan dot mckinnon at gmail dot com