CentOS 7 下 yum history 实现安装 && 卸载

安装

# ansible 安装
[root@slave1 ~]# yum -y install ansible-2.9.19-1.el7.ans.noarch.rpm 
Loaded plugins: fastestmirror
Examining ansible-2.9.19-1.el7.ans.noarch.rpm: ansible-2.9.19-1.el7.ans.noarch
Marking ansible-2.9.19-1.el7.ans.noarch.rpm to be installed
Resolving Dependencies
--> Running transaction check
---> Package ansible.noarch 0:2.9.19-1.el7.ans will be installed
--> Processing Dependency: PyYAML for package: ansible-2.9.19-1.el7.ans.noarch
Loading mirror speeds from cached hostfile
 * base: mirrors.huaweicloud.com
 * extras: mirrors.huaweicloud.com
 * updates: mirror.lzu.edu.cn
--> Processing Dependency: python-jinja2 for package: ansible-2.9.19-1.el7.ans.noarch
--> Processing Dependency: python-paramiko for package: ansible-2.9.19-1.el7.ans.noarch
--> Processing Dependency: python-six for package: ansible-2.9.19-1.el7.ans.noarch
--> Processing Dependency: python2-cryptography for package: ansible-2.9.19-1.el7.ans.noarch
--> Processing Dependency: sshpass for package: ansible-2.9.19-1.el7.ans.noarch
--> Running transaction check
---> Package PyYAML.x86_64 0:3.10-11.el7 will be installed
--> Processing Dependency: libyaml-0.so.2()(64bit) for package: PyYAML-3.10-11.el7.x86_64
---> Package python-jinja2.noarch 0:2.7.2-4.el7 will be installed
--> Processing Dependency: python-babel >= 0.8 for package: python-jinja2-2.7.2-4.el7.noarch
--> Processing Dependency: python-markupsafe for package: python-jinja2-2.7.2-4.el7.noarch
---> Package python-paramiko.noarch 0:2.1.1-9.el7 will be installed
--> Processing Dependency: python2-pyasn1 for package: python-paramiko-2.1.1-9.el7.noarch
---> Package python-six.noarch 0:1.9.0-2.el7 will be installed
---> Package python2-cryptography.x86_64 0:1.7.2-2.el7 will be installed
--> Processing Dependency: python-idna >= 2.0 for package: python2-cryptography-1.7.2-2.el7.x86_64
--> Processing Dependency: python-cffi >= 1.4.1 for package: python2-cryptography-1.7.2-2.el7.x86_64
--> Processing Dependency: python-setuptools for package: python2-cryptography-1.7.2-2.el7.x86_64
--> Processing Dependency: python-ipaddress for package: python2-cryptography-1.7.2-2.el7.x86_64
--> Processing Dependency: python-enum34 for package: python2-cryptography-1.7.2-2.el7.x86_64
---> Package sshpass.x86_64 0:1.06-2.el7 will be installed
--> Running transaction check
---> Package libyaml.x86_64 0:0.1.4-11.el7_0 will be installed
---> Package python-babel.noarch 0:0.9.6-8.el7 will be installed
---> Package python-cffi.x86_64 0:1.6.0-5.el7 will be installed
--> Processing Dependency: python-pycparser for package: python-cffi-1.6.0-5.el7.x86_64
---> Package python-enum34.noarch 0:1.0.4-1.el7 will be installed
---> Package python-idna.noarch 0:2.4-1.el7 will be installed
---> Package python-ipaddress.noarch 0:1.0.16-2.el7 will be installed
---> Package python-markupsafe.x86_64 0:0.11-10.el7 will be installed
---> Package python-setuptools.noarch 0:0.9.8-7.el7 will be installed
--> Processing Dependency: python-backports-ssl_match_hostname for package: python-setuptools-0.9.8-7.el7.noarch
---> Package python2-pyasn1.noarch 0:0.1.9-7.el7 will be installed
--> Running transaction check
---> Package python-backports-ssl_match_hostname.noarch 0:3.5.0.1-1.el7 will be installed
--> Processing Dependency: python-backports for package: python-backports-ssl_match_hostname-3.5.0.1-1.el7.noarch
---> Package python-pycparser.noarch 0:2.14-1.el7 will be installed
--> Processing Dependency: python-ply for package: python-pycparser-2.14-1.el7.noarch
--> Running transaction check
---> Package python-backports.x86_64 0:1.0-8.el7 will be installed
---> Package python-ply.noarch 0:3.4-11.el7 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

