Linux - Virtualization and CloudThis forum is for the discussion of all topics relating to Linux Virtualization and Linux Cloud platforms. Xen, KVM, OpenVZ, VirtualBox, VMware, Linux-VServer and all other Linux Virtualization platforms are welcome. OpenStack, CloudStack, ownCloud, Cloud Foundry, Eucalyptus, Nimbus, OpenNebula and all other Linux Cloud platforms are welcome. Note that questions relating solely to non-Linux OS's should be asked in the General forum.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
I am using KVM to set up some test boxes. The host is Debian 7 and the client is Centos 6.4 and I have some questions about the best way to setup the virtual network. If it's easier I have no objection to making my host Centos...
I have bridging working and now would like to have a small simulated network. The end goal is to have some Virtual servers with static IP addresses to play with and set up a test/learning environment.
Right now when I set the client to static it can no longer communicate past the gateway, I can ping everything inside but nothing outside...
I have seen some guides and read some various suggestions but I am a little confused. Can I do this with Bridging alone? Should I set up a simulated router? Do I need to setup Virtio?
Which setup is closest what would be used on a production KVM box? Since the end goal is to learn, I don't need the whole answer just a nudge in the right direction. Although if I get stuck a guide might be nice
Last edited by matthekc83; 06-01-2013 at 07:33 PM.
Since you don't bring any of what you have actually done so far to the table, just some vague descriptions, I think it would be best to start with some basics.
First of all, how typical, bridged KVM VM networking works:
your VM is on all accounts a computer in it's own rights, no magic there, just emulation of every device you would have in a normal PC, including a network card.
This virtual network card is visible as a network card to the VM, and as a tap device (basically just a basic means of pushing data to other devices) on the host. So whenever the VM tries to use it's network card, the data is in fact in the tap device on the host.
On the host, this tap is plugged into a bridge, which in turn is plugged into a physical device, so here, the bridge acts as a virtual switch, into which real and virtual network cards get connected. Communication from the physical host to the network goes through a physical NIC, which is plugged into a real switch and onwards.
virtual NIC -> [tap] -> [bridge (virtual switch)] <- [host ethX] -> [rest of the network]
Once you understand how this works, and read up on bridges in general, you'll see that it's all very simple.
To get such a setup to work, all you need is an IP on the bridge (not the physical NIC it is plugged into, but the bridge itself) - which will be the IP the host uses, and an IP in the same network in the VM, with the same subnet and gateways and routes.
CentOS by default uses NetworkManager to set up ports. If you have a GUI that's the easiest way. If you want to edit the ifcfg-ethX scripts yourself, be sure to include NM_CONTROLLED="no" to prevent NM from having its way with them.