1. Shutdown source Guest DOM
2. Create snapshot of source guest DOM disk
zfs snapshot -r rpool/vdisks/gdom001/gdom001-disk0@clone
3. Send source snapshot to destination, destination pool and zfs can be redefined
On destination:
zfs create -V 100gb vpool/vdisks/gdom002/gdom002-disk0
On source
zfs send rpool/vdisks/gdom001/gdom001-disk0@clone | ssh dsthost zfs recv -F vpool/vdisks/gdom002/gdom002-disk0
4. Create new guest DOM with the disk cloned
# ldm add-domain gdom002
add whole core
# ldm set-core 1 gdom002
# ldm add-mem 32G gdom002
# ldm add-vnet vnet0 primary-vsw0 gdom002
# ldm add-vdsdev /dev/zvol/dsk/vpool/vdisks/gdom002/gdom002-disk0 gdom002_disk0@primary-vds0
# ldm add-vdisk disk0 gdom002_disk0@primary-vds0 gdom002
# zfs snapshot vpool/vdisks/gdom002-disk0@version_1
# ldm set-var auto-boot\?=true gdom002
# ldm set-var boot-device=disk0 gdom002
# ldm bind-domain gdom002
# ldm list-domain gdom002
# ldm start gdom002
No comments:
Post a Comment