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.
Notices
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.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi all - I'm looking to set up a home lab with more than a few CentOS VMs at my fingertips.
I'm planning as using KVM as my hypervisor because of it's relatively small footprint, but regardless of the hypervisor, I'm curious on how many VMs I will be able to squeeze out of the server I'm going to build. Again, this is a home lab, so these VMs would not be running many intensive applications, but mostly for playing around and getting experience setting up/configuring LDAP, DNS, and other infrastructure and their clients.
I'm looking at building a barebones server and from what I've read the VMs will be mostly constrained by CPU. I'm looking at the newer quad-core i5s or i7s. These VMs will probably be 1 CPU x 2GB/4GB VMs, so I'm not planning on overloading the VMs with CPUs.
My question is how many CentOS VMs would I realistically be able to run? Is there a rule of thumb for how many VMs per core?
Not anything to do with vm per cpu/core from my experience. More real cores helps as most vm's are fully smp up to some number of cores. Like 32 or 64, something like that. I almost never assign to core/cpu. I let the system do what it needs to. If you need to limit then you can assign cores or use other cpu tools to limit.
Kind of boils down to clicks. There are only so many to go around.
I tend to find other resources drag the system down way before cpu fails. You can't easily share one hard drive on 100 vm's. Same for memory, you tend to run out of it pretty fast. You don't really want to use swap as it further kills the system. Cpus are used in almost every transaction so it does count.
Some of the versions of the core i7 are made more for server work. I think the older 3770K was one of them. The Xeon's are made for this task usually. If you like, Opterons are used also.
I have a small development core i7 and ssd that might run 3 or 4 hard running vm's no problem. Maybe 20 or 30 small servers just sitting around would work. I think you'd run out of other stuff way before cpu is the issue.
You would want to get new hardware that allows the best use of vm's if possible. Not all people need advanced features like adding on pci cards and usb.
If I had a choice of the faster cpu and less memory or a bit slower cpu and a lot of ram, I'd go with the more ram option since it is pretty cheap. Ram is fast. Tends to beat out multiple drives/raid in my uses.
I'd realistically like to run ~15 at one time. Again this is just a lab environment, so they would not all be spun up at the same time around the clock, but I would definitely like the flexibility to be able to do so.
I'll have to look at the newer i7s. I'm hoping that my disk usage or memory won't be constrained since I'm going to run the hypervisor/VMs on SSD and will put in at least 16GB of memory.
For a simple test, you should be able to run 200 maybe on a good server. A good home system should be able to run 20 I'd think. This is again all tied to "It really depends on what they are doing." as jpollard states.
You may also find limit is backplane speed, networking speed. Imagine cutting up your system into 20 or more pieces. What do you have left and how much is host taking? The pieces could get pretty small.
You better be careful about what a "good server" is.
I've seen no more than 20 VMs on a 32 core server with 64GB of memory. After that things get dicy. Yes, some of those VMs were assigned 2 CPUs rather than one.
I have a dual quad, with 8 GB of memory, but I don't want to run more 4 VMs (could do a total of about 5), but I see the system start slowing down.... Yes, it is partially disk I/O limited... but the host system has to deal with memory allocations from 3 (and each has only 1G of memory).
When all three are active, things can slow down - it seems normal most of the time, but there are periods of activity (likely cron based) that get in sync. At these times all four systems kick off administrative tasks at the same time - and the system as whole slows down for 3-5 seconds.
It also makes a difference if you are running a GUI at the same time... (LOTS of memory pigs there). And if the VMs are also running a GUI...
This, as usual depends on the actual loads. A busy server VM is better off without overallocation, and even with HT off, while a VDI load can easily go up to 1/10 or 1/15 ratio. In any case, if you are building the host yourself, I doubt CPU will be the bottleneck, it's more likely to be the disk subsystem
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.