===============================================================================================================================
 Package                                   Arch         Version                   Repository                              Size
===============================================================================================================================
Installing:
 ansible                                   noarch       2.9.19-1.el7.ans          /ansible-2.9.19-1.el7.ans.noarch       103 M
Installing for dependencies:
 PyYAML                                    x86_64       3.10-11.el7               base                                   153 k
 libyaml                                   x86_64       0.1.4-11.el7_0            base                                    55 k
 python-babel                              noarch       0.9.6-8.el7               base                                   1.4 M
 python-backports                          x86_64       1.0-8.el7                 base                                   5.8 k
 python-backports-ssl_match_hostname       noarch       3.5.0.1-1.el7             base                                    13 k
 python-cffi                               x86_64       1.6.0-5.el7               base                                   218 k
 python-enum34                             noarch       1.0.4-1.el7               base                                    52 k
 python-idna                               noarch       2.4-1.el7                 base                                    94 k
 python-ipaddress                          noarch       1.0.16-2.el7              base                                    34 k
 python-jinja2                             noarch       2.7.2-4.el7               base                                   519 k
 python-markupsafe                         x86_64       0.11-10.el7               base                                    25 k
 python-paramiko                           noarch       2.1.1-9.el7               base                                   269 k
 python-ply                                noarch       3.4-11.el7                base                                   123 k
 python-pycparser                          noarch       2.14-1.el7                base                                   104 k
 python-setuptools                         noarch       0.9.8-7.el7               base                                   397 k
 python-six                                noarch       1.9.0-2.el7               base                                    29 k
 python2-cryptography                      x86_64       1.7.2-2.el7               base                                   502 k
 python2-pyasn1                            noarch       0.1.9-7.el7               base                                   100 k
 sshpass                                   x86_64       1.06-2.el7                extras                                  21 k

Transaction Summary
===============================================================================================================================
Install  1 Package (+19 Dependent packages)

