On Wed, 26 May 2010 22:33:16 -0400, Steve Bertrand <st...@ipv6canada.com> wrote: > I've written a few "howto"'s on backup/restore/cloning in the past, but > now I have a question that I hope to have quickly answered. > > I'm not looking for criticism on my approach, only on whether it will > work. With that said, I'll lay out my scenario and my questions. > > Scenario: > > - live web server (300 domains), shut the box down and booted up a copy > of the system on new hardware > > - changed the normal system items (nic, fstab etc) > > - new box is running fine under old system, but I need to transfer the > old system data (all of it...*all* data) to the new disk sub-structure > > - new box has RAID card, but not compatible w/FBSD > > - new box has had RAID card disabled, so new disks show up as standard > adX drives > > Questions: > > - while running the 'new' box under the 'old' system, can I: > --- atacontrol create RAID1 ad4 ad6 > --- fdisk > --- label: to items under /mnt, as to prepare for copy > > - stop all services (or go into single-user), and dump each slice from > orig to new > > ...if so, please advise of the dump command that I'd be using. > > Normally I'd use rsync, but this situation can sustain some downtime to > ensure a complete and utter mirror.
If you want to use dump/restore to copy the root partition from ad0s1a to ad4s1a you can use: # newfs -L NEWROOT /dev/ad4s1a # mount -t ufs /dev/ufs/NEWROOT /mnt # cd /mnt # dump -0auL -C 32 -f - / | restore -rf - When this is run in single-user mode, the partiion mounted at /mnt should have a copy of the root filesystem. Repeat the dump-restore pipe for other filesystems, e.g.: # newfs -L NEWDATA /dev/ad4s2a # mount -t ufs /dev/ufs/NEWDATA /mnt/data # cd /mnt/data # dump -0auL -C 32 -f - /data | restore -rf - # newfs -L NEWHOME /dev/ad4s3a # mount -t ufs /dev/ufs/NEWHOME /mnt/home # cd /mnt/home # dump -0auL -C 32 -f - /home | restore -rf - ... When you have dumped all your filesystems to properly mounted graft points under /mnt, update /mnt/etc/fstab and boot the new disk. _______________________________________________ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"