From owner-freebsd-questions Thu Mar 6 22: 3:45 2003 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8F57537B406 for ; Thu, 6 Mar 2003 22:03:43 -0800 (PST) Received: from tomts23-srv.bellnexxia.net (tomts23-srv.bellnexxia.net [209.226.175.185]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3AD9D43FDD for ; Thu, 6 Mar 2003 22:03:41 -0800 (PST) (envelope-from matt@gsicomp.on.ca) Received: from gabby.gsicomp.on.ca ([65.95.176.5]) by tomts23-srv.bellnexxia.net (InterMail vM.5.01.04.19 201-253-122-122-119-20020516) with ESMTP id <20030307060337.RSZP24585.tomts23-srv.bellnexxia.net@gabby.gsicomp.on.ca>; Fri, 7 Mar 2003 01:03:37 -0500 Received: from hermes (hermes.gsicomp.on.ca [192.168.0.18]) by gabby.gsicomp.on.ca (8.12.6/8.12.6) with SMTP id h2760YjC069200; Fri, 7 Mar 2003 01:00:34 -0500 (EST) (envelope-from matt@gsicomp.on.ca) Message-ID: <026001c2e46f$28529a00$1200a8c0@gsicomp.on.ca> From: "Matthew Emmerton" To: "Murray Taylor" , Cc: References: <200303071654.41171.murraytaylor@bytecraftsystems.com> Subject: Re: Growing / shrinking a file system Date: Fri, 7 Mar 2003 01:02:37 -0500 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1106 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG ----- Original Message ----- From: "Murray Taylor" To: Cc: Sent: Friday, March 07, 2003 12:54 AM Subject: Growing / shrinking a file system > I've found growfs and looked at tunefs--- is there a utility to shrink a > partition so that I can give the space to another one No. > operator@redback(/sbin)ttyp1 > df -h > Filesystem Size Used Avail Capacity Mounted on > /dev/ad0s1a 97M 41M 48M 46% / > /dev/ad0s1f 17G 1.8G 14G 11% /usr > /dev/ad0s1e 19M 7.9M 9.9M 44% /var > procfs 4.0K 4.0K 0B 100% /proc > > This is the current disk stats ... NB this disk was setup using auto sizing > from the install CD (poss miscalculation??) Auto-sizing is not perfect for everyone, especially people running large mail servers or database servers which require lots of space in /var. > We need to reallocate space from ad0s1f and give it to ad0s1e > preferably with out rebuilding the machine. > > I am thinking of paxing /var to /usr/var, then unmounting /var > and symlinking /usr/var to /var as an interim step What is your main consumer of space in /var? One trick I've often done is create a /usr/var2 directory, move stuff from /var into /usr/var2 (such as /var/log and /var/mail) and then symlink the directories from /var over to /usr/var2. > But I would like them to remain on separate better sized slices Then your only choice is to backup, re-splice and restore. -- Matt Emmerton To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message