# yum history 或 # yum history list all Loaded plugins: fastestmirror, presto ID | Login user | Date and time | Action(s) | Altered ------------------------------------------------------------------------------- 13 | root | 2017-08-18 13:30 | Update | 2 12 | root | 2017-08-10 07:46 | Install | 1 11 | root | 2017-07-28 17:10 | E, I, U | 28 EE 10 | root | 2017-04-21 09:16 | E, I, U | 162 EE 9 | root | 2017-02-09 17:09 | E, I, U | 20 EE 8 | root | 2017-02-02 10:45 | Install | 1 7 | root | 2016-12-15 06:48 | Update | 1 6 | root | 2016-12-15 06:43 | Install | 1 5 | root | 2016-12-02 10:28 | E, I, U | 23 EE 4 | root | 2016-10-28 05:37 | E, I, U | 13 EE 3 | root | 2016-10-18 12:53 | Install | 1 2 | root | 2016-09-30 10:28 | E, I, U | 31 EE 1 | root | 2016-07-26 11:40 | E, I, U | 160 EE
# yum history info 13 Loaded plugins: fastestmirror, presto Transaction ID : 13 Begin time : Fri Aug 1813:30:522017 Begin rpmdb : 420:f5c5f9184f44cf317de64d3a35199e894ad71188 End time : 13:30:542017 (2 seconds) End rpmdb : 420:d04a95c25d4526ef87598f0dcaec66d3f99b98d4 User : root Return-Code : Success Command Line : update git Transaction performed with: Installed rpm-4.8.0-55.el6.x86_64 @base Installed yum-3.2.29-81.el6.centos.noarch @base Installed yum-plugin-fastestmirror-1.1.30-40.el6.noarch @base Installed yum-presto-0.6.2-1.el6.noarch @anaconda-CentOS-201207061011.x86_64/6.3 Packages Altered: Updated git-1.7.1-8.el6.x86_64 @base Update1.7.1-9.el6_9.x86_64 @updates Updated perl-Git-1.7.1-8.el6.noarch @base Update1.7.1-9.el6_9.noarch @updates history info
# yum history undo 13 Loaded plugins: fastestmirror, presto Undoing transaction 53, from Fri Aug 18 13:30:52 2017 Updated git-1.7.1-8.el6.x86_64 @base Update 1.7.1-9.el6_9.x86_64 @updates Updated perl-Git-1.7.1-8.el6.noarch @base Update 1.7.1-9.el6_9.noarch @updates Loading mirror speeds from cached hostfile * base: repos.lax.quadranet.com * epel: fedora.mirrors.pair.com * extras: repo1.dal.innoscale.net * updates: mirror.vtti.vt.edu Resolving Dependencies --> Running transaction check ---> Package git.x86_64 0:1.7.1-8.el6 will be a downgrade ---> Package git.x86_64 0:1.7.1-9.el6_9 will be erased ---> Package perl-Git.noarch 0:1.7.1-8.el6 will be a downgrade ---> Package perl-Git.noarch 0:1.7.1-9.el6_9 will be erased --> Finished Dependency Resolution
Dependencies Resolved
================================================================================================= Package Arch Version Repository Size ================================================================================================= Downgrading: git x86_64 1.7.1-8.el6 base 4.6 M perl-Git noarch 1.7.1-8.el6 base 29 k
# yum downgrade git-1.7.1-8.el6 perl-Git-1.7.1-8.el6 Loaded plugins: search-disabled-repos, security, ulninfo Setting up Downgrade Process Resolving Dependencies --> Running transaction check ---> Package git.x86_64 0:1.7.1-8.el6 will be a downgrade ---> Package git.x86_64 0:1.7.1-9.el6_9 will be erased ---> Package perl-Git.noarch 0:1.7.1-8.el6 will be a downgrade ---> Package perl-Git.noarch 0:1.7.1-9.el6_9 will be erased --> Finished Dependency Resolution
Dependencies Resolved
================================================================================================= Package Arch Version Repository Size ================================================================================================= Downgrading: git x86_64 1.7.1-8.el6 base 4.6 M perl-Git noarch 1.7.1-8.el6 base 29 k