• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • VCS
  • Interview Questions
  • Database
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

CentOS / RHEL : How to view the commands executed in yum history command output

by admin

By default when you execute yum history command, you would only see the time and actions (update, install etc.) for the yum packages.

# yum history
.....
ID     | Login user               | Date and time    | Action(s)      | Altered
-------------------------------------------------------------------------------
    22 |  [user1]                | 2017-07-19 21:45 | I, U           |  279 EE
    21 |  [oracle]                | 2017-07-08 14:36 | Install        |    1
    20 |  [oracle]                | 2017-07-08 14:36 | Install        |    1 EE
    19 |  [oracle]                | 2017-07-08 14:35 | Install        |    1 EE
    18 |  [oracle]                | 2017-07-08 00:32 | Install        |    1

To also view the yum commands executed in the out put we need to add history_list_view=cmds entry to /etc/yum.conf file. By default, this parameter is not added in the yum configuration file.

# vi /etc/yum.conf
history_list_view=cmds

If you now check, you can find the commands like “install, update” in the second column. You would also get the options used with the command like –exclude.

# yum history
....
ID     | Command line             | Date and time    | Action(s)      | Altered
-------------------------------------------------------------------------------
    22 | --exclude=kernel*,*relea | 2017-07-19 21:45 | I, U           |  279 EE
    21 | install oracleasmlib-2.0 | 2017-07-08 14:36 | Install        |    1
    20 | install kmod-oracleasm-2 | 2017-07-08 14:36 | Install        |    1 EE
    19 | install oracleasm-suppor | 2017-07-08 14:35 | Install        |    1 EE
    18 | install compat-libcap* - | 2017-07-08 00:32 | Install        |    1

Filed Under: Linux

Some more articles you might also be interested in …

  1. husky Command Examples
  2. e2label: command not found
  3. lvcreate/lvremove Failed with Error “Can’t remove merging snapshot logical volume”
  4. flake8: Tool to check the style and quality of Python code
  5. llvm-as Command Examples
  6. gh: Work seamlessly with GitHub from the command-line
  7. notify-send: command not found
  8. gdebi: command not found
  9. e4defrag: command not found
  10. echo: command not found

You May Also Like

Primary Sidebar

Recent Posts

  • Vanilla OS 2 Released: A New Era for Linux Enthusiasts
  • mk Command Examples
  • mixxx Command Examples
  • mix Command Examples

© 2025 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright