Shim always uses 512 byte block size to fetch grub EFI binary
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 1.1k
- Forks
- 348
- PR merge metrics
- No merged PRs in 30d
Description
Shim uses a hard-coded 512 byte block size for the TFTP (netboot) request to download the grub EFI file:
https://github.com/rhboot/shim/blob/main/netboot.c#L325
This results in very poor performance transferring the file, especially over high-latency network connections (and compared to iPXE). It would be better to use the block size that was negotiated and used to transfer the shim EFI binary itself, which is often bigger (e.g. 1482 on a typical Ethernet segment).
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in netboot.c around line 325 and inspect how the block size is negotiated and retained while downloading the shim EFI binary. Trace the subsequent GRUB EFI TFTP request, then make it use the negotiated block size rather than a hard-coded 512 bytes. Done means the GRUB request uses that negotiated value, especially for high-latency transfers.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- networking
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 48/100