Error: Package: libselinux-python-2.2.2-6.el7.x86_64 (@anaconda) Requires: libselinux = 2
==========直接抛出问安装问题
===场景 安装nginx时相关的依赖包不配套问题 yum -y install gcc pcre-devel zlib zlib-devel openssl openssl-devel
===系统centos7 安装nginx
====解决方案
1.安装yum-utils相关工具 yum -y install yum-utils
2.清理yum yum clean all
3.清理未完成事务 yum-complete-transaction,清理未完成事务
4.清理安装文件原有依赖
package-cleanup --cleandupes -y
package-cleanup --cleandupes with --removenewestdupes -y
清理完安装正常
==================环境和系统和场景不同仅供参考====================
5.安装 yum -y install gcc pcre-devel zlib zlib-devel openssl openssl-devel