未知博客

使用grub2制作U盘引导iso

umount /dev/sdb1
dd if=/dev/zero of=/dev/sdb bs=512 count=1
fdisk /dev/sdb

Then to create the first exFAT partition;

第一个分区要是windows可以认得的,不然放在第二分区,windows认不得。exfat好处是可以放超过4g的文件

type n and then press enter to create a new p to create a primary 1 to create the first primary partition just press enter to start at the default sector type -50M to set the size minus 50M (if prompted to remove signature, press Y) t for enabling type 7 to set the partition type to exFAT

Now to create the second fat32 partition;

n to create a new p for primary 2 to create the second partition just press enter to start at the default sector then press enter once more to end at the default last sector t to enable type 2 to select the second partition 6 to set the type to fat a to make this partition active 2 again for the second partition w to write the information to disk and exit

mkfs.exfat -n USB /dev/sdb1
mkfs.vfat -F 32 -n BOOT /dev/sdb2
grub-install --target=x86_64-efi --efi-directory=/media/user/BOOT/boot/efi --boot-directory=/media/user/BOOT/boot --force --removable --no-floppy

from https://pendrivelinux.com/make-an-exfat-bootable-usb-flash-drive/