From owner-freebsd-questions Mon Mar 20 19:29:26 2000 Delivered-To: freebsd-questions@freebsd.org Received: from cc942873-a.ewndsr1.nj.home.com (cc942873-a.ewndsr1.nj.home.com [24.2.89.207]) by hub.freebsd.org (Postfix) with ESMTP id DE8B837BCB9 for ; Mon, 20 Mar 2000 19:29:12 -0800 (PST) (envelope-from cjc@cc942873-a.ewndsr1.nj.home.com) Received: (from cjc@localhost) by cc942873-a.ewndsr1.nj.home.com (8.9.3/8.9.3) id WAA82176; Mon, 20 Mar 2000 22:28:25 -0500 (EST) (envelope-from cjc) Date: Mon, 20 Mar 2000 22:28:25 -0500 From: "Crist J. Clark" To: Adam Cc: freebsd-questions Subject: Re: Moving FreeBSD from an IDE drive to a SCSI drive? Message-ID: <20000320222825.A81950@cc942873-a.ewndsr1.nj.home.com> Reply-To: cjclark@home.com References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0i In-Reply-To: ; from ajwoodbe@oakland.edu on Mon, Mar 20, 2000 at 04:41:40PM -0500 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Mon, Mar 20, 2000 at 04:41:40PM -0500, Adam wrote: > Has anyone moved a FreeBSD 3.4 installation from an IDE hard drive to a SCSI > hard disk? I'm installing a SCSI controller and hard disk in our current > FreeBSD 3.4 server, which is currently running on an IDE hard disk. Since > I've never moved FreeBSD between hard disks without re-installing FreeBSD, I > figured I'd ask you guys to see if 1.) it is possible and 2.) what is the > easiest way to do it? Is it possible to install the boot loader off of the > CD onto the new SCSI hard disk and then just copy everything onto the new > hard disk? Or would it be better to back everything up onto tape and then > restore it to the new SCSI disk? Please point out any pitfalls I may run > into so I can plan ahead of them. The reason I shy away from totally > reinstalling FreeBSD onto the new SCSI hard drive is because I've put a LOT > of work into customizing, securing, and optimizing the server and I'd really > like to avoid having to do all that work over again if it can be avoided. I > figure this process is pretty generic so I didn't include much system > information. Let me know if you need any more info. Thank you for the > help! This really should be pretty easy since you will be able to run the system with both drives at once. My personal advice, the way I would do it, is to: 1) Use fdisk(8) if you are not going to run in 'dangerously dedicated' mode. Slice up the disk as you want. 2) Use disklabel(8) to make the partitions you want (and this is a chance to rethink partitions if you are not pleased with the old setup). disklabel(8) is also the tool to put on the boot sectors, see the '-B' option on the manpage. 3) Now newfs(8) the paritions on the drive. 4) Copy over files from one disk to the other with a dump(8)-restore(8), # mount /dev/da0s1a /mnt # cd /mnt # dump -0af - / | restore -rf - And repeat for each partition. (This step is the one you will probably get other opinions on, but I like dump-restore myself.) The only challenge after that will be getting the right system to boot... and if you are planning to remove the IDE drive (not clear from your mail), that gets pretty easy (assuming the BIOS can handle a SCSI boot). -- Crist J. Clark cjclark@home.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message