Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

There is so much different information out there about setting up a virtual machine but I'm at a lost where to start. My fundamental question is:

How do I virtually deploy a web server (complete with a unique set of users) on top of the headless machine that I'm running?

The things that make my particular system unique (i.e. makes it hard for me to find information via google):

  1. Server is wireless.
  2. Server doesn't run a GUI.

Most tutorials/howtos assume a wired connection and/or a GUI.

What I've Tried

  1. I've read documentation for libvirt, qemu, and kvm. I've also seen a number of tutorials that use ubuntu-vm-builder or qemu-img. I'm just not sure where to start. I'm not sure how to think about the entire stack: I think it looks like this: libvirt --controls--> qemu --controls--> kvm. But I'm not sure.
  2. I've turned on virtualization through the BIOS on my system.
  3. I've installed the qemu* and libvirt* packages.
  4. I've tried to run qemu-system-x86_64 ubuntu-server-12.04.iso with the downloaded server ISO. This didn't work.

Challenges I haven't found the answers to yet.

  1. What are the canonical steps to get a virtualized server running? Do you start with qemu-img? Or does the first step begin with ubuntu-vm-builder?
  2. How do you keep it running every time your physical server boots?
  3. One tutorial noted that you couldn't bridge off of a wireless card. Is this still true today?
  4. I don't understand how to edit /etc/network/interfaces. I use wlan0 as my primary networking interface so I'm a little tentative to mess with it since all the tutorials I've seen assume that I'm using eth0.
  5. All of the tutorials I've seen assume that I have a GUI running. I don't. How would I get the guest OS to blit to the video card (I have a video card, but Ubuntu Server just runs CLI)?
  6. There are a lot of filesystems available for using qemu-img. Which should I use?

There are a lot of questions stuffed into this one. Sorry, but the question I care about most is at the beginning. My preference is to not to have to install Xen or use Virtual Box.

share|improve this question
    
This is a great question and a lot of information. However, it doesn't fit the Q&A style for Ask Ubuntu. Could you please instead break your "answer" into a self answer below (everything after the break). That way you can later accept it as an answer and others can still provide answers or build upon your progress. FAQ About self-answering –  Marco Ceppi Jun 29 '12 at 19:59
add comment

1 Answer 1

I'm going to keep a running log of the progress that I've made so far. I'll clean this up later and post it as an answer if I succeed.

Day 1

  1. I'm mainly using this tutorial. Note that it was originally for 9.10 /and/ it assumes that the primary network interface is eth0. I'm using a wireless card as my primary interface. As a sidenote, I'm not sure that using libvirt is the best way to go. We'll see.
  2. It's true that bridging off a wireless card isn't supported out of the box. Here is a howto on how to get around that (note that this howto builds off another one). I've tried it but because I'm still trying to use libvirt to manage my VMs, I haven't verified that this workaround works.
  3. With regard to what the flow of control looks like, tuxradar has a pretty good article. Here's the diagram from that article: Virtualization.

Day 2

  1. I got my VM to boot. I ran vmbuilder --debug --verbose with this as my config file in /etc/vmbuilder.cfg. I ran the most basic partition setup. Use google to see what to put in the vmbuilder.partition file. This takes a long time and I couldn't figure out how to install apt-proxy. If you can install apt-proxy, I would do it.

  2. Still can't get networking to work. The guest OS can't see the host OS and vice versa.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.