Total size: 107 M
Total download size: 4.0 M
Installed size: 122 M
Downloading packages:
(1/19): python-backports-1.0-8.el7.x86_64.rpm                                                           | 5.8 kB  00:00:00     
(2/19): python-backports-ssl_match_hostname-3.5.0.1-1.el7.noarch.rpm                                    |  13 kB  00:00:00     
(3/19): python-enum34-1.0.4-1.el7.noarch.rpm                                                            |  52 kB  00:00:00     
(4/19): python-cffi-1.6.0-5.el7.x86_64.rpm                                                              | 218 kB  00:00:00     
(5/19): libyaml-0.1.4-11.el7_0.x86_64.rpm                                                               |  55 kB  00:00:00     
(6/19): python-ipaddress-1.0.16-2.el7.noarch.rpm                                                        |  34 kB  00:00:00     
(7/19): python-idna-2.4-1.el7.noarch.rpm                                                                |  94 kB  00:00:00     
(8/19): python-paramiko-2.1.1-9.el7.noarch.rpm                                                          | 269 kB  00:00:00     
(9/19): python-markupsafe-0.11-10.el7.x86_64.rpm                                                        |  25 kB  00:00:00     
(10/19): python-ply-3.4-11.el7.noarch.rpm                                                               | 123 kB  00:00:00     
(11/19): python-babel-0.9.6-8.el7.noarch.rpm                                                            | 1.4 MB  00:00:01     
(12/19): python-six-1.9.0-2.el7.noarch.rpm                                                              |  29 kB  00:00:00     
(13/19): python-setuptools-0.9.8-7.el7.noarch.rpm                                                       | 397 kB  00:00:00     
(14/19): python2-pyasn1-0.1.9-7.el7.noarch.rpm                                                          | 100 kB  00:00:00     
(15/19): python2-cryptography-1.7.2-2.el7.x86_64.rpm                                                    | 502 kB  00:00:00     
(16/19): sshpass-1.06-2.el7.x86_64.rpm                                                                  |  21 kB  00:00:00     
(17/19): python-pycparser-2.14-1.el7.noarch.rpm                                                         | 104 kB  00:00:00     
(18/19): python-jinja2-2.7.2-4.el7.noarch.rpm                                                           | 519 kB  00:00:01     
(19/19): PyYAML-3.10-11.el7.x86_64.rpm                                                                  | 153 kB  00:00:05     
-------------------------------------------------------------------------------------------------------------------------------
Total                                                                                          704 kB/s | 4.0 MB  00:00:05     
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : python-six-1.9.0-2.el7.noarch                                                                              1/20 
  Installing : python2-pyasn1-0.1.9-7.el7.noarch                                                                          2/20 
  Installing : python-ipaddress-1.0.16-2.el7.noarch                                                                       3/20 
  Installing : sshpass-1.06-2.el7.x86_64                                                                                  4/20 
  Installing : python-ply-3.4-11.el7.noarch                                                                               5/20 
  Installing : python-pycparser-2.14-1.el7.noarch                                                                         6/20 
  Installing : python-cffi-1.6.0-5.el7.x86_64                                                                             7/20 
  Installing : python-backports-1.0-8.el7.x86_64                                                                          8/20 
  Installing : python-backports-ssl_match_hostname-3.5.0.1-1.el7.noarch                                                   9/20 
  Installing : python-setuptools-0.9.8-7.el7.noarch                                                                      10/20 
  Installing : python-babel-0.9.6-8.el7.noarch                                                                           11/20 
  Installing : python-markupsafe-0.11-10.el7.x86_64                                                                      12/20 
  Installing : python-jinja2-2.7.2-4.el7.noarch                                                                          13/20 
  Installing : python-enum34-1.0.4-1.el7.noarch                                                                          14/20 
  Installing : libyaml-0.1.4-11.el7_0.x86_64                                                                             15/20 
  Installing : PyYAML-3.10-11.el7.x86_64                                                                                 16/20 
  Installing : python-idna-2.4-1.el7.noarch                                                                              17/20 
  Installing : python2-cryptography-1.7.2-2.el7.x86_64                                                                   18/20 
  Installing : python-paramiko-2.1.1-9.el7.noarch                                                                        19/20 
  Installing : ansible-2.9.19-1.el7.ans.noarch                                                                           20/20 
  Verifying  : python-idna-2.4-1.el7.noarch                                                                               1/20 
  Verifying  : libyaml-0.1.4-11.el7_0.x86_64                                                                              2/20 
  Verifying  : python-setuptools-0.9.8-7.el7.noarch                                                                       3/20 
  Verifying  : python-enum34-1.0.4-1.el7.noarch                                                                           4/20 
  Verifying  : python-backports-ssl_match_hostname-3.5.0.1-1.el7.noarch                                                   5/20 
  Verifying  : python-paramiko-2.1.1-9.el7.noarch                                                                         6/20 
  Verifying  : python-markupsafe-0.11-10.el7.x86_64                                                                       7/20 
  Verifying  : python-babel-0.9.6-8.el7.noarch                                                                            8/20 
  Verifying  : python-backports-1.0-8.el7.x86_64                                                                          9/20 
  Verifying  : python-cffi-1.6.0-5.el7.x86_64                                                                            10/20 
  Verifying  : python-ipaddress-1.0.16-2.el7.noarch                                                                      11/20 
  Verifying  : ansible-2.9.19-1.el7.ans.noarch                                                                           12/20 
  Verifying  : python-jinja2-2.7.2-4.el7.noarch                                                                          13/20 
  Verifying  : python2-pyasn1-0.1.9-7.el7.noarch                                                                         14/20 
  Verifying  : python-ply-3.4-11.el7.noarch                                                                              15/20 
  Verifying  : PyYAML-3.10-11.el7.x86_64                                                                                 16/20 
  Verifying  : python-pycparser-2.14-1.el7.noarch                                                                        17/20 
  Verifying  : python-six-1.9.0-2.el7.noarch                                                                             18/20 
  Verifying  : sshpass-1.06-2.el7.x86_64                                                                                 19/20 
  Verifying  : python2-cryptography-1.7.2-2.el7.x86_64                                                                   20/20 

Installed:
  ansible.noarch 0:2.9.19-1.el7.ans                                                                                            

