I have several VMs which I know will never get VMware tools installed, so I want to remove them from the alarm. I managed to get the rule to work if I add "||(scope.get("name") == "LXACS001")" to the "VMW Virtual Machine VMware Tools" condition. However, I really don't want to setup 4 different conditions to the IF statement. Can somebody please tell me how I can use a wildcard (or perhaps there's a better way to do this)? I want something like: "||(scope.get("name") like "LXACS%")".
Thanks!!
Other way around: I want to look at all VMs that _don't_ start with "LXACS". I know the LXACS servers will always fail, so I don't want them getting alarms.
Excellent! I didn't know to do it in the scope section. I would have figured that it would be in the Condition section. I discovered the Scoping Query Editor, so I'm sure that I will use that heavily. Thank you very much!
Mind if I ask a follow-up question? What if the scope is on a different object? For example, the "VMW Virtual Machine Memory Swapping" rule has a scope of VMWVirtualMachineMemory. I have a VM that keeps triggering it due to not having VMware Tools (one of the VMs I mentioned above). I want to stop getting emails on those, so I want to add the same condition to the scope. If I change the scope of the rule from VMWVirtualMachineMemory to VMWVirtualMachine (like if I were to use the same scope as above), will the conditions/alarms break?
The same will work for VMWVirtualMachineMemory as it does for VMWVirtualMachine.
eg.. VMWVirtualMachineMemory where name ! like "LXACS%'
or you can be more specific like:
VMWVirtualMachineMemory where name != "LXACS-myVM"
That will tell it to exclude just LXACS-myVM.
-Larry
Just make sure to export the rules (backup the rules) now and then just in case.
You can do this via cmd line on the vFog server:
Open cmd prompt and cd intto the vfoglight\bin folder, then run the below command:
fglcmd -ussr foglight -pwd foglight -cmd util:configexport -f c:\rules.xml
Of course, change the user/password strings as needed. This create an xml file of the rules. It can be imported back in.
-Larry
lmurphy1
57 Posts
548
0
Posted June 14th, 2010 19:00
VMWVirtualMachine where name ! like "LXACS%"
-Larry