From owner-freebsd-questions@FreeBSD.ORG Thu Mar 24 06:55:47 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 2195716A4CE for ; Thu, 24 Mar 2005 06:55:47 +0000 (GMT) Received: from dns1.popstick.com (dns1.popstick.com [66.37.210.4]) by mx1.FreeBSD.org (Postfix) with SMTP id 4A88043D41 for ; Thu, 24 Mar 2005 06:55:46 +0000 (GMT) (envelope-from mlists@northglobe.com) Received: (qmail 80625 invoked from network); 24 Mar 2005 06:55:45 -0000 Received: from unknown (HELO ?192.168.0.106?) (24.147.148.119) by dns1.popstick.com with SMTP; 24 Mar 2005 06:55:45 -0000 Message-ID: <42426471.9040007@northglobe.com> Date: Thu, 24 Mar 2005 01:55:45 -0500 From: Nicholas Basila User-Agent: Mozilla Thunderbird 1.0 (Windows/20041206) X-Accept-Language: en-us, en MIME-Version: 1.0 To: freebsd-questions@freebsd.org References: <1735169762.20050324050924@wanadoo.fr> In-Reply-To: <1735169762.20050324050924@wanadoo.fr> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: What's an easy way to replace a drive? 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, 24 Mar 2005 06:55:47 -0000 Anthony Atkielski wrote: >The continuing problems I'm having with my SATA drives seem to center on >only one of the two drives, /dev/ad10, and since both drives are >identical (Western Digital WD1200JD 120-GB SATA drives), this is a good >indicator that the drive itself might be failing. So I've decided to >spend $83 and buy a replacement drive to see if that fixes the problem. > >Now, what's the easiest way to replace the drive? The drive I want to >replace contains only /var and /tmp. Are these mounted in single-user >mode? I was thinking perhaps I can just replace the drive, set up >identical slices on the new drive, then restore /var and /tmp from the >latest backup. Can I restore from tape in single-user mode? > >I don't have any extra connectors to which I can attach this drive >without removing one of the other drives, so I'm looking for a way to >fix it up by just removing the old drive and putting in the new one, >without the need to have both old and new drives online at the same >time. > > > You can back up to tape and restore in single user mode. If /var and /tmp aren't too big, you could boot into single user mode, mount /usr mount -r /var (just to be safe) mount -r /tmp and create tar balls or even use dump to file (use the device in /dev as source, of course) with /var and /tmp unmounted. Then, reboot into single user mode with the new disk, set up the disk the way you want it with fdisk and bsdlabel, and then untar or restore from dump.