Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 26 Dec 2023 19:41:15 +0100
From:      Michael Grimm <trashcan@ellael.org>
To:        Miroslav Lachman <000.fbsd@quip.cz>
Cc:        freebsd-fs@freebsd.org
Subject:   Re: Howto migrate a FreeBSD cloud instance to another one without native FreeBSD support?
Message-ID:  <A54A7120-FEA8-4E67-9613-2C27A665B90F@ellael.org>
In-Reply-To: <cd7491fd-aec6-4023-9e93-4de3f59f6bbe@quip.cz>
References:  <4A6398FE-5DC1-45A1-85A9-7C5054CF5BF7@ellael.org> <cd7491fd-aec6-4023-9e93-4de3f59f6bbe@quip.cz>

next in thread | previous in thread | raw e-mail | index | archive | help
Miroslav Lachman <000.fbsd@quip.cz> wrote;
> On 26/12/2023 15:22, Michael Grimm wrote:

>> Hi,
>> I do run FreeBSD 14.0-STABLE instances in OVH's public cloud for some =
years already. Now, I do need to migrate my FBSD instances to new =
instances (old ones are no longer supported).
>> In the past one could create new instances running FBSD from the =
start, but OVH has removed that option. I do have used Ubuntu rescue =
systems in the past for my FBSD instances, thus I am familiar in using =
Ubuntu's OpenZFS functionality.
>> Sadly, OVH doesn't offer Linux systems installed on ZFS pools. Thus I =
do have to stick to Linux systems without.
>> Here are my questions regarding using Linux (Ubuntu) rescue systems:
>> # What would be the closest equivalent to FBSD's gpart tool?
>> gdisk, =E2=80=A6?
>=20
>> # Would it be possible at all to go for legacy booting of FBSD?
>> gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 1 ada0
>> # Or, would it be better/easier to consider UEFI booting instead?
>> rsync /boot/loader.efi to rescue system
>> # Are there other promising strategies for migrating feasible?
>=20
> I know nothing about OVH and almost nothing about what kind of FreeBSD =
setup you want to migrate (partitions, UFS vs ZFS etc.) but one thing I =
can imagine in you situation is creating everything from Linux rescue =
(partitions, formatting to UFS or ZFS, boot sector, rsync old FreeBSD =
instance to newly created...)

Sorry, if I haven't been clear enough:

#) I do want to migrate an existing ZFS pool (from one instance to =
another (zfs send | zfs receive).=20
   This I have done numerous times before.

#) New to me is the preparation of the target disk out of an =
Ubuntu/Linux rescue system.
   Namely, how to partition with Linux functionality (gdisk, cfdisk, =
=E2=80=A6) lacking gpart?
   Namely, which kind of booting to use (legacy versus EFI)?

> And the second is: you can prepare small minimalistic FreeBSD image in =
Bhyve / VirtualBox etc. make a copy of it with dd and then write it by =
dd to your new instance's disk with the help of Linux rescue system. =
Then you can reboot to a minimalistic FreeBSD system, enlarge =
partition(s), use growfs or zpool / zfs enlargement and then finally =
move data from the old instance to this new instance by rsync, or zfs =
send, or whatever tool you prefer.

Thanks for this info, very much appreciated.

Regards,
Michael=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?A54A7120-FEA8-4E67-9613-2C27A665B90F>