void-mklive icon indicating copy to clipboard operation
void-mklive copied to clipboard

Migrating void to new laptop

Open lawmanuk opened this issue 2 months ago • 4 comments

Please consider a way to migrate void installation to new laptop, including luks btrfs system.

Or .. a way to create custom install iso based on current system

I keep getting uuid errors when simply copying over

Thanks

lawmanuk avatar Nov 24 '25 01:11 lawmanuk

Have you considered dding over?

Vaelatern avatar Nov 24 '25 03:11 Vaelatern

I have to copy gpt luks partition to a usb drive then to new laptop gpt partition.

Dd would copy empty space too which is the majority. It wouldn't copy gpt partition uuid when only copying a single partition.

Is there a more efficient and reliable way which just copies the data?

I backed up using borg which is useful to deduplicate btrfs snapshots.

But can't just restore this as uuid are different.

I tried calling the gpt partition uuid to match old laptop. This partially worked but grub failed when trying to decrypt luks.

Thx

lawmanuk avatar Nov 24 '25 09:11 lawmanuk

If you are putting on different partitions and filesystems then the uuids will mismatch. If you dd then data that's invisible to you the human but visible to the computer will be copied over.

Vaelatern avatar Nov 24 '25 16:11 Vaelatern

dd and resizing should be fine, as long as the two copies won't collide...

i guess only fstab and grub config should be modified, and then the generated stuffs of grub and dracut should be regenerated... (probably i can look up more precise info in case of need, but im in a mess and in a lack of time... :D ) otherwise i believe using labels are better than uuids if one considers how to distinguish those between machines/storages/filesystems, as uuids are used against moving targets like /dev/sdX... btw i made my own effort to make my uuids human readable and well-regulated :D

beyond topic(!!):

i started like: https://duckduckgo.com/?t=ftsa&q=hexadecimal+words&ia=web https://nedbatchelder.com/text/hexwords.html i took notes for those that could be used at all for anything

i wrote categories i could think about like machines/phones/storages/routers/others, with my things i should consider, including whatever i could imagine for the future, and then i took a different perspective and wrote this:

machines storages (independent or machine specific; 0 should be considered) systems (can share mac, ip, ssh keys etc) users (can be identical across systems) network interfaces (can see multiple networks) networks

then things started to settle like:

(edit: these turned into headings, i now hate markdown a bit more)

# positions inside uuid's:
#   1-8: purposes
#   9-20: owner identities
#
#   21: 16 layers
#   22-29 (free):
#     00000000
#     (XXX: these were planned, but aren't applicable/doable
#       22-27: names for btrfs subvols ("UUID_SUB"; lvm and zfs might still have uuids beyond pools)
#       28-29: 256 snapshots for each subvol)
#   30: 16 namespaces for device types (machine, phone, storage...)
#   31-32: 256 devices in types
# positions in fat volume id's:
#   1-3: purpose, "EF1" only ("3F1" could be used as an extension space, or even "EF2"...)
#   4-5:
#     namespaces instead of owner identity for myself and people i would care about
#     0-15 preserved for myself
#     16-255 (240) people i would care about and interact with
#   6: 16 namespaces for device types (4 affected from 5 used)
#   7-8: 256 devices/namespaces

where my identity is 1337-C0DE-B055 (NEVER use this, if u dont want to ever collide with me!!! :D ), and the purposes are like 5702A6E0 for gpt disk uuid, B105B007 for grub bios boot partition, EF1B10A7 (bloat isn't the best i could wish for, but i found nothing better) for /boot/efi, B007AB1E for /boot, ACAB67F0 (this one is fine X'D ) for luks+btrfs, 0FF10AD0 for swap, 5AFE5AFE for loopback luks containers before i realized it makes no sense at this level to use luks (but gocryptfs, or later cryfs can become better if it matures enough... i can even throw away my .kdbx garbages!)

so, i have tons of notes, im working out maximally fine-tuned basics with some wrapper functions to expose meaningful options in place of littering with fine-tuning options, i live on void live on 2 machines (i had to occupy my ssd of my console machine before my fs stuffs settled, but on the other machine (used via ssh almost exclusively after pressing power on), i can build the fs, and do much more than that without making an xmas tree from my console machine), i have codes for install/config whatever i need beyond the live system, and i have a bash framework ("bashin", not yet public, but will be public domain, maybe u can search for this for more info around mklive) with native tree structures (magic) for config, error handling, and a lot more, but then i jumped off from that and started to write the fine tuned essentials for my taste without the universality that my framework will provide... so these will eventually be tidied up and built together and then the world will be a better place... :D until then, this is my personal hell, but it always evolve here and there... :D

hippi777 avatar Nov 27 '25 12:11 hippi777