NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: qemu segmentation fault



Victor Dorneanu wrote on December 16th:
 > I try to run:
 > 
 > $ qemu -cdrom /home/cyneox/tmp/debian-503-i386-netinst.iso -net nic -net tap
 > 
 > and get:
 > segmentation fault  qemu -cdrom
 > /home/cyneox/tmp/debian-503-i386-netinst.iso -net nic -net tap
 > 

The last few days I have been playing with QEMU and experienced the
same problem. By searching the internet I found one "solution":

# qemu -cdrom /home/cyneox/tmp/debian-503-i386-netinst.iso \
  -net nic -net tap,fd=3 3<>/dev/tap0

It will probably require root privileges to run to be able to access
/dev/tap0.


However this "solution" creates another problem when I try to create
a bridged network setup. My host OS is NetBSD v5.0, guest OS is Linux
Ubuntu v9.10, QEMU is v0.10.6nb1.

Host environment:
NIC: re0: 192.168.0.3
Default gateway: 192.168.0.1
Virtual NIC: tap0: 192.168.1.1

Guest environment:
NIC: eth0: 192.168.1.2
Default gateway: 192.168.1.1


First I prepare the Host OS:

# ifconfig tap0 create
# ifconfig tap0 192.168.1.1/24 up
# ifconfig bridge0 create
# brconfig bridge0 add re0 add tap0 up

Then I start QEMU

# qemu -cdrom ubuntu-9.10-desktop-i386.iso -m 256 \
  -net nic -net tap,fd=3 3<>/dev/tap0

In the Guest OS I do:

# ifconfig eth0 192.168.1.2/24 up
# route add default gateway 192.168.1.1

From the Host OS I can now ping both 192.168.1.1 and 192.168.1.2.

From the Guest OS I can now ping 192.168.1.1, 192.168.1.2 and
192.168.0.3 but not 192.168.0.1. Also I can not get access to
the internet via the Host OS default router, no matter how I
configure the /etc/resolv.conf or the routing table of the Guest OS.

If I place the Guest OS on the same net as the Host OS by doing:

# ifconfig eth0 192.168.0.251/24 up
# route add default gateway 192.168.0.1

I am able to reach the internet from the Guest OS, but not
192.168.1.1, even though I don't have any use for that :-)

But I don't really want to have the Guest OS on the same net as the
Host OS.


Can anybody tell me how to configure the networks, so the Guest OS is
on another net than the Host OS and on the same time is able to ping
both the Host OS (192.168.0.3), the default router (192.168.0.1) as
well as the external internet (e.g. www.netbsd.org/204.152.190.12)?


Happy New Year
  Ib-Michael
-- 
Email at home: i.m.martinsen(at)gmail.com
Running NetBSD/i386 v5.0


Home | Main Index | Thread Index | Old Index