Dependency Installed:
  PyYAML.x86_64 0:3.10-11.el7                                               libyaml.x86_64 0:0.1.4-11.el7_0                    
  python-babel.noarch 0:0.9.6-8.el7                                         python-backports.x86_64 0:1.0-8.el7                
  python-backports-ssl_match_hostname.noarch 0:3.5.0.1-1.el7                python-cffi.x86_64 0:1.6.0-5.el7                   
  python-enum34.noarch 0:1.0.4-1.el7                                        python-idna.noarch 0:2.4-1.el7                     
  python-ipaddress.noarch 0:1.0.16-2.el7                                    python-jinja2.noarch 0:2.7.2-4.el7                 
  python-markupsafe.x86_64 0:0.11-10.el7                                    python-paramiko.noarch 0:2.1.1-9.el7               
  python-ply.noarch 0:3.4-11.el7                                            python-pycparser.noarch 0:2.14-1.el7               
  python-setuptools.noarch 0:0.9.8-7.el7                                    python-six.noarch 0:1.9.0-2.el7                    
  python2-cryptography.x86_64 0:1.7.2-2.el7                                 python2-pyasn1.noarch 0:0.1.9-7.el7                
  sshpass.x86_64 0:1.06-2.el7                                              

Complete!

查看安装记录

[root@slave1 ~]# yum history list
Loaded plugins: fastestmirror
ID     | Login user               | Date and time    | Action(s)      | Altered
-------------------------------------------------------------------------------
     5 | root <root>              | 2021-03-23 17:40 | Install        |   20   
     4 | root <root>              | 2021-03-23 17:40 | Erase          |   20   
     3 | root <root>              | 2021-03-23 17:26 | Install        |   20   
     2 | root <root>              | 2021-03-23 17:23 | Install        |    1   
     1 | System <unset>           | 2020-07-08 23:55 | Install        |  409   
history list

查看安装详情

[root@slave1 ~]# yum history info 5
Loaded plugins: fastestmirror
Transaction ID : 5
Begin time     : Tue Mar 23 17:40:55 2021
Begin rpmdb    : 410:99d50cbd05cc74fbf150dcd38410867114af2ae0
End time       :            17:41:11 2021 (16 seconds)
End rpmdb      : 430:98507e234c878bdf0b791552f9f5cbb2c81e7e46
User           : root <root>
Return-Code    : Success
Command Line   : -y install ansible-2.9.19-1.el7.ans.noarch.rpm
Transaction performed with:
    Installed     rpm-4.11.3-32.el7.x86_64                      @anaconda
    Installed     yum-3.4.3-158.el7.centos.noarch               @anaconda
    Installed     yum-plugin-fastestmirror-1.1.31-45.el7.noarch @anaconda
Packages Altered:
    Dep-Install PyYAML-3.10-11.el7.x86_64                                @base
    Install     ansible-2.9.19-1.el7.ans.noarch                          @/ansible-2.9.19-1.el7.ans.noarch
    Dep-Install libyaml-0.1.4-11.el7_0.x86_64                            @base
    Dep-Install python-babel-0.9.6-8.el7.noarch                          @base
    Dep-Install python-backports-1.0-8.el7.x86_64                        @base
    Dep-Install python-backports-ssl_match_hostname-3.5.0.1-1.el7.noarch @base
    Dep-Install python-cffi-1.6.0-5.el7.x86_64                           @base
    Dep-Install python-enum34-1.0.4-1.el7.noarch                         @base
    Dep-Install python-idna-2.4-1.el7.noarch                             @base
    Dep-Install python-ipaddress-1.0.16-2.el7.noarch                     @base
    Dep-Install python-jinja2-2.7.2-4.el7.noarch                         @base
    Dep-Install python-markupsafe-0.11-10.el7.x86_64                     @base
    Dep-Install python-paramiko-2.1.1-9.el7.noarch                       @base
    Dep-Install python-ply-3.4-11.el7.noarch                             @base
    Dep-Install python-pycparser-2.14-1.el7.noarch                       @base
    Dep-Install python-setuptools-0.9.8-7.el7.noarch                     @base
    Dep-Install python-six-1.9.0-2.el7.noarch                            @base
    Dep-Install python2-cryptography-1.7.2-2.el7.x86_64                  @base
    Dep-Install python2-pyasn1-0.1.9-7.el7.noarch                        @base
    Dep-Install sshpass-1.06-2.el7.x86_64                                @extras
history info

undo 卸载

