Moving Host to a new SSD

Hello,

my Host System has only a very small SSD 32GB and it is nearly full. I'm thinking about to migrate to a bigger one, but I don't want to reinstall my host.

My first thought was to use dd and than try to resize the partition afterwards. I did this on my raspberrypi and it worked well :D , but it there I'm running linux I and I don't know if I can do this on freebsd as well.

The second thought was to do a snapshot and install that snapshot on my new ssd. This sounds really cool ;-) , but I until now I only used zfs snapshots as a rollback point.

Does anyone has tried any of my solutions ? If you have a better one, please share it !
 
You shouldn't use dd(8) to clone a system to an SSD, since it interferes with TRIM. To add to what abishai said, my tool of choice is sysutils/zxfer, a shell script that turns zfs send and zfs recv into something a bit like rsync. As the simplest example, suppose you have two pools, oldpool and newpool. Running zxfer -FPdv -R oldpool/ newpool would copy all the contents of the source pool onto the destination pool with snapshots intact. If any of the properties in the new pool conflict with those of the datasets being copied, the properties of the destination pool will override those in the copied datasets. All other properties will remain intact. There's a flag you can use to change that behavior and copy all properties with the dataset if needed.
 
If it is possible to attach both SSDs to the system, you could temporarily create a mirrored zpool by using zpool attach <pool> <olddev> <newdev> Wait for resilvering to complete, and then zpool detach <pool> <olddev>. I did this once to upgrade the only drive in machine (with only two drive slots) from 250GB to a pair of 500GB drives (an old disk array using 500GB drives had been decommissioned...) It turned out later to be a bad move, as that old array was using SATA-I (1.5Gbps) 500GB drives.

The Dreamer
 
Back
Top