From the course: Red Hat Certified System Administrator (EX200) Cert Prep: 1 Deploy, Configure, and Manage (2021)

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

RPM query formatting

RPM query formatting

- [Narrator] Querying the RPM database of local installed packages can be very powerful. If you want to present the information in a certain format you might want to change the fields that are returned. All packages have tags that we can show or hide. To get a list of all tags type into a terminal rpm space dash dash query tags and hit Enter. My center's installation lists over 240 different tags. You get to decide what you want printed on the screen just by choosing them. If I wanted to show the package name and version but nothing else, I could type in clear and then type in rpm space dash qa space dash dash query format space double quote percent left curly brace uppercase name right curly brace space percent left curly brace version right curly brace backslash n double quote. To use the tags we need to surround them with a percent symbol and curly braces. For this example, I'm querying all files in the database with a…

Contents