Questo contenuto non è disponibile nella lingua selezionata.

Chapter 8. Managing Errata


Software packages in Red Hat products are subject to updates, referred to as errata, that are released at regular intervals as well as asynchronously. This section shows how to inspect and apply errata using hammer. For web UI equivalents of the following procedures see Managing Errata in the Content Management Guide.

8.1. Inspecting Available Errata

To view errata that are available for all organizations, issue the following command:

$ hammer erratum list
Copy to Clipboard Toggle word wrap

Example 8.1. Filtering Errata

The hammer erratum list command provides numerous options for filtering and ordering the output list. For example, to find an erratum that contains a specific security fix, issue:

$ hammer erratum list --cve CVE-2014-0453
Copy to Clipboard Toggle word wrap

The following command displays applicable errata for the selected product that contain the specified bugs ordered so that the security errata are displayed on top:

$ hammer erratum list \
--product-id 7 \
--search "bug = 1213000 or bug = 1207972" \
--errata-restrict-applicable 1 \
--order "type desc"
Copy to Clipboard Toggle word wrap

For more information on syntax used in the --search option, see Inspecting Available Errata in the Content Management Guide. For more information on filtering options implemented in hammer, see the output of hammer erratum list --help.

To view details of a specific erratum, issue the following command:

$ hammer erratum info --id erratum_ID
Copy to Clipboard Toggle word wrap

Replace erratum_ID with a unique identifier of the erratum found in the output of the hammer erratum list command. You can identify errata also by name and repository name, see the output of hammer erratum info --help for details.

8.2. Applying Errata to a Host

To list errata available for a host, issue the following command:

$ hammer host errata list --host hostname
Copy to Clipboard Toggle word wrap

To apply selected errata to the host, issue the following command:

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

Example 8.2. Applying All Available Errata to a Host

The following Bash script applies all errata available to a host (auth01.example.com):

HOST="auth01.example.com"
for i in $(hammer --csv host errata list --host $HOST | grep -vi '^ID' | awk -F, {'print $2'})
do
  hammer host errata apply --host $HOST --errata-ids $i
done
Copy to Clipboard Toggle word wrap

Example 8.3. Applying a Security Advisory

This example shows how to apply a security fix to hosts using hammer:

  1. Find the erratum that contains a fix for a selected issue (CVE-2015-3238):

    $ hammer erratum list --cve CVE-2015-3238
    -------|----------------|----------|------------------------------
    ID     | ERRATA ID      | TYPE     | TITLE
    -------|----------------|----------|------------------------------
    f30e66 | RHSA-2015:1640 | security | Moderate: pam security update
    -------|----------------|----------|------------------------------
    Copy to Clipboard Toggle word wrap
  2. Verify if the security erratum (RHSA-2015:1640) is applicable for your host (auth01.example.com):

    $ hammer host errata list \
    --host auth01.example.com \
    --search "RHSA-2015:1640"
    Copy to Clipboard Toggle word wrap
  3. Apply the erratum to the host:

    $ hammer host errata apply \
    --host auth01.example.com \
    --errata-ids "RHSA-2015:1640"
    Copy to Clipboard Toggle word wrap

You can use the following Bash script to apply a security erratum (for example RHSA-2015:1640) to all hosts where it is applicable:

ORG="ACME"
RHSA="RHSA-2015:1640"

for i in $(hammer --csv host list --organization $ORG | grep -vi '^ID' | awk -F, {'print $2'})
do
  hammer host errata apply --host $i --errata-ids $RHSA
done
Copy to Clipboard Toggle word wrap

To see if errata were applied successfully, find the corresponding task in the output of the following command:

$ hammer task list
Copy to Clipboard Toggle word wrap

To review the state of a selected task, issue the following command:

$ hammer task progress --id task_ID
Copy to Clipboard Toggle word wrap

8.3. Applying Errata to a Host Collection

To apply selected errata to a Host Collection, enter a command as follows:

$ hammer host-collection erratum install \
--errata "erratum_ID1,erratum_ID2,..." \
--name "my-collection" --organization $ORG
Copy to Clipboard Toggle word wrap

This command is available in Red Hat Satellite 6.2.8 or later.

Torna in cima
Red Hat logoGithubredditYoutubeTwitter

Formazione

Prova, acquista e vendi

Community

Informazioni sulla documentazione di Red Hat

Aiutiamo gli utenti Red Hat a innovarsi e raggiungere i propri obiettivi con i nostri prodotti e servizi grazie a contenuti di cui possono fidarsi. Esplora i nostri ultimi aggiornamenti.

Rendiamo l’open source più inclusivo

Red Hat si impegna a sostituire il linguaggio problematico nel codice, nella documentazione e nelle proprietà web. Per maggiori dettagli, visita il Blog di Red Hat.

Informazioni su Red Hat

Forniamo soluzioni consolidate che rendono più semplice per le aziende lavorare su piattaforme e ambienti diversi, dal datacenter centrale all'edge della rete.

Theme

© 2025 Red Hat