Annotated edit history of
QemuNotes version 3 showing authors affecting page license.
View with all changes included.
Rev |
Author |
# |
Line |
1 |
AlastairPorter |
1 |
Here is how IanMcDonald is getting qemu running Linux. |
|
|
2 |
|
|
|
3 |
Create a disk image like: |
|
|
4 |
<verbatim> |
|
|
5 |
qemu-img create file1.img 5G |
|
|
6 |
</verbatim> |
|
|
7 |
which creates an image of 5 Gigabyte. |
|
|
8 |
|
|
|
9 |
Start qemu as follows: |
|
|
10 |
<verbatim> |
|
|
11 |
qemu -boot d -cdrom /dev/cdrom -hda hd.img |
|
|
12 |
</verbatim> |
|
|
13 |
|
|
|
14 |
Install the operating system. And then start qemu as below: |
|
|
15 |
<verbatim> |
|
|
16 |
qemu -hda hd.img -boot c |
|
|
17 |
</verbatim> |
|
|
18 |
|
|
|
19 |
However this created problems getting files in and out so better to create a loopback file system. For more on this see UserModeLinux. |
2 |
AlastairPorter |
20 |
|
|
|
21 |
!!Qemu and networking |
|
|
22 |
Qemu can present a network device to the guest operating system via tuntap.%%% |
|
|
23 |
You should boot it like: |
|
|
24 |
<verbatim> |
|
|
25 |
qemu -boot c -hda hd.img -net nic,model=ne2k_pci -net tap,ifname=tap0,script=/path/to/tunconfig |
|
|
26 |
</verbatim> |
|
|
27 |
|
|
|
28 |
the file tunconfig should contain something like: |
|
|
29 |
<verbatim> |
|
|
30 |
#!/bin/bash |
|
|
31 |
/sbin/ifconfig ${1##/*/} 192.168.1.1 |
|
|
32 |
</verbatim> |
|
|
33 |
|
|
|
34 |
The above command appears to create an NE2K device at address 0xc100, irq 10. |
3 |
AlastairPorter |
35 |
|
|
|
36 |
!! Hardware information |
|
|
37 |
Qemu has a built in console which you can use to get system information.%%% |
|
|
38 |
To access the console, use Ctrl-Alt-2 |
|
|
39 |
|
|
|
40 |
Some commands that may be useful: |
|
|
41 |
<verbatim> |
|
|
42 |
show pci |
|
|
43 |
show network |
|
|
44 |
</verbatim> |