expand ZFS partition at the front

I have no idea how this happened but I have a ZFS pool where each disk in the pool has partition 2 allocated to ZFS. Partition 1 is a 2 GB swap space. I wanted ZFS to use the whole device.

The only way I can think of to fix the problem is to offline each vdev and replace it with that same drive, allowing ZFS to resilver each time.

Anyone have a better idea?
 
That's the only way.

Offline the disk.

Repartition the disk as needed.

"zpool replace" the disk in the pool.

Wait for it to resilver.

Rinse and repeat for each disk.

But, is it really worth the effort to reclaim 2 GB?
 
You're right, it's not worth the effort to reclaim 2 gig from each drive. But I'm not doing this on a practical setup. I'm just learning about ZFS and am curious if it would be possible.

Theoretically, it should be possible, right? Just move the root node and adjust the pointers on all of the other nodes.
 
Heh, we're still waiting on the mythical "Block Pointer Re-Write" feature that would allow something like that to work. :) Should be here any year now ... ;)
 
Back
Top