[Top][All Lists]

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

Re: [Qemu-discuss] Cannot connect to network

From: Aleksei
Subject: Re: [Qemu-discuss] Cannot connect to network
Date: Fri, 7 Oct 2016 22:33:26 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.3.0

Hi Jerry,
You didn't specify network options in qemu command, so it created a default SLIRP network for your Debian guest. If you can access internet from Ubuntu, it's weird that you can't access it from Debian - I don't know why. Can your Ubuntu VM access internet regardless of which host interface is up (wireless/Ethernet)?
See here for available Qemu networking options: http://wiki.qemu.org/Documentation/Networking#User_Networking_.28SLIRP.29

If you want Debian VM to be on the same network as your host, like Ubuntu does, you can set up a bridge in Ubuntu, specify Ubuntu's NIC as a slave and have Qemu tap into it as well. It will be a tricky "layered bridging" setup, but I think it'll work. See here for info on creating bridges in Ubuntu https://help.ubuntu.com/community/NetworkConnectionBridge

Hope this gives you enough pointers to at least get started.

--Regards, Aleksei

From: Jerry Stuckle
Sent: Friday, October 07, 2016 7:49PM
To: Qemu-discuss
Subject: [Qemu-discuss] Cannot connect to network
Hi, all,

First of all, I will admit I'm a programmer, not a Linux administrator,
so the problem can be anywhere.  But I strongly suspect it's in the way
I'm setting up QEMU.

Here's the setup.  Main system is Window 7.  Underneath that, I am
running Ubuntu in VirtualBox.  This is working OK; I have two
NICs on the machine (wired and wireless, only one active at any one
time); VirtualBox is set up to bridge two virtual NICs to the two real
NICs, and the appropriate one is active in Ubuntu and gets an IP address
from the DHCP server.

Running QEMU 2.5.0 (the latest available in Ubuntu) I'm trying to bring
up a Debian system with:

qemu-system-arm -m 1024M \
		-sd /export/armhf.qcow2 \
		-M vexpress-a9 \
		-cpu cortex-a9 \
		-kernel /export/boot/vmlinuz \
		-initrd /export/boot/initrd.img \
		-append "root=/dev/mmcblk0p2"

This works fine, except the ethernet port (eth0) gets an ip address of instead of one from our intranet and can't access anything on
the intranet or the internet.  (The interface is defined in Debian for
DHCP on eth0).

Right now I need to be able to connect and update the Debian system.
Eventually I will need other outbound services also, to connect to both
intranet and internet systems.

I will also eventually need to be able to connect into this system
(multiple ports/processes).  I know I can use hostfwd, but I'd much
rather have the guest system allocated an ip from our intranet.

Does anyone have a suggestion as to what I'm doing wrong, and how I can
correct it?  Hours of searching on the internet have turned up very little.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]