Strange as it may seem with all of the great new features in UCSM 1.4, this is one of my favorites.
To understand the impact, first look at the way disruptive changes were handled prior to this release. When changing a configuration setting on a service profile, updating service profile template, or many policies, if the change would cause a disruption to running service profiles (i.e. requiring a reboot), you had two options : yes, or no. When modifying a single profile, this wasn’t a big issue. You could simply change the configuration when you were also ready to accommodate a reboot of that particular profile. Where it became troublesome was when you wanted to modify an updating service profile or policy that affected many service profiles – your choice was really only to reboot them all simultaneously, or modify each individually. Obviously for large deployments using templates and policies (the real strength of UCS), this wasn’t ideal.
With UCSM 1.4, we now have the concept of a Maintenance Policy. The screenshot below is taken from the Servers tab:
Creating a Maintenance Policy allows the administrator to define the manner in which a service profile (or template) should behave when disruptive changes are applied. First, there’s the old way:
A policy of “Immediate” means that when a disruptive change is made, the affected service profiles are immediately rebooted without confirmation. A normal “soft” reboot occurs, whereby a standard ACPI power-button press is sent to the physical compute node – assuming that the operating system traps for this, the OS should gracefully shut down and the node will reboot.
A much safer option is to use the “user-ack” policy option:
When this option is selected, disruptive changes are staged to each affected service profile, but the profile is not immediately rebooted. Instead, each profile will show the pending changes in its status field, and will wait for the administrator to manually acknowledge the changes when it is acceptable to reboot the node.
The most interesting new option is the is the “timer-automatic” setting. This setting allows the maintenance policy to reference another new object, the Schedule.
Schedules allow you to define one-time or reoccurring time periods where one or more of the affected nodes may be rebooted without administrator intervention. Note that the Schedules top-level object is located within the Servers tab:
The only schedule created automatically by UCSM is the “default” schedule, which has one recurring entry to reboot all service profiles that reference a “timed-automatic” maintenance policy associated with the “default” schedule each day at midnight. This “default” schedule can be modified, of course.
Creating a user-defined schedule provides the ability to control when – and how many – profiles are rebooted to apply disruptive changes.
The One Time Occurrence option sets a single date and time when this schedule will be in effect. For example, if you wanted all affected profiles to be rebooted on January 18th at midnight, you could create an entry such as the following.
Once the date and time have been selected, the other options for the occurrence can be selected.
Max Duration specifies how long this occurrence can run. Based on the other options selected below it, it is possible that all service profiles may not be able to be rebooted in the time allotted. If this is the case, changes to those profiles will not take effect.
Max Number Of Tasks specifies how many total profiles could be rebooted by this occurrence.
Max Number Of Concurrent Tasks controls how many profiles can be rebooted simultaneously. If, for example, this schedule will be used on a large cluster of service profiles where workload can be sustained even while 5 nodes are unavailable, set this value to 5 and the reboots will occur in groups of that size.
Minimum Internal Between Tasks allows you to set a delay between each reboot. This can be set to ensure that each node rebooted is given time to fully boot before the next node is taken down.
The Recurring Occurrence option provides for the creation of a schedule that will run every day, or on a specific day, to apply disruptive changes.
This option has the same per-task options as the previous example.
Once you have created your maintenance policy and schedule (if necessary), the service profile or service profile template must reference the maintenance policy in order for it to have any effect. After selecting your service profile or template, the Actions window has an option to Change Maintenance Policy.
You may then select the Maintenance Policy you wish to use, or create a new one.
The service profile properties will now show that a maintenance policy has been selected.
In this example, a policy requiring user acknowledgement has been chosen. Now if any disruptive changes are made, the service profile will not reset until manually acknowledged by an administrator. Any time profiles are awaiting acknowledgement, a warning “Pending Activities” will be shown on the UCSM status bar.
Within the profile properties, a description of the pending changes will be displayed along with the “Reboot Now” option.
I hope this description of the new maintenance policies and schedules options was helpful. I’m very excited by all the new features rolling into UCS – it was a great system before, and it’s only getting better!
5 thoughts on “UCSM 1.4 : Maintenance Policies and Schedules”
So I have a question about this, specifically the usr-ack option… So if I have a dynamically updating service profile template with a maint policy of usr-ack, and individual service profiles linked to it (one for each of my ESX hosts), what’s the impact should I, for example, update the firmware package in the template? Is it the case that I can then individually ack each of the ESX host profiles, allowing each to reboot as I wish it, or is the acknowledgement on the service template, and I’m still facing the problem of all the ESX nodes linked to the template rebooting at the same time?
What I’m looking for is an easy firmware update plan that doesn’t require unbinding from the template so that I can individually control the reboot of blades. In a sense, I’m looking for a “update firmware package on next reboot of blade” option. Does the usr-ack get me there?
Acknowledgement would be at the individual service profile level, not the template. So yes, usr-ack gets you exactly what you’re looking for.
Just tested and it does in fact do as I want. Thanks!
Going back to comment #1.. I set that up on my UCS environment, and I can see some potential here to help upgrade the ESX server’s firmwares/bios.. but how can we get UCS to put the ESX server in maintenance mode first? It seems to just hit the power button on the server, and that takes down all the VM’s that were on it, causing them to basically power cycle before they boot up on another ESX host.
Ideally, I’d like to see the ability to run some script before a server goes down for maintenance.. it would need to take in some user definable arguments that are unique to the service profile like hostname, passwords, etc.. those would have to be defined separate from the SP template that the maintenance policy and subsequent maintenance pre-run script and post-run script are defined.
I’d have to test it to be sure, but I’m pretty sure that after receiving the soft power button press, ESX[i] will vMotion all running guests to other cluster members. Now, how long it’s willing to wait before just shutting down, I don’t know. Perhaps one of the more experienced readers can chime in.
To your specific point, though, there’s no way currently for UCS to directly interact with ESX or vCenter to do what you’re trying to do.