yum history list + how to verify rpm historical status

sheffadmin asked:

The rpm command gives every package installed a transaction ID. The transaction ID is a Unix time stamp (number of seconds since January 1, 1970). You can then perform some operations on packages based on the transaction ID.

but on our rhel machines when we try to get info from yum history list $rpm_name

then we get the following errors

Bad transaction IDs, or package(s), given
Error: Failed history list

usually if rpm was removed the we should get from yum history list $rpm_name

ID     | Login user               | Date and time    | Action(s)      | Altered
-------------------------------------------------------------------------------
    29 | root <root>              | 2020-11-24 00:54 | Erase          |   26
     1 | System <unset>           | 2019-12-15 14:05 | Install        | 1363
history list

and if rpm is installed then we should get from yum history list $rpm_name

ID     | Login user               | Date and time    | Action(s)      | Altered
-------------------------------------------------------------------------------
    31 | root <root>              | 2020-11-26 01:06 | Install        |    1

but what is the meaning of the errors below ? that we get from yum history list $rpm_name

note – rpm_name – is rpm name

Bad transaction IDs, or package(s), given
Error: Failed history list

My answer:


You must give the name of the package, not the name of a file.

So you would use libcgroup, not libcgroup-0.41-19.el7.x86_64.rpm.


View the full question and any other answers on Server Fault.

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.