One - One Code All

Blog Content

centos卸载软件不要直接运行yum remove

Linux-Mac   2019-09-20 07:29:52

安装和卸载nginx

使用yum install nginx 安装了nginx,

这是如果直接使用yum remove nginx 的话,会把依赖的一些包也删掉,


Dependencies resolved.

========================================================================================================================

 Package                            Architecture  Version                                       Repository         Size

========================================================================================================================

Removing:

 nginx                              x86_64        1:1.14.1-9.module_el8.0.0+184+e34fea82        @AppStream        1.7 M

Removing unused dependencies:

 gd                                 x86_64        2.2.5-6.el8                                   @AppStream        431 k

 jbigkit-libs                       x86_64        2.1-14.el8                                    @AppStream        107 k

 libXpm                             x86_64        3.5.12-7.el8                                  @AppStream        129 k

 libjpeg-turbo                      x86_64        1.5.3-10.el8                                  @AppStream        623 k

 libtiff                            x86_64        4.0.9-15.el8                                  @AppStream        619 k

 libwebp                            x86_64        1.0.0-1.el8                                   @AppStream        841 k

 libxslt                            x86_64        1.1.32-3.el8                                  @BaseOS           745 k

 nginx-all-modules                  noarch        1:1.14.1-9.module_el8.0.0+184+e34fea82        @AppStream          0  

 nginx-filesystem                   noarch        1:1.14.1-9.module_el8.0.0+184+e34fea82        @AppStream          0  

 nginx-mod-http-image-filter        x86_64        1:1.14.1-9.module_el8.0.0+184+e34fea82        @AppStream         29 k

 nginx-mod-http-perl                x86_64        1:1.14.1-9.module_el8.0.0+184+e34fea82        @AppStream         61 k

 nginx-mod-http-xslt-filter         x86_64        1:1.14.1-9.module_el8.0.0+184+e34fea82        @AppStream         25 k

 nginx-mod-mail                     x86_64        1:1.14.1-9.module_el8.0.0+184+e34fea82        @AppStream        113 k

 nginx-mod-stream                   x86_64        1:1.14.1-9.module_el8.0.0+184+e34fea82        @AppStream        171 k


Transaction Summary

========================================================================================================================

Remove  15 Packages


Freed space: 5.5 M

Is this ok [y/N]: n


所以要使用rpm -e --nodeps nginx这个命令,就只删除nginx这个包,不会删除依赖包,

rpm -e --nodeps nginx



上一篇:mac升级mysql数据库到mysql8.0
下一篇:解决iterm2终端SSH连接服务器一段时间不操作之后卡死的问题

The minute you think of giving up, think of the reason why you held on so long.