[root@slave1 ~]# yum -y history undo 5
Loaded plugins: fastestmirror
Undoing transaction 5, from Tue Mar 23 17:40:55 2021
    Dep-Install PyYAML-3.10-11.el7.x86_64                                @base
    Install     ansible-2.9.19-1.el7.ans.noarch                          @/ansible-2.9.19-1.el7.ans.noarch
    Dep-Install libyaml-0.1.4-11.el7_0.x86_64                            @base
    Dep-Install python-babel-0.9.6-8.el7.noarch                          @base
    Dep-Install python-backports-1.0-8.el7.x86_64                        @base
    Dep-Install python-backports-ssl_match_hostname-3.5.0.1-1.el7.noarch @base
    Dep-Install python-cffi-1.6.0-5.el7.x86_64                           @base
    Dep-Install python-enum34-1.0.4-1.el7.noarch                         @base
    Dep-Install python-idna-2.4-1.el7.noarch                             @base
    Dep-Install python-ipaddress-1.0.16-2.el7.noarch                     @base
    Dep-Install python-jinja2-2.7.2-4.el7.noarch                         @base
    Dep-Install python-markupsafe-0.11-10.el7.x86_64                     @base
    Dep-Install python-paramiko-2.1.1-9.el7.noarch                       @base
    Dep-Install python-ply-3.4-11.el7.noarch                             @base
    Dep-Install python-pycparser-2.14-1.el7.noarch                       @base
    Dep-Install python-setuptools-0.9.8-7.el7.noarch                     @base
    Dep-Install python-six-1.9.0-2.el7.noarch                            @base
    Dep-Install python2-cryptography-1.7.2-2.el7.x86_64                  @base
    Dep-Install python2-pyasn1-0.1.9-7.el7.noarch                        @base
    Dep-Install sshpass-1.06-2.el7.x86_64                                @extras
Resolving Dependencies
--> Running transaction check
---> Package PyYAML.x86_64 0:3.10-11.el7 will be erased
---> Package ansible.noarch 0:2.9.19-1.el7.ans will be erased
---> Package libyaml.x86_64 0:0.1.4-11.el7_0 will be erased
---> Package python-babel.noarch 0:0.9.6-8.el7 will be erased
---> Package python-backports.x86_64 0:1.0-8.el7 will be erased
---> Package python-backports-ssl_match_hostname.noarch 0:3.5.0.1-1.el7 will be erased
---> Package python-cffi.x86_64 0:1.6.0-5.el7 will be erased
---> Package python-enum34.noarch 0:1.0.4-1.el7 will be erased
---> Package python-idna.noarch 0:2.4-1.el7 will be erased
---> Package python-ipaddress.noarch 0:1.0.16-2.el7 will be erased
---> Package python-jinja2.noarch 0:2.7.2-4.el7 will be erased
---> Package python-markupsafe.x86_64 0:0.11-10.el7 will be erased
---> Package python-paramiko.noarch 0:2.1.1-9.el7 will be erased
---> Package python-ply.noarch 0:3.4-11.el7 will be erased
---> Package python-pycparser.noarch 0:2.14-1.el7 will be erased
---> Package python-setuptools.noarch 0:0.9.8-7.el7 will be erased
---> Package python-six.noarch 0:1.9.0-2.el7 will be erased
---> Package python2-cryptography.x86_64 0:1.7.2-2.el7 will be erased
---> Package python2-pyasn1.noarch 0:0.1.9-7.el7 will be erased
---> Package sshpass.x86_64 0:1.06-2.el7 will be erased
--> Finished Dependency Resolution

Dependencies Resolved

===============================================================================================================================
 Package                                         Arch               Version                        Repository             Size
