iPXE discussion forum

Full Version: INITRD Basics
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
When using "initrd" to download a file, how is that file accessible in UEFI context?

I was expecting to see a new file system device created, but I find no new devices. For example.

initrd http:/blahblah/disk_image.dsk
kernel http:/blahblah/bootx64.efi /efi/boot/

At this point, UEFI is able to find and execute bootx64.efi (an OS loader), but how do I locate the prior initrd of disk_image.dsk?

I expected to find a UEFI RAMdisk or new file system device created, but I am not seeing this.

Obviously the file disk_image.dsk is in memory somewhere, but how does my OS loader find it? If not via memory address and size, then through what protocol?

Is there a detailed description somewhere of what is actually happening when iPXE pulls images down?
I would probably start reading the wimboot sources, which finds all loaded files

But the linux kernel for example receives an argument telling it which filenames to load, I think this is mentioned in the FAQ
This turned out to be much simpler than it seemed. The downloaded file appeared not as a RAMdisk (hence, no new fs device) but as just a file in the default volume.
My mistake was thinking that because this was a disk image file, that an INITRD would create a UEFI disk. Nope... just a file.

UEFI FileIo was able to access the file by name. Since what I was looking for was it's address in physical memory, but it was stored as a file, it was just a matter of reading the file size, allocating memory for it, and reading the file into the allocated memory. Pass the address and size through to the booting OS and it was able to mount the disk image as a RAMdisk. Problem solved.
Reference URL's