Patch Management Best PracticesEnda O'Connor, April 2008 IntroductionPatch management is a quite complex and involved topic. Unfortunately, there is no one patch management plan that fits all situations. Everyone must determine the plan that fits best with their own environment and business objectives. A plan should be reviewed periodically because the environment and business objectives change over time, new tools and practices evolve, and operating systems evolve. All of these changes require modifications to existing patch management plans. This article covers the following topics:
Patch ContentPeople most often associate patches with delivering bug fixes only, and while this might have been true in early Solaris releases, this has progressively ceased to be the case. With the advent of the Solaris 10 Operating System, patches are used for the following purposes:
Some features require the installation of new packages. These new packages are typically available only by installing or upgrading to a Solaris Update Release that contains the new packages. But any change to pre-existing code is always delivered in a patch. New functionality, such as ZFS and NewBoot, is delivered entirely by patches, enabling businesses to take advantage of the new functionality without having to upgrade to a newer release of the Solaris OS. So, Sun ships some new functionality in standard patches. Sun also ships new hardware support in patches for much the same reason that Sun ships new functionality, that is, the need to get support for such hardware to market quickly and yet maintain a stable release model going forward. This document goes through some basic scenarios for creating a patch management strategy for any given organization. Again, it must be stated that the strategies outlined here are only guidelines. Every organization is different in both environment and business objectives. Some organizations have specific guidelines on change management that must be adhered to when developing a patch management plan. Customers can contact Sun Services to help develop an appropriate patch management strategy for their specific circumstances. The four basic strategies outlined here are as follows:
We will discuss the tools most appropriate to each strategy, where to locate the patches or patch clusters to apply, and any useful information and tips that are appropriate to a given strategy. Note: Always make sure you apply the latest revision of the patch utilities patch first before adding any other patches. The patch utilities patch must be applied to the live system in all cases. In the rest of this document, it is always assumed that the latest patch utilities patch has been applied first. For the Solaris 10 OS, the patch utilities patches are as follows:
Log in to SunSolve, and then see the "Latest Patch Update" section on the SunSolve home page for a complete list of pre-requisite patches for each OS version that should be installed before applying other patches. Note: From the perspective of accessing patches, patches that address security issues remain free. So do patches that provide new hardware drivers. Customers must have a valid support contract to access most other Solaris patches, including the Solaris patch clusters, such as the Recommended Patch Cluster or the Sun Alert Patch Cluster. See Solaris Subscriptions or Sun Spectrum Service Plans for information on how to buy a Solaris Subscription (Solaris OS only) or Sun Spectrum (entire system) support contract. These support contracts entitle customers to access all patches, plus a wide range of additional support services. Also see the Solaris Subscriptions web page. Note: It is strongly advised that you read the Special Install Instructions for all patches prior to installing them. In some cases, the Special Install Instructions are updated after the patch has been released to SunSolve, in order to clarify issues surrounding the particular patch installation or to notify users of newly identified issues. Proactive Patch Management StrategyThe main goal in proactive patch management is to prevent unplanned downtime or, in other words, problem prevention. The idea behind proactive patching is that in most cases, problems that can occur have already been identified and patches have already been released. So, the problem becomes mainly one of identifying important patches from the user perspective and applying them in a safe and reliable manner. In all cases of proactive patching, it is assumed that the system is already functioning normally. Why patch a system that is functioning normally, since any change implies risk, which in itself implies downtime? As with any system that is functioning normally, there is always the chance that some underlying, known issue can cause a problem. Such issues can include the following:
Security issues are a good example of the value of proactive patching. Most security issues are latent issues, that is, they exist but are not causing issues yet. However, it is important to take proactive action to prevent such issues from being exploited. In comparison to reactive patching, which is explained in the Reactive Patch Management Strategy section, proactive patching, in general, implies more change as well as regularly scheduled maintenance windows. Sun strongly recommends that proactive patching be the strategy of choice in those situations where it is applicable. Proactive patching is recommended mainly for the following reasons:
Identifying and Downloading Patches That Are Appropriate for Proactive PatchingThe recommended way of tracking issues relevant to proactive patching is to register to receive Sun Alerts, which can be done on the SunSolve home page under the Sun Alerts section. This section also provides access to all recent Sun Alerts along with Sun Alert patch reports. It is highly likely that the patches identified will all be contained in the most recent Recommended Patch Cluster, which can be downloaded from SunSolve Patch Access page. Individual patches can be downloaded from the Patches and Updates page. Note: Both the Recommended and Sun Alert clusters contain only core Solaris OS patches. They do not contain patches for Sun Java Enterprise System, Sun Cluster software, Sun Studio software, or Sun N1, and they do not contain other non-Solaris OS patches that address security, data corruption, or system availability issues. Core Solaris Tools for PatchingThe recommended method of proactively applying patches is to use Solaris Live Upgrade. Solaris Live Upgrade consists of a set of tools that enable users to create an alternate boot environment that is a mirror copy of the current boot partition and then patch the newly created boot partition prior to making it live. Once patched, the new boot partition can be booted. The benefits of using Solaris Live Upgrade are the following:
If Solaris Live Upgrade is not applicable to the system being patched, it is recommended that the appropriate
patches are downloaded and all requirements are identified, and then the patches can be applied using only Solaris Live Upgrade might not be applicable under the following circumstances:
If Solaris Live Upgrade is being used, it can also be used to apply the Recommended Patch Cluster. One caveat is that you must pass the
#cd 10_Recommended #luupgrade -t -n be3 -O -t -s . ./patch_order The first When using Solaris Live Upgrade is not an option, the Recommended Patch Cluster can be installed using the The following is a basic example of running #patchadd -a -M <dir containing patches> The It is recommended that after the complete list of patches has been identified, the patches be installed one by one using just
Here is an example of using
#patchadd -q -a -M . |grep "Approved patches:" |sort -u \
|sed -e "s/Approved patches://g" > patch_order_file 2>&1
#Cat patch_order_file
120900-03 121333-04 119254-50
#for i in 'cat patch_order-file'
do
patchadd $i
done
In this While this method of applying patches (using just Note: The The information in this section describes how to use the core Solaris Live Upgrade and patch utilities to patch a system. Sun also has a range of higher-level patch automation tools. See the Patch Automation Tools section for more information. Proactive Patching on Systems With Non-global ZonesOn systems where there are non-global zones, patching can still be done using Solaris Live Upgrade. If you are already running the Solaris 08/07 OS, then Solaris Live Upgrade can be used to apply patches without any further issue. If you are running a Solaris 10 release prior to 08/07, you need to add the Solaris 08/07 Solaris Live Upgrade packages to the live system and then apply a list of patches that are required in order to get Solaris Live Upgrade working in an environment that has non-global zones deployed. The Solaris Live Upgrade Software: Minimum Patch Requirements document outlines the required patches and the process that must be followed to get Solaris Live Upgrade from the Solaris 08/07 release working on a pre-08/07 Solaris release. Note that the list of patches to apply to get Solaris Live Upgrade working in an environment with non-global zones is quite large, and they must be applied to the live running environment. But once this is done, Solaris Live Upgrade can be used to patch going forward, as normal, with all the benefits that Solaris Live Upgrade provides. If Solaris Live Upgrade is not an acceptable option, then Sun recommends that you use the same method outlined in the Core Solaris Tools for Patching section, that is,
identify all the patches required and use Pay particular attention to the
In such cases, the problem must be identified and rectified before patching can commence. In the case of systems that have non-global zones configured, it is recommended that you apply patches individually using just
Due to current issues with In the case of Reactive Patch Management StrategyBasically, reactive patching occurs in response to an issue that is currently affecting the running system and that needs immediate relief. The most common response to such a situation is usually to apply the latest patch or patches, which might be perceived as being capable of fixing the issue. These patches could be the latest Recommended Patch Cluster or one or more patches that appear to be appropriate. Unfortunately, even though this approach might work if the undiagnosed issue has already been root caused and a patch issued to fix the issue, if the approach does not work, you are often worse off than before you applied the patch or patches. There are two main reasons why this approach is fundamentally incorrect:
So Sun strongly recommends that even when you experience an issue that is affecting the system, you should spend time investigating the root cause of the issue. If a fix can be identified from such investigation, and that fix involves applying one or more patches, then at least the change is minimized to just the patch or set of patches required to fix the problem. Depending on the severity of the problem, the patch or patches that fix the issue will be installed at one of the following times:
Identifying Patches for Reactive PatchingIdentifying patches that are applicable in a reactive patching scenario can often be complex. In a lot of cases, depending on support, contact with official Sun Support channels will be initiated. But as a starting point, you should do some analysis. Some tools that are useful in starting this analysis might include the following, depending on the issue, though this is not an exhaustive list:
There is no one, standard way of analyzing an issue because each issue involves different choices. Using debug level logging (when appropriate) and examining various log files might also provide insight into the issue. Also, a proper recording system that records changes to the system should be considered, so that recent system configuration changes can be investigated as possible root causes. When providing data to Sun engineers, using Sun Explorer logs is strongly recommended, because this provides a good foundation on which to start an analysis of the system. Tools for Applying Patches in a Reactive Patching ScenarioIf a fix has been identified and a patch has been downloaded (see the Identifying and Downloading Patches That Are
Appropriate for Proactive Patching section for information on downloading patches), Sun recommends that users use Solaris Live Upgrade
to apply patches, when possible. If you need to apply the patch or patches immediately (or the issue impacts Solaris Live Upgrade itself),
you should first run If the system being reactively patched has non-global zones installed, you should apply all patches individually using
In addition to using the core Solaris Live Upgrade and patch utilities to patch a system, Sun also has a range of higher-level patch automation tools. See the section Patch Automation Tools for more information. Security Patch ManagementSecurity patch management requires a separate strategy, because it requires you to be proactive and yet it requires a sense of urgency. In other words, security fixes deemed relevant might need to be installed proactively before the next scheduled maintenance window. The recommended method of staying on top of security issues is to register to receive Sun Alerts, which encompasses receiving Security Alerts as well. To register to receive Sun Alerts go to the Subscribe to the Sun Alert Weekly Summary Report web page. There is also a security web site that contains all relevant information, plus lets you report an issue. You can also visit the Sun security community Security Blog, which has links to security Sun Alerts that are listed with most recent issue at the top. Tools for Applying Security PatchesThe same rules apply to applying security patches as to proactively or reactively applying patches. The recommended approach is to use Solaris
Live Upgrade; otherwise, use In addition to using the core Solaris Live Upgrade and patch utilities to patch a system, Sun also has a range of higher-level patch automation tools. See the section Patch Automation Tools for more information. Installing a New SystemProbably the best time to proactively patch a system is while it is being installed. This ensures that when the system boots, it has the latest patches installed and, therefore, avoids any known issues that are outstanding. It also lets you perform testing on the configuration in advance (if testing has been scheduled into the provisioning plan). In addition, it allows you to create a baseline for all installations. Patching during the installation phase requires that you use JumpStart. See example 3-5 in the Solaris 10 8/07 Installation Guide: Custom JumpStart and Advanced Installations for an example of applying patches. The following JumpStart profile examples might be of use:
Patches can also be applied using finish scripts, as shown in example 4-4 in Creating Finish Scripts. Patch Automation ToolsHere is a list of automated patching tools:
For More InformationHere are additional resources:
Comments (latest comments first)Discuss and comment on this resource in the BigAdmin Wiki
Unless otherwise licensed, code in all technical manuals herein (including articles, FAQs, samples) is provided under this License. |
| ||||