===============================================================================================================================
Removing:
 PyYAML                                          x86_64             3.10-11.el7                    @base                 630 k
 ansible                                         noarch             2.9.19-1.el7.ans               installed             103 M
 libyaml                                         x86_64             0.1.4-11.el7_0                 @base                 130 k
 python-babel                                    noarch             0.9.6-8.el7                    @base                 5.2 M
 python-backports                                x86_64             1.0-8.el7                      @base                 638  
 python-backports-ssl_match_hostname             noarch             3.5.0.1-1.el7                  @base                  18 k
 python-cffi                                     x86_64             1.6.0-5.el7                    @base                 1.0 M
 python-enum34                                   noarch             1.0.4-1.el7                    @base                 322 k
 python-idna                                     noarch             2.4-1.el7                      @base                 563 k
 python-ipaddress                                noarch             1.0.16-2.el7                   @base                 227 k
 python-jinja2                                   noarch             2.7.2-4.el7                    @base                 3.0 M
 python-markupsafe                               x86_64             0.11-10.el7                    @base                  58 k
 python-paramiko                                 noarch             2.1.1-9.el7                    @base                 1.2 M
 python-ply                                      noarch             3.4-11.el7                     @base                 529 k
 python-pycparser                                noarch             2.14-1.el7                     @base                 622 k
 python-setuptools                               noarch             0.9.8-7.el7                    @base                 1.9 M
 python-six                                      noarch             1.9.0-2.el7                    @base                  97 k
 python2-cryptography                            x86_64             1.7.2-2.el7                    @base                 2.6 M
 python2-pyasn1                                  noarch             0.1.9-7.el7                    @base                 458 k
 sshpass                                         x86_64             1.06-2.el7                     @extras                38 k

Transaction Summary
===============================================================================================================================
Remove  20 Packages

Installed size: 122 M
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Erasing    : ansible-2.9.19-1.el7.ans.noarch                                                                            1/20 
  Erasing    : python-jinja2-2.7.2-4.el7.noarch                                                                           2/20 
  Erasing    : python-paramiko-2.1.1-9.el7.noarch                                                                         3/20 
  Erasing    : python2-cryptography-1.7.2-2.el7.x86_64                                                                    4/20 
  Erasing    : python-setuptools-0.9.8-7.el7.noarch                                                                       5/20 
  Erasing    : python-backports-ssl_match_hostname-3.5.0.1-1.el7.noarch                                                   6/20 
  Erasing    : python-cffi-1.6.0-5.el7.x86_64                                                                             7/20 
  Erasing    : python-pycparser-2.14-1.el7.noarch                                                                         8/20 
  Erasing    : PyYAML-3.10-11.el7.x86_64                                                                                  9/20 
  Erasing    : python-ply-3.4-11.el7.noarch                                                                              10/20 
  Erasing    : python-backports-1.0-8.el7.x86_64                                                                         11/20 
  Erasing    : python-ipaddress-1.0.16-2.el7.noarch                                                                      12/20 
  Erasing    : python-enum34-1.0.4-1.el7.noarch                                                                          13/20 
  Erasing    : python-idna-2.4-1.el7.noarch                                                                              14/20 
  Erasing    : python2-pyasn1-0.1.9-7.el7.noarch                                                                         15/20 
  Erasing    : python-six-1.9.0-2.el7.noarch                                                                             16/20 
  Erasing    : python-babel-0.9.6-8.el7.noarch                                                                           17/20 
  Erasing    : libyaml-0.1.4-11.el7_0.x86_64                                                                             18/20 
  Erasing    : python-markupsafe-0.11-10.el7.x86_64                                                                      19/20 
  Erasing    : sshpass-1.06-2.el7.x86_64                                                                                 20/20 
  Verifying  : python-idna-2.4-1.el7.noarch                                                                               1/20 
  Verifying  : libyaml-0.1.4-11.el7_0.x86_64                                                                              2/20 
  Verifying  : python2-cryptography-1.7.2-2.el7.x86_64                                                                    3/20 
  Verifying  : python-ply-3.4-11.el7.noarch                                                                               4/20 
  Verifying  : python-backports-ssl_match_hostname-3.5.0.1-1.el7.noarch                                                   5/20 
  Verifying  : python-paramiko-2.1.1-9.el7.noarch                                                                         6/20 
  Verifying  : python-markupsafe-0.11-10.el7.x86_64                                                                       7/20 
  Verifying  : sshpass-1.06-2.el7.x86_64                                                                                  8/20 
  Verifying  : python-babel-0.9.6-8.el7.noarch                                                                            9/20 
  Verifying  : python-backports-1.0-8.el7.x86_64                                                                         10/20 
  Verifying  : python-cffi-1.6.0-5.el7.x86_64                                                                            11/20 
  Verifying  : python-ipaddress-1.0.16-2.el7.noarch                                                                      12/20 
  Verifying  : ansible-2.9.19-1.el7.ans.noarch                                                                           13/20 
  Verifying  : python-jinja2-2.7.2-4.el7.noarch                                                                          14/20 
  Verifying  : python2-pyasn1-0.1.9-7.el7.noarch                                                                         15/20 
  Verifying  : PyYAML-3.10-11.el7.x86_64                                                                                 16/20 
  Verifying  : python-pycparser-2.14-1.el7.noarch                                                                        17/20 
  Verifying  : python-six-1.9.0-2.el7.noarch                                                                             18/20 
  Verifying  : python-setuptools-0.9.8-7.el7.noarch                                                                      19/20 
  Verifying  : python-enum34-1.0.4-1.el7.noarch                                                                          20/20 

