Although most datacenter admins regularly utilize pools for resources like WWNs or IP addresses, I find few fully utilizing the benefits of Cisco UCS dynamic server pools. You can create a static pool, but the true power and flexibility of server pools comes from creating dynamic pools. I’m going to show you the benefits of dynamic pools and show you how to create them via the GUI and via PowerTool. Let’s dive into pools.
Static pools are like manual labor
What happens when you add a new server or a new chassis filled with servers to you UCS domain? Nothing. You have to manually add the servers you want to each pool. Static pools require constant manual intervention.
Let UCSM do it for you
Wouldn’t it be great if you could create a pool of servers with local SSD and all the servers with local SSD would get added to that pool automatically? Wouldn’t it be great if any servers with local SSD you added to your domain at a later date would be automatically added to that pool?
Consider the picture of pools here. What if a server is a B200 M4 with lots of memory? Shouldn’t it go into both the B200 M4 pool and the high memory pool?
This brings us to the first warning: pools can overlap. Static pools can overlap. Dynamic pools can overlap.
A warning and a benefit
I just warned you that pools can overlap. Now I’m going to tell you overlapping pools are an asset. Consider these two pictures:
In both pictures, DEV and TEST have dedicated and shared servers. As the development cycle nears an end, it makes sense that TEST needs more servers and DEV needs fewer – so pools with overlap (shared resources) make sense.
Just be sure that you plan accordingly. Overlap is not always appropriate. The picture on the right, where PROD has its own non-overlapping pool of servers, more closely resembles how I would allocate my resources.
Let’s build a dynamic pool
There are three steps to building a dynamic pool. The first and second steps are obvious, but the need for a third step is not.
Step one: create a server pool
This is easy. Go to the “Servers” tab in UCSM, right-click on server pools, and select “Create Server Pool”. You provide a name and [optionally] a description. Don’t manually add any servers. You now have an empty pool and the next two steps will dynamically populate the pool for you.
Step two: set the criteria
If you’re going to let UCSM do the heavy lifting of putting the appropriate servers into a dynamic pool, you have to specify the criteria, which is called “server pool policy qualification” in the GUI. A qualification is something like:
- “servers with 16 cores”
- “servers with less than 64GB RAM”
- “servers with at least one solid state drive”
…and a “server pool policy qualification” is a way of defining a group of criteria.
This is a policy, so you’ll find it under Policies on the Servers tab in UCSM. In the screenshot below, I’m creating a new pool policy qualification with two criteria (qualifications): memory and storage. What you can’t see here is the detail behind each of these criteria. It’s really quite amazing how granular you can get in describing your requirements.
In order for a server to meet this group of criteria (a.k.a. “server pool qualification policy”), it must meet all of the qualifications (criteria) I specified. The memory qualification and the storage qualification must both be true.
Step three: link the pool to the criteria
You are probably wondering why there is a step three. Why doesn’t the server pool policy qualification I created above allow me to specify a pool? If it did, I would already be done, right? Why do I need a pool policy to link a qualification to a pool as shown below?
The pool policy makes dynamic pools more flexible because you can assign more than one qualification to a single pool. Let me show you two interesting use cases.
The first use case shows two sets of qualifications being mapped to the DEV pool. The picture below essentially says that a server must have more than 128GB of memory with two sockets and 16 cores – OR – it could be server model X with a chassis ID of 5.
How could something like this be useful? Let’s say that the development team has been using servers with 128GB of RAM, two sockets and 16 cores for a while and then another team donates an entire chassis full of servers to them. How does the development team make use of this new chassis full of servers that might have less than 128GB of RAM or fewer than 16 cores? They would create a second pool policy as shown above.
The second use case builds off of the first use case I just described. What if that donated chassis of servers was to be shared by the development and test teams? As shown below, they could use pool policy B to map a pool policy qualification to the DEV pool and then use pool policy C to map that exact same pool policy qualification to the TEST pool.
The result is that the development has a pool of servers and they share a subset of those servers with the test team.
Create dynamic pools faster
It’s certainly not hard to perform the three steps for creating dynamic pools using the UCS Manager GUI, but PowerShell and UCS PowerTool save time.
I’ll follow the same flow we followed in the GUI. First, I’ll create the pool. This is a really simple process. Remember that the description is optional, so this command could be even shorter. I assigned the output of this command (the actual pool that gets created) to the $MyPool variable so I can reference it later. You’ll see why.
> $MyPool = Add-UcsServerPool -Name vHosts -Descr 'hypervisor hosts'
Let’s verify that the pool was created and that it has no servers in it. You can see from the command and its output that the pool was created and is empty.
> Get-UcsServerPool | ft Name, Size, Descr -AutoSize Name Size Descr ---- ---- ----- vHosts 0 hypervisor hosts
The next step is to create the server pool qualification and then add one or more qualifications (criteria) to it. In this case, I’m looking for servers with at least 256GB of RAM and no local disk in chassis 2 or 3. Just like the previous step, I assigned the output of the creation command to a variable so I can reference it later.
> $MyQual = Add-UcsServerPoolQualification -Name vHostsQ > $MyQual | Add-UcsMemoryQualification -MinCap (256*1024) > $MyQual | Add-UcsStorageQualification -Diskless yes > $MyQual | Add-UcsChassisQualification -MinId 2 -MaxId 3
The final step is to create the server pool policy that links them together with a pool policy. Notice that the variables I created earlier come in very handy now. Let’s also check to make sure that our pool has some servers in it now.
> Add-UcsServerPoolPolicy -Name HiMem -PoolDn $MyPool.Dn -Qualifier $MyQual.Name > Get-UcsServerPool | ft Name, Size, Descr -AutoSize Name Size Descr ---- ---- ----- vHosts 9 hypervisor hosts
We can easily tweak our qualifications and see that the number of servers in the pool dynamically adjusts. Above we were looking for servers with at least 256GB of memory. What happens when we change that to 257GB or more?
> $MyQual | Get-UcsMemoryQualification | Set-UcsMemoryQualification -MinCap (257*1024) > Get-UcsServerPool | ft Name, Size, Descr -AutoSize Name Size Descr ---- ---- ----- vHosts 4 hypervisor hosts
Notice that the pool shrunk from nine servers to four servers when I changed the qualification to require more memory!
Remember that pools can overlap while keeping in mind that overlapping pools are powerful. Even if you never create an overlapping pool, I hope you’ll see the benefits of dynamic server pools and enjoy the administrative time saved.