I recently had some similar issues.
If your EFI partition data is unrecoverable, you can boot into Windows install media, a Windows 10 disc or a flash drive with the Win 10 image flashed.
Once booted into the installation media:
Press Shift+F10 to open command prompt,
then execute the following commands:
sel disk # (replace # with the ...
From this answer on askUbuntu, I used TestDisk to recover the data in the deleted EFI partition.
I copied the Microsoft folder from /boot/efi/EFI in the deleted EFI partition and copied it to the same destination but in the new efi partition. And Voila! Windows Boot Manger showed up in the systemd-boot menu.
Normally, when a BIOS-style GRUB is installed into the MBR, it also occupies the first few blocks after the actual MBR block. But on a GPT-partitioned disk, the GPT partition table that same location, so an essential part of your pre-existing GRUB must have been overwritten by the new GPT partition table.
If the conversion was otherwise executed correctly, ...
Binary data buffer that is passed to the loaded image.
Longer description of search process
efibootmgr source contains a function which outputs EFI boot variables (file efibootmgr.c):
show_vars(const char *prefix)
const unsigned char *description;
The tool that creates the new partition also generates the GUID for it. fdisk uses the uuid_generate_random function from libuuid for that.
If you are interested in details, RFC 4122 describes UUIDs in more details and also includes description of algorithms to create them. (UUID and GUID are more or less synonyms, there are some differences, if you are ...