From owner-freebsd-questions@FreeBSD.ORG Fri Jul 9 08:19:56 2004 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 768A916A4CE for ; Fri, 9 Jul 2004 08:19:56 +0000 (GMT) Received: from vs3.bgnett.no (vs3.bgnett.no [194.54.96.185]) by mx1.FreeBSD.org (Postfix) with ESMTP id A774043D39 for ; Fri, 9 Jul 2004 08:19:55 +0000 (GMT) (envelope-from peter@bgnett.no) Received: from tosh.datadok.no.bgnett.no (tosh.datadok.no [194.54.103.99]) by vs3.bgnett.no (8.12.9p2/8.12.9) with ESMTP id i698JnQ2019107 for ; Fri, 9 Jul 2004 10:19:50 +0200 (CEST) (envelope-from peter@bgnett.no) Sender: peter@tosh.datadok.no To: freebsd-questions@freebsd.org References: From: peter@bgnett.no (Peter N. M. Hansteen) Date: 09 Jul 2004 10:19:22 +0200 In-Reply-To: Message-ID: <87bripoanp.fsf@tosh.datadok.no> Lines: 42 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-bgnett.no-virusscanner: Found to be clean X-Envelope-To: freebsd-questions@freebsd.org Subject: Re: disk space question 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: Fri, 09 Jul 2004 08:19:56 -0000 Andrew Musselman writes: > I would like more space in /usr. I've installed another drive and set > it to mount to /mnt. I would like to make FreeBSD(5.2.1) think that > /usr also includes this new drive. > > Is there a way to do what I want to do? Yes. You could copy say, the contents of /usr/local to /mnt, then replace /usr/local with a symlink to /mnt. Not pretty, should be done from single user mode only and you'd need somewhere else to mount things temporarily, but it *will*, sort of, do what you want. A more permanent solution would be something along the lines of (assuming there's a usable file system at /mnt) # cd /usr/local # tar cf - . | (cd /mnt; tar xvf - 2>/var/tmp/mycopyerrors) check /var/tmp/mycopyerrors for any errors ( if you're not in single user already, go there NOW ) # mv /usr/local /usr/local.old # mkdir /usr/local #vi /etc/fstab edit so your new disk gets mounted as /usr/local, save # reboot check that your system works ok, when you're certain everything's ok, # rm -rf /usr/local.old /var/tmp/mycopyerrors untested, from memory, adjust as needed, and if it kills your puppy, I will *not* revive it. - P -- Peter N. M. Hansteen, member of the first RFC 1149 implementation team http://www.blug.linux.no/rfc1149/ http://www.datadok.no/ "First, we kill all the spammers" The Usenet Bard, "Twice-forwarded tales"