Creating mirror from existing system

Following the steps for creating a mirror from disk...and running into an issue.

I have two disks /dev/ada0 and /dev/ada1.

Code:
root@subsonic:/usr/home/brodey # gpart show ada0
=>       34  156301421  ada0  GPT  (74G)
         34        128     1  freebsd-boot  (64k)
        162  146800512     2  freebsd-ufs  (70G)
  146800674    7815168     3  freebsd-swap  (3.7G)
  154615842    1685613        - free -  (823M)

I have free space and yet...

Code:
root@subsonic:/usr/home/brodey # gpart backup ada0 > table.ada0
root@subsonic:/usr/home/brodey # gpart backup ada0p2 > table.ada0p2
gpart: No such geom: ada0p2.
 
20.4.3 Creating a Mirror with an Existing Drive (added: using MBR)

This section makes no mention of the requirement for MBR except for the small indicator of using s1, s2, etc. It's been a while since I tickled the BSD side of things but I figured that since the handbook made no mention of MBR that there was a reason for it.

I have an existing hard disk with an operating install/deployed server. Can I achieve success with a GEOM mirror without having to re partition/reformat my disk?
 
See the introductory section: Metadata Issues.

It's not necessary to manually repartition the existing drive. Following those instructions, a one-drive MBR-partitioned mirror is created on the new drive. The data is copied over, then the old drive is added to the mirror. That last step will overwrite everything on the original drive, including the partitioning scheme. Make full backups first.

It's helpful to practice the process on a spare machine or VM.
 
Back
Top