Red Hat Satellite Content View package and errata reports

Red Hat Satellite 6.10.7 login
https://twitter.com/UnixSysAdmin/status/1550066522785255424

In order to produce a report of packages contained in a Content View in Red Hat Satellite, the following hammer command can be used:

hammer --csv package list --content-view CV-Name --content-view-version x.y --organization ACME --per-page N

where CV-Name is the name is the name of the content view, x.y is the content version (such as 1.0, 2.0, etc) and N is the number of records that you wish to return. For example, a content view with the name RHEL-Latest at version 12.0 containing 36000 RPMs, the following would be used:

hammer --csv package list --content-view RHEL-8-Latest --content-view-version 12.0 --organization ACME --per-page 36100

I’ve added an extra 100 to the ‘–per-page’ argument to make sure that everything is included.

The output will be a CSV with output similar to the following:

# hammer --csv package list --content-view RHEL-8-Latest --content-view-version 12.0 --organization ACME --per-page 5
Id,Filename,Source RPM
245326,389-ds-base-1.4.0.20-7.module+el8+2750+1f4079fb.x86_64.rpm,389-ds-base-1.4.0.20-7.module+el8+2750+1f4079fb.src.rpm
242490,389-ds-base-1.4.0.20-10.module+el8.0.0+3096+101825d5.x86_64.rpm,389-ds-base-1.4.0.20-10.module+el8.0.0+3096+101825d5.src.rpm
262730,389-ds-base-1.4.1.3-7.module+el8.1.0+4150+5b8c2c1f.x86_64.rpm,389-ds-base-1.4.1.3-7.module+el8.1.0+4150+5b8c2c1f.src.rpm
283599,389-ds-base-1.4.2.4-8.module+el8.2.0+5959+cfcaedbd.x86_64.rpm,389-ds-base-1.4.2.4-8.module+el8.2.0+5959+cfcaedbd.src.rpm
295135,389-ds-base-1.4.2.4-10.module+el8.2.0+7749+4a513fb2.x86_64.rpm,389-ds-base-1.4.2.4-10.module+el8.2.0+7749+4a513fb2.src.rpm

It’s also possible to report on the errata content within a view as follows:

# hammer --csv erratum list --content-view RHEL-8-Latest --content-view-version 12.0 --organization ACME --per-page 36100

Sample output:

# hammer --csv erratum list --content-view RHEL-8-Latest --content-view-version 12.0 --organization ACME --per-page 5
Id,Errata ID,Type,Title,Issued,Updated
73296,RHSA-2022:5468,security,Important: php:8.0 security update,2022-06-30,2022-06-30
73295,RHSA-2022:5467,security,Important: php:7.4 security update,2022-06-30,2022-06-30
73286,RHSA-2022:5469,security,Important: firefox security update,2022-06-30,2022-06-30
73285,RHSA-2022:5470,security,Important: thunderbird security update,2022-06-30,2022-06-30
73299,RHBA-2022:5332,bugfix,scap-security-guide bug fix and enhancement update,2022-06-28,2022-06-28

The output from these reports can be shared with teams who may want to know what patch levels their servers will be updated to.

Leave a Reply

Your email address will not be published. Required fields are marked *

To respond on your own website, enter the URL of your response which should contain a link to this post's permalink URL. Your response will then appear (possibly after moderation) on this page. Want to update or remove your response? Update or delete your post and re-enter your post's URL again. (Find out more about Webmentions.)