Here is the procedure formatted as clean, copy-pastable Markdown.
This procedure outlines how to create a bootable Windows 11 USB flash drive (or HDD/SSD) using the command line.
⚠️ WARNING: DATA LOSS This process involves formatting drives. Identify your device identifier correctly (e.g.,/dev/sdX). In the examples below, the device is/dev/sde. Do not copy/paste commands containing/dev/sdewithout verifying your specific drive identifier.
Download the ISO from Microsoft: https://www.microsoft.com/software-download/windows11
Verify the checksum (optional but recommended):
sha256sum Win11_English_x64v1.iso
# Example Output:
# 4bc6c7e7c61af4b5d1b086c5d279947357cff45c2f82021bb58628c2503eb64e Win11_English_x64v1.isoPlug in your USB drive. Use the following commands to find the correct device identifier (e.g., /dev/sdb, /dev/sdc, etc.).
lsblk
dmesg | tail -50Note: Run all following commands as root.
Wipe the existing filesystem signature:
# Replace /dev/sde with your actual device identifier!
wipefs -a /dev/sdeCreate the partition layout (GPT label, a FAT32 boot partition, and an NTFS install partition):
parted /dev/sdeInside the parted interactive prompt:
(parted) mklabel gpt
(parted) mkpart BOOT fat32 0% 1GiB
(parted) mkpart INSTALL ntfs 1GiB 100%
(parted) quit
Verify the layout:
parted /dev/sde unit B printCreate a mount point and mount the downloaded ISO image:
mkdir -p /mnt/iso
# Adjust the path to your ISO file location
mount /home/user/Downloads/Win11_English_x64v1.iso /mnt/iso/Format the first partition as FAT32, mount it, and copy the boot files (excluding the large sources folder).
mkfs.vfat -n BOOT /dev/sde1
mkdir -p /mnt/vfat
mount /dev/sde1 /mnt/vfat/
# Copy all files EXCEPT the 'sources' directory
rsync -r --progress --exclude sources --delete-before /mnt/iso/ /mnt/vfat/Create the sources directory and copy only the boot.wim file:
mkdir -p /mnt/vfat/sources
cp /mnt/iso/sources/boot.wim /mnt/vfat/sources/Format the second partition as NTFS, mount it, and copy the full contents of the ISO.
mkfs.ntfs --quick -L INSTALL /dev/sde2
mkdir -p /mnt/ntfs
mount /dev/sde2 /mnt/ntfs
# Copy everything (including the large install.wim inside sources)
rsync -r --progress --delete-before /mnt/iso/ /mnt/ntfs/Unmount all drives and ensure data is synced to disk.
umount /mnt/ntfs
umount /mnt/vfat
umount /mnt/iso
syncPower off the device (safely remove):
udisksctl power-off -b /dev/sde
Confirmed working with 25H2, thanks!