From owner-freebsd-questions Mon Feb 12 19:27:51 2001 Delivered-To: freebsd-questions@freebsd.org Received: from cody.jharris.com (cody.jharris.com [205.238.128.83]) by hub.freebsd.org (Postfix) with ESMTP id EB65837B4EC for ; Mon, 12 Feb 2001 19:27:45 -0800 (PST) Received: from localhost (nick@localhost) by cody.jharris.com (8.11.1/8.9.3) with ESMTP id f1D3oJn65352; Mon, 12 Feb 2001 21:50:19 -0600 (CST) (envelope-from nick@rogness.net) Date: Mon, 12 Feb 2001 21:50:19 -0600 (CST) From: Nick Rogness X-Sender: nick@cody.jharris.com To: Brad W Cc: questions@FreeBSD.ORG Subject: Re: Transfer disk space form /usr to root partition In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Mon, 12 Feb 2001, Brad W wrote: > First of all, is this possible? I have exceeded all available space on my > root partition. Yes, it is doable. > > Filesystem Size Used Avail Capacity Mounted on > /dev/ad0s2a 51M 51M -4.0M 109% / > /dev/ad0s2f 4.6G 1.8G 2.4G 42% /usr > /dev/ad0s2e 20M 9.7M 9.0M 52% /var > procfs 4.1K 4.1K 0B 100% /proc > > > I should have made my root partition larger when I initially installed but, > ahh... too late now. Is there any valuable documentation on doing this and > if so where? 1) Add a new disk to the system 2) fdisk and disklabel it (via /stand/sysinstall or manually) 3) mount the filesystem(s) on the new disk (example: Where ad1 is the new disk) # mount /dev/ad1s1a /mnt # mount /dev/ad1s1f /mnt/usr # mount /dev/ad1s1e /mnt/var 4) Dump the data and restore it. This copies your existing filesystems to the new disk, example: # dump 0af - / |(cd /mnt;restore xf -) # dump 0af - /usr |(cd /mnt/usr;restore xf -) # dump 0af - /var |(cd /mnt/var;restore xf -) 5) edit and change your /etc/fstab file to reflect the new changes, save it and reboot! Of course, you don't need to change all the filesystems if you don't want to. I used all of your filesystems above but you could just as easily just change root and/or usr. Nick Rogness - Keep on routing in a Free World... "FreeBSD: The Power to Serve!" To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message