此内容没有您所选择的语言版本。

Chapter 3. Monthly Patching Example


This chapter explains how to use Satellite to deploy errata to systems each month. In this example, we assume that we are patching systems in March of 2016.

Note

This procedure replicates the functionality of the spacewalk-clone-by-date command that was present in Satellite 5, and was described in this document written by Rich Jerrido: Satellite 5.6 Errata Management Guide. The command-line tool hammer is used in Satellite 6 to perform the same functions that the spacewalk-clone-by-date command performed in Satellite 5.

3.1. Defining a Content View to Filter Errata

In this procedure, we create a Content View, add a filter to the Content View to include the errata in the Content View, and then restrict the filter by date by means of a filter rule.

  1. Create a Content View.

    # hammer -p PASSWORD content-view create --name='test_cv' --organization="Default Organization"
    Copy to Clipboard Toggle word wrap
    Note

    The previous command passes the password in plaintext. This method is included in this guide for the sake of customers who are used to this method of authentication, but a more secure method of storing passwords, involving the storage of the password in a .yml file, is recommended to our customers and is to be found here: Authentication in the Hammer CLI Guide.

  2. Create a filter for the errata.

    # hammer -p PASSWORD content-view filter create --name='test_filter' --organization="Default Organization" --content-view='test_cv' --type=erratum
    Copy to Clipboard Toggle word wrap
  3. Create the filter rule with the date.

    In this example, the date is 30 Mar 2016. This rule means that all errata on or after 30 Mar 2016 will be excluded.

    # hammer -p PASSWORD content-view filter rule create --content-view='filter_test'  --organization="Default Organization"  --content-view-filter='my-filter' --start-date=2016-03-30  --types=security,enhancement,bugfix
    Copy to Clipboard Toggle word wrap
  4. Promote the Content View to the lifecycle environment so that the errata in it are available to that lifecycle environment:

    $ hammer content-view version promote
      --content-view cv_name \
      --organization-label="Default Organization" --to-lifecycle-environment env_name
    Copy to Clipboard Toggle word wrap
  5. Use the following command to add a repository to a Content View without clobbering the existing list of repositories that have been added to that Content View:

    $ hammer content-view add-repository --organization-label org_label --name cv_name --repository-id repo_ID
    Copy to Clipboard Toggle word wrap
  6. Apply the errata to the host, using the commands in the Hammer CLI Guide:

    $ hammer host errata apply --host <hostname> --errata-ids <erratum_ID1>,<erratum_ID2>...
    Copy to Clipboard Toggle word wrap

    For more detail on commands that apply errata to hosts, see Applying Errata to a Content Host in the Hammer CLI Guide.

返回顶部
Red Hat logoGithubredditYoutubeTwitter

学习

尝试、购买和销售

社区

关于红帽文档

通过我们的产品和服务,以及可以信赖的内容,帮助红帽用户创新并实现他们的目标。 了解我们当前的更新.

让开源更具包容性

红帽致力于替换我们的代码、文档和 Web 属性中存在问题的语言。欲了解更多详情,请参阅红帽博客.

關於紅帽

我们提供强化的解决方案,使企业能够更轻松地跨平台和环境(从核心数据中心到网络边缘)工作。

Theme

© 2025 Red Hat