Removed:
  PyYAML.x86_64 0:3.10-11.el7                         ansible.noarch 0:2.9.19-1.el7.ans                                        
  libyaml.x86_64 0:0.1.4-11.el7_0                     python-babel.noarch 0:0.9.6-8.el7                                        
  python-backports.x86_64 0:1.0-8.el7                 python-backports-ssl_match_hostname.noarch 0:3.5.0.1-1.el7               
  python-cffi.x86_64 0:1.6.0-5.el7                    python-enum34.noarch 0:1.0.4-1.el7                                       
  python-idna.noarch 0:2.4-1.el7                      python-ipaddress.noarch 0:1.0.16-2.el7                                   
  python-jinja2.noarch 0:2.7.2-4.el7                  python-markupsafe.x86_64 0:0.11-10.el7                                   
  python-paramiko.noarch 0:2.1.1-9.el7                python-ply.noarch 0:3.4-11.el7                                           
  python-pycparser.noarch 0:2.14-1.el7                python-setuptools.noarch 0:0.9.8-7.el7                                   
  python-six.noarch 0:1.9.0-2.el7                     python2-cryptography.x86_64 0:1.7.2-2.el7                                
  python2-pyasn1.noarch 0:0.1.9-7.el7                 sshpass.x86_64 0:1.06-2.el7                                              

Complete!

yum history 验证

[root@slave1 ~]# yum history info 6
Loaded plugins: fastestmirror
Transaction ID : 6
Begin time     : Tue Mar 23 17:43:13 2021
Begin rpmdb    : 430:98507e234c878bdf0b791552f9f5cbb2c81e7e46
End time       :            17:43:14 2021 (1 seconds)
End rpmdb      : 410:99d50cbd05cc74fbf150dcd38410867114af2ae0
User           : root <root>
Return-Code    : Success
Command Line   : -y history undo 5
Transaction performed with:
    Installed     rpm-4.11.3-32.el7.x86_64                      @anaconda
    Installed     yum-3.4.3-158.el7.centos.noarch               @anaconda
    Installed     yum-plugin-fastestmirror-1.1.31-45.el7.noarch @anaconda
Packages Altered:
    Erase PyYAML-3.10-11.el7.x86_64                                @base
    Erase ansible-2.9.19-1.el7.ans.noarch                          @/ansible-2.9.19-1.el7.ans.noarch
    Erase libyaml-0.1.4-11.el7_0.x86_64                            @base
    Erase python-babel-0.9.6-8.el7.noarch                          @base
    Erase python-backports-1.0-8.el7.x86_64                        @base
    Erase python-backports-ssl_match_hostname-3.5.0.1-1.el7.noarch @base
    Erase python-cffi-1.6.0-5.el7.x86_64                           @base
    Erase python-enum34-1.0.4-1.el7.noarch                         @base
    Erase python-idna-2.4-1.el7.noarch                             @base
    Erase python-ipaddress-1.0.16-2.el7.noarch                     @base
    Erase python-jinja2-2.7.2-4.el7.noarch                         @base
    Erase python-markupsafe-0.11-10.el7.x86_64                     @base
    Erase python-paramiko-2.1.1-9.el7.noarch                       @base
    Erase python-ply-3.4-11.el7.noarch                             @base
    Erase python-pycparser-2.14-1.el7.noarch                       @base
    Erase python-setuptools-0.9.8-7.el7.noarch                     @base
    Erase python-six-1.9.0-2.el7.noarch                            @base
    Erase python2-cryptography-1.7.2-2.el7.x86_64                  @base
    Erase python2-pyasn1-0.1.9-7.el7.noarch                        @base
    Erase sshpass-1.06-2.el7.x86_64                                @extras
history info
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值