P2V FreeBSD 8.1

hello,
I'm trying to virtualize my FreeBSD 8.1 server.
I know virtualization pretty good so there is no problem on this side.
So I installed a fresh new full zfs FreeBSD on my ESXi. FreeBSD 8.1 RELEASE. Pools have same names each side.
It's booting and no problem there.
Then I tried with not much luck to rsync the existing server to the new VM. I tried to sync all outside /dev and /etc/fstab. When I boot that it starts ok then it cant mountroot. I get the mountroot prompt and when I enter zfs:zroot it wont work better than during the boot itself.
I check with fixit that my pool is there and ok and it is. Well was booting before rsync so no surprise.
I guess I'm transfering files that I should not transfer outside /dev and /etc/fstab.
When I do that on linux I also keep /proc, /sys, /boot and some other (lvm, ...) but I dont know enough FreeBSD/zfs to get the good list.
So, someone can point what I should not transfer or provide some tips for FreeBSD P2V ?
 
Did you zpool set bootfs=.... on other machine?

This is common pitfall for me :) I forget to set it, then need to reboot and fixit with fixit cd
 
killasmurf86 said:
Did you zpool set bootfs=.... on other machine?

This is common pitfall for me :) I forget to set it, then need to reboot and fixit with fixit cd

Well, no since both pools have same names.
I should ?
 
Do I understand you? You have 2x Virtual servers both have same zpool names?
On new server which doesn't boot you need to set bootfs.
 
Not exactly.
I have 2 servers, one physical and one virtual.
At start both servers boot and have same zpool names.
Then I rsync physical server onto virtual server but then the virtual server wont boot anymore.
 
Since you are going from zfs pool to zfs pool, and you want everything to be the same, why not use zfs send instead of rsync? See zfs() man page for details.
 
phoenix said:
Since you are going from zfs pool to zfs pool, and you want everything to be the same, why not use zfs send instead of rsync? See zfs() man page for details.
Well, basically because I didnt know how to use it and I use to P2V linux systems with rsync.
Anyway I managed to succeed in my virtualization.
I restarted the rsync transfering just directories that need to be transfered and avoiding some files like /etc/fstab.
Somehow it didnt complete, beeing stalled, when rsync the whole thing with --exclude-from so I transfered directory by directory and that was ok.
 
Back
Top