From owner-freebsd-questions@FreeBSD.ORG Thu Apr 21 13:55:27 2005 Return-Path: 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 00F6E16A4E6 for ; Thu, 21 Apr 2005 13:55:23 +0000 (GMT) Received: from clunix.cl.msu.edu (clunix.cl.msu.edu [35.9.2.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id 27D5C43D31 for ; Thu, 21 Apr 2005 13:55:23 +0000 (GMT) (envelope-from jerrymc@clunix.cl.msu.edu) Received: from clunix.cl.msu.edu (localhost [127.0.0.1]) j3LDtNb0016551; Thu, 21 Apr 2005 09:55:23 -0400 (EDT) Received: (from jerrymc@localhost) by clunix.cl.msu.edu (8.12.10+Sun/8.12.2/Submit) id j3LDtNLZ016550; Thu, 21 Apr 2005 09:55:23 -0400 (EDT) From: Jerry McAllister Message-Id: <200504211355.j3LDtNLZ016550@clunix.cl.msu.edu> To: dmehler26@woh.rr.com Date: Thu, 21 Apr 2005 09:55:23 -0400 (EDT) In-Reply-To: <000501c54620$63158660$0200a8c0@satellite> X-Mailer: ELM [version 2.5 PL7] MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit cc: freebsd-questions@freebsd.org Subject: Re: resizing partitions X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 21 Apr 2005 13:55:27 -0000 > > Hello, > I've got a 5.3-RELEASE box which has a /usr partition /dev/ad0s1e that > is to small by approximately 700 mb. I've got the space on /var /dev/ad0s1d > to do a resize, but i am unsure as to the procedure. I tried this once a > while back on a test box and lost everything. If anyone has done this or has > a procedure i'd be interested. Instead of actually resizing the partition, you can just move some of the stuff to a partition where you have plenty of room and then make sym-links to it. /usr/local and /usr/ports are good candidates. Tar the whole directory tree up and put it where you want and untar it. Then make links and rm the old one. For example, I often make a partition and mount it as /work that contains all my spare disk space in a slice. If I put /usr/ports over there it would look something like this: cd /usr/ports tar cvf /work/ports.tar * cd /work mkdir usr.ports cd usr.ports tar xvf ../ports.tar Then look around in /work/usr.ports a bit to make sure it looks ok cd /usr ---------------------------- mv ports ports.old if you are really nervous, else just rm it ---------------------------- ln -s /work/usr.ports ports Try out the link by doing something like cd /usr/ports and looking around It should put you in /work/usr.ports/wherever cd /usr rm -rf ports.old cd /work rm ports.tar Works just fine. I am always nervous about my typing so I normally do the extra steps of mv-ing the old one and checking things before actuall rm-ing the old stuff. But it can be skipped if you don't have that problem. You can call your extra partition mount point whatever you like. Since /var can fill up with stuff such as mail and logs and spools and db if you are running a database, you might not want to use it to house the extra stuff unless you have a really big /var - well beyond what you think you might ever need. I reserve /var for those things that grow unexpectedly so they can sort of be isolated there and make another space (/work or whatever) for space manipulation and other work - just a comment. ////jerry > Thanks. > Dave. > > _______________________________________________ > freebsd-questions@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org" >