On 23/02/16 20:31, Barbu Paul - Gheorghe wrote:
Hello everybody,
I'm creating an ISO image this way:
$ rumprun-bake hw_generic app.bin app # app compiles fine and runs fine in QEMU
$ rumprun iso -I if,wm -W if,inet,dhcp -- app.bin 123
When I try to boot it into virtual box I get the error:
"rumprun: failed to mount rootfs from image"
Do you folks have any idea on how to fix this?
Let me explain first what happens. When I hacked up the "iso" support
for rumprun, the cheapest/quickest way was to include the config on the
root file system (i.e. the iso), mount the iso at runtime, and read the
config from the mounted file system.
The current model works in qemu because the block storage stack required
to mount the iso at runtime is present. IOW, qemu emulates the
supported devices. It also works when booting real hardware from a USB
stick because USB block storage support is present. It doesn't work in
virtualbox because the block storage stack for virtualbox is not
available. IOW, virtualbox does not emulate the supported devices, or
more to the point, we don't provide the required drivers. So, one would
have to componentize the necessary drivers available in NetBSD. Plenty
of people have expressed their interest in having the block storage
stack work on virtualbox (rumprun issue #24); nobody has contributed
their time or resources to making it happen, and that lack of actual
work is why it doesn't work as of now.
Looking long-term, once we get rid of the rumprun launcher, for
"embedded style" deployments (ones where you can't pass it via "command
line" e.g. via initrd), there needs to be a recipe/best practices for
the method. Probably baking the config into the binary would be a
reasonable option. Other options might be investigated as well.
The two issues mentioned above are largely orthogonal, and time/resource
contributions towards either are much appreciated.