Replace a single drive.

gunnahafta

Dabbler
Joined
Nov 5, 2018
Messages
32
I presently have a pool in my Freenas on a single 3TB drive. I want to replace this 3TB drive with a larger 8TB drive. I thought I could add the larger drive to the pool or maybe as a mirror. Then remove the older drive but will I then basically waste the extra 5TB?

How can I move from the old drive to the new drive without breaking all the paths, acl's, VM's, jails etc or waste the extra storage space?

And yes I am aware of the danger of having a single drive but its not critical data so I am not worried.
 

Alecmascot

Guru
Joined
Mar 18, 2014
Messages
1,177
Move the System Dataset to the boot-pool.
Attach the 8TB drive as a new pool.
Do a replication from the old pool to the new one.
Export both pools.
Import the 8TB pool changing its name to that of the old one.
Clear the dataset Read-Only setting and you should be good to go.
If you get stuck the old 3TB will still have all the data.
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
  • copy partition table from old drive to new drive gpart backup <old> | gpart restore <new>
  • attach new drive to vdev to build a mirror zpool attach <pool> <old> <new>
  • after resilvering detach old drive zpool offline <pool> <old>; zpool detach <pool> <old>
  • resize partition gpart resize -i <partition> <drive>
  • extend pool zpool online -e <pool> <drive>
 

gunnahafta

Dabbler
Joined
Nov 5, 2018
Messages
32
Tha
  • copy partition table from old drive to new drive gpart backup <old> | gpart restore <new>
  • attach new drive to vdev to build a mirror zpool attach <pool> <old> <new>
  • after resilvering detach old drive zpool offline <pool> <old>; zpool detach <pool> <old>
  • resize partition gpart resize -i <partition> <drive>
  • extend pool zpool online -e <pool> <drive>

Thanks. New drive arrives tomorrow will give it a go.
 
Top