[clue] Virtual networking problem

Matt Gushee matt at gushee.net
Sun Jun 1 18:57:22 MDT 2014


Hello, all--

Long time no post! Hope everybody's doing well.

So, I'm trying to figure out how to set up a virtual network on my
Arch Linux box. I'm planning to set up some VPS web servers, and want
to test out my automated configuration management procedures locally
before I go live (I'm using Ansible, by the way, though I don't think
that especially matters in this context). I believe I've found the
right tools for the job, but their documentation assumes background
that I don't have. I think the main problem is that I don't know the
right names for what I want to do with the network.

So, I need one or more virtual machines running FreeBSD. I'm okay on
this part: I've set up a VM using QEMU and installed FreeBSD 10.0.

And I need to be able to:

* Connect to the internet from each VM, so I can install software packages.

* Connect to the internet from the host machine--because I will need
to refer to various online docs as I go.

* Connect to each VM from the host machine via TCP/IP.

The host machine has a single wired Ethernet connection to my home
network, which is connected to the internet via DSL.

The tools I have found for setting up the network are vde2 and slirp.
I seem to have gotten the setup somewhat working, in that the BSD box
obtains an IP address from a virtual DHCP server, and a virtual
network device appears on the host machine. But there is no actual
connectivity. So, questions:

* I think what I want is a virtual TAP device. Is that right, or do I
need something else?

* How do I connect the virtual interface on the host machine to the
real, internet-connected interface?

* How do I determine what IP address to assign to the virtual
interface ... or does that not matter?

P.S.: I have the impression networking might be easier with VirtualBox
(and I've used it for other things in the past), but for some reason I
can't get the VirtualBox host modules to load; I also tried installing
VMWare player, and the installation failed. So unless one of those
makes the problem *a lot* easier, I think I'll stick with QEMU.

Thanks for any insights!

--
Matt Gushee


More information about the clue mailing list