* [Qemu-devel] suggestion for the QEMU advent calendar
@ 2014-12-05 8:37 Fabian Greffrath
2014-12-08 10:14 ` Stefan Hajnoczi
0 siblings, 1 reply; 10+ messages in thread
From: Fabian Greffrath @ 2014-12-05 8:37 UTC (permalink / raw)
To: qemu-devel
Hi there,
thank you very much for the QEMU advent calender! What a neat idea, I
enjoy it very much.
I'd like to add one suggestion: GRUB Invaders [1]. This is a multi-boot
compliant kernel game that allows to play Space Invaders from within
GRUB, i.e. without an operating system. I especially recommend the
version [2] packaged in Debian which contains some extra patches.
Thank you for considering!
Best regards,
Fabian
[1] http://www.erikyyy.de/invaders/
[2] https://packages.qa.debian.org/i/invaders.html
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [Qemu-devel] suggestion for the QEMU advent calendar
2014-12-05 8:37 [Qemu-devel] suggestion for the QEMU advent calendar Fabian Greffrath
@ 2014-12-08 10:14 ` Stefan Hajnoczi
2014-12-08 15:54 ` Fabian Greffrath
0 siblings, 1 reply; 10+ messages in thread
From: Stefan Hajnoczi @ 2014-12-08 10:14 UTC (permalink / raw)
To: Fabian Greffrath; +Cc: qemu-devel
On Fri, Dec 5, 2014 at 8:37 AM, Fabian Greffrath <fabian@greffrath.com> wrote:
> I'd like to add one suggestion: GRUB Invaders [1]. This is a multi-boot
> compliant kernel game that allows to play Space Invaders from within
> GRUB, i.e. without an operating system. I especially recommend the
> version [2] packaged in Debian which contains some extra patches.
Thanks! I've added it to the list of ideas for the remaining slots.
If you have the time to create the image yourself, please let me know.
Stefan
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [Qemu-devel] suggestion for the QEMU advent calendar
2014-12-08 10:14 ` Stefan Hajnoczi
@ 2014-12-08 15:54 ` Fabian Greffrath
2014-12-08 16:03 ` John Snow
0 siblings, 1 reply; 10+ messages in thread
From: Fabian Greffrath @ 2014-12-08 15:54 UTC (permalink / raw)
To: Stefan Hajnoczi; +Cc: qemu-devel
Am Montag, den 08.12.2014, 10:14 +0000 schrieb Stefan Hajnoczi:
> If you have the time to create the image yourself, please let me know.
I'd love to, but how do I create an image with just GRUB and the game,
but no actual OS?
- Fabian
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [Qemu-devel] suggestion for the QEMU advent calendar
2014-12-08 15:54 ` Fabian Greffrath
@ 2014-12-08 16:03 ` John Snow
2014-12-08 16:54 ` Fabian Greffrath
0 siblings, 1 reply; 10+ messages in thread
From: John Snow @ 2014-12-08 16:03 UTC (permalink / raw)
To: Fabian Greffrath, Stefan Hajnoczi; +Cc: qemu-devel
On 12/08/2014 10:54 AM, Fabian Greffrath wrote:
> Am Montag, den 08.12.2014, 10:14 +0000 schrieb Stefan Hajnoczi:
>> If you have the time to create the image yourself, please let me know.
>
> I'd love to, but how do I create an image with just GRUB and the game,
> but no actual OS?
>
> - Fabian
>
>
>
I would use a boot environment, like the "try it out" mode of
Fedora/Ubuntu etc to get a working linux environment, create a /boot
partition on a smallish virtual hard disk, and install your packages as
needed.
If manually installing a bootable grub sounds gross, I would try a two
virtual disk approach where you put /boot on -hda and / on -hdb, and
just run through e.g. the Debian installation process and install your
grub packages as needed. Then once completed, you can use either the OS
installation or a boot disk to cull the OS entries from grub, then
delete the second virtual disk to leave you with a functioning grub stub.
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [Qemu-devel] suggestion for the QEMU advent calendar
2014-12-08 16:03 ` John Snow
@ 2014-12-08 16:54 ` Fabian Greffrath
2014-12-08 17:19 ` Stefan Hajnoczi
2014-12-09 9:28 ` Kevin Wolf
0 siblings, 2 replies; 10+ messages in thread
From: Fabian Greffrath @ 2014-12-08 16:54 UTC (permalink / raw)
To: John Snow; +Cc: Stefan Hajnoczi, qemu-devel
[-- Attachment #1: Type: text/plain, Size: 927 bytes --]
Am Montag, den 08.12.2014, 11:03 -0500 schrieb John Snow:
> If manually installing a bootable grub sounds gross, [...]
Actually, this turns out not to be necessary at all. After all, GRUB
Invaders is a multiboot-compliant kernel game and as such can be loaded
directly by means of qemu's -kernel parameter. Thus, the "run" script
would look like this:
qemu-system-i386 -kernel invaders.exec
Please find the kernel image attached. It is built from the Debian
sources found here:
https://packages.qa.debian.org/i/invaders.html
Hope this helps. If there are any further questions, please do not
hesitate to ask me.
- Fabian
PS: I am a bit shocked by the fact how complicated it is to install GRUB
on a disk image. And, John, even if the approach you outlined worked, I
guess GRUB will find its device.map puzzled when it will get rebooted
from inside an image file instead of an actual hard-drive partition the
next time.
[-- Attachment #2: invaders.exec --]
[-- Type: application/x-executable, Size: 6272 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [Qemu-devel] suggestion for the QEMU advent calendar
2014-12-08 16:54 ` Fabian Greffrath
@ 2014-12-08 17:19 ` Stefan Hajnoczi
2014-12-09 9:28 ` Kevin Wolf
1 sibling, 0 replies; 10+ messages in thread
From: Stefan Hajnoczi @ 2014-12-08 17:19 UTC (permalink / raw)
To: Fabian Greffrath; +Cc: John Snow, qemu-devel
On Mon, Dec 8, 2014 at 4:54 PM, Fabian Greffrath <fabian@greffrath.com> wrote:
> Am Montag, den 08.12.2014, 11:03 -0500 schrieb John Snow:
>> If manually installing a bootable grub sounds gross, [...]
>
> Actually, this turns out not to be necessary at all. After all, GRUB
> Invaders is a multiboot-compliant kernel game and as such can be loaded
> directly by means of qemu's -kernel parameter. Thus, the "run" script
> would look like this:
>
> qemu-system-i386 -kernel invaders.exec
>
> Please find the kernel image attached. It is built from the Debian
> sources found here:
>
> https://packages.qa.debian.org/i/invaders.html
>
> Hope this helps. If there are any further questions, please do not
> hesitate to ask me.
>
> - Fabian
>
> PS: I am a bit shocked by the fact how complicated it is to install GRUB
> on a disk image. And, John, even if the approach you outlined worked, I
> guess GRUB will find its device.map puzzled when it will get rebooted
> from inside an image file instead of an actual hard-drive partition the
> next time.
Thanks!
Stefan
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [Qemu-devel] suggestion for the QEMU advent calendar
2014-12-08 16:54 ` Fabian Greffrath
2014-12-08 17:19 ` Stefan Hajnoczi
@ 2014-12-09 9:28 ` Kevin Wolf
2014-12-09 9:44 ` Fabian Greffrath
1 sibling, 1 reply; 10+ messages in thread
From: Kevin Wolf @ 2014-12-09 9:28 UTC (permalink / raw)
To: Fabian Greffrath; +Cc: Stefan Hajnoczi, John Snow, qemu-devel
Am 08.12.2014 um 17:54 hat Fabian Greffrath geschrieben:
> PS: I am a bit shocked by the fact how complicated it is to install GRUB
> on a disk image. And, John, even if the approach you outlined worked, I
> guess GRUB will find its device.map puzzled when it will get rebooted
> from inside an image file instead of an actual hard-drive partition the
> next time.
As long as you don't say which version of GRUB, it's easy. Install GRUB
Legacy, copy stage[12] and menu.lst to the image and do this in the GRUB
shell:
device (hd0) $IMAGE_PATH
root (hd0,0)
install /boot/grub/stage1 (hd0) /boot/grub/stage2 p /boot/grub/menu.lst
Or boot from a floppy/CD with GRUB in the VM and run the same thing
without the "device" command.
Syslinux is relatively easy as well. Just avoid GRUB 2 if you want to
set up disk images from the host. I've done it before, but it's ugly...
Kevin
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [Qemu-devel] suggestion for the QEMU advent calendar
2014-12-09 9:28 ` Kevin Wolf
@ 2014-12-09 9:44 ` Fabian Greffrath
2014-12-09 9:51 ` Stefan Hajnoczi
0 siblings, 1 reply; 10+ messages in thread
From: Fabian Greffrath @ 2014-12-09 9:44 UTC (permalink / raw)
To: Kevin Wolf; +Cc: qemu-devel
Am Dienstag, den 09.12.2014, 10:28 +0100 schrieb Kevin Wolf:
> Syslinux is relatively easy as well. Just avoid GRUB 2 if you want to
> set up disk images from the host. I've done it before, but it's ugly...
Yep, I was talking about GRUB 2. However, in the meantime I have figured
out what to do in order to create a "minimal" booting image. After all
the image creation, partitioning, formatting, device mapping and finally
mounting you only have to call "grub-install" with the right parameters
(!), copy the actual kernel into the image and create a minimal grub.cfg
file.
By "right parameters" I meant that grub-install per default copies GRUB
2 in its entirety onto the image, including the whole menu system,
graphical support, file system drivers and localization, etc. This will
take up about 10MB, which is why I put the "minimal" word in quotation
marks. You can, of course, manually select which modules you want to
install, but this must be a perfect guess. In my simple case it worked
with '--install-modules="part_msdos ext2 multiboot normal" --locales=""'
passed to grub-install on the command line.
Anyway, it's easier to just boot the multiboot kernel image and be done
with it. ;)
Cheers,
Fabian
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [Qemu-devel] suggestion for the QEMU advent calendar
2014-12-09 9:44 ` Fabian Greffrath
@ 2014-12-09 9:51 ` Stefan Hajnoczi
2014-12-09 9:54 ` Fabian Greffrath
0 siblings, 1 reply; 10+ messages in thread
From: Stefan Hajnoczi @ 2014-12-09 9:51 UTC (permalink / raw)
To: Fabian Greffrath; +Cc: Kevin Wolf, qemu-devel
On Tue, Dec 9, 2014 at 9:44 AM, Fabian Greffrath <fabian@greffrath.com> wrote:
> Am Dienstag, den 09.12.2014, 10:28 +0100 schrieb Kevin Wolf:
>> Syslinux is relatively easy as well. Just avoid GRUB 2 if you want to
>> set up disk images from the host. I've done it before, but it's ugly...
>
> Yep, I was talking about GRUB 2. However, in the meantime I have figured
> out what to do in order to create a "minimal" booting image. After all
> the image creation, partitioning, formatting, device mapping and finally
> mounting you only have to call "grub-install" with the right parameters
> (!), copy the actual kernel into the image and create a minimal grub.cfg
> file.
>
> By "right parameters" I meant that grub-install per default copies GRUB
> 2 in its entirety onto the image, including the whole menu system,
> graphical support, file system drivers and localization, etc. This will
> take up about 10MB, which is why I put the "minimal" word in quotation
> marks. You can, of course, manually select which modules you want to
> install, but this must be a perfect guess. In my simple case it worked
> with '--install-modules="part_msdos ext2 multiboot normal" --locales=""'
> passed to grub-install on the command line.
>
> Anyway, it's easier to just boot the multiboot kernel image and be done
> with it. ;)
The multiboot image is fine.
10 MB for a boot loader? Just wow, at some point it's better to slap
a boot sector onto the Linux kernel and be done with it, kexec already
exists.
Stefan
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [Qemu-devel] suggestion for the QEMU advent calendar
2014-12-09 9:51 ` Stefan Hajnoczi
@ 2014-12-09 9:54 ` Fabian Greffrath
0 siblings, 0 replies; 10+ messages in thread
From: Fabian Greffrath @ 2014-12-09 9:54 UTC (permalink / raw)
To: Stefan Hajnoczi; +Cc: qemu-devel
Am Dienstag, den 09.12.2014, 09:51 +0000 schrieb Stefan Hajnoczi:
> The multiboot image is fine.
I think so.
> 10 MB for a boot loader? Just wow, at some point it's better to slap
> a boot sector onto the Linux kernel and be done with it, kexec already
> exists.
Well, it's a bit more than "just" a boot loader, but yeah:
$ du -h /boot/grub/
3,2M /boot/grub/locale
2,4M /boot/grub/i386-pc
2,3M /boot/grub/fonts
11M /boot/grub/
- Fabian
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2014-12-09 9:54 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-12-05 8:37 [Qemu-devel] suggestion for the QEMU advent calendar Fabian Greffrath
2014-12-08 10:14 ` Stefan Hajnoczi
2014-12-08 15:54 ` Fabian Greffrath
2014-12-08 16:03 ` John Snow
2014-12-08 16:54 ` Fabian Greffrath
2014-12-08 17:19 ` Stefan Hajnoczi
2014-12-09 9:28 ` Kevin Wolf
2014-12-09 9:44 ` Fabian Greffrath
2014-12-09 9:51 ` Stefan Hajnoczi
2014-12-09 9:54 ` Fabian Greffrath
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).