VMware Cloud Community
kalin-georgiev
Contributor
Contributor

DRS VM groups using Tags

I have a requirement to group all Red Hat VMs in my environment together and pin them to specific hosts within cluster. I was planning on using VM-to-Host DRS affinity rules, but I noticed that when creating the VM group, I only have the ability to filter by name. I was wondering if there is any way to create DRS groups using Tags, or alternatively by filtering based on OS-type.

0 Kudos
4 Replies
Nawals
Expert
Expert

There is no option to filtered with OS type. You have to select the respective VMs and added to the group.

NKS Please Mark Helpful/correct if my answer resolve your query.
0 Kudos
scott28tt
VMware Employee
VMware Employee

Moderator: Moved to vSphere Discussions


-------------------------------------------------------------------------------------------------------------------------------------------------------------

Although I am a VMware employee I contribute to VMware Communities voluntarily (ie. not in any official capacity)
VMware Training & Certification blog
0 Kudos
nachogonzalez
Commander
Commander

As it's been stated there is no option to create a VM-Host affinity rule based on OS.
You can do it by the following:
 
- Create tags for redhat vms --> then create rules based on tags
- Review your VM naming scheme to be descriptive (such as rh for redhat win for windows, etc) and create rules based on naming scheme.

If you have vRealize automation tags can be created at provisioning.

0 Kudos
lucasbernadsky
Hot Shot
Hot Shot

Hi there. Unfortunately there is no way to manage DRS rules by tag yet. But don't worry, I found an article with almost the same issue (It's written in german but chrome translator will do the job) https://mycloudrevolution.com/de/2017/04/19/drs-affinity-rules-by-tag/.I think PowerCLI is the way to go.

 

If you have vROps, then you can achive this with the "Business Intent Tag-Based VM placement" feature:

https://docs.vmware.com/en/vRealize-Operations-Manager/7.0/com.vmware.vcom.core.doc/GUID-1A585BE5-86...
Also, you can schedule the PowerCLI script execution using vRO (Which is free) or Cron jobs for linux, or scheduled tasks in windows