# How can I delete a zpool (I have two)



## meteor8488 (Apr 4, 2013)

Hi all, 

My server has two zpools, one named HDD (6HDD raidz2), and one named SSD (2 X25E mirror). Now I need to replace use 2 480G 520 to replace the old X25E. How can I do that? I think I should delete the zpool SSD first, then shutdown, and add the new SSD. Am I right? Do I need to clean the information for the 2 X25E?


----------



## Savagedlight (Apr 4, 2013)

If you delete the zpool, you'll lose the data. If you want to replace the drives without losing data, this is what you do:

Read all of this and cross-reference with zpool(8) and possibly other sources before you start.
Enable autoexpand of the pool: `# zpool set autoexpand=on poolname`
Scrub the pool.
`# zpool scrub poolname`
wait for scrub to finish

Backup the data, to be on the safe side.
`# zpool detach poolname disk1`
Replace the drive
Partition new drive
`# zpool attach poolname drive2 newDrive1`
Wait for resilver to complete.
Repeat step 5 to 9 with the new drive


----------

