HOWTO: Single ZFS Drive to Mirror

Posted on the July 9th, 2007 under HOWTOs,Sys Admin,Technology / Computing by jglemza

My original installation of NexentaCP just had a single drive being used for the system installation. This can be verified here:
root@ufuk:~# zpool status syspool

  pool: syspool
 state: ONLINE
 scrub: none requested
config:

        NAME        STATE     READ WRITE CKSUM
        syspool     ONLINE       0     0     0
          c0d0s0    ONLINE       0     0     0

errors: No known data errors
I got my hands on another drive and I wanted to mirror this pool. To do this, issue the following command:
root@ufuk:~# zpool attach syspool mirror c0d0s0 c4d1s0
After a couple hours of resilvering, it’s all setup.
root@ufuk:~# zpool status syspool
  pool: syspool
 state: ONLINE
 scrub: none requested
config:

        NAME        STATE     READ WRITE CKSUM
        syspool     ONLINE       0     0     0
          mirror    ONLINE       0     0     0
            c0d0s0  ONLINE       0     0     0
            c4d1s0  ONLINE       0     0     0

errors: No known data errors
Done. Loving ZFS.
Bookmark and Share

Leave a Reply




XHTML::
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>