系統:redhat 7.6
說明:配置yum源,提示This system is not registered with an entitlement server. You can use subscription-manager to register.
配置文件:
[root@localhost yum.repos.d]# cat redhat7.repo [rhel-source] name=Source baseurl=file:///mnt enabled=1 gpgcheck=0
yum安裝測試,能夠進行安裝,但是系統提示沒有注冊
[root@localhost yum.repos.d]# yum install -y tree Loaded plugins: product-id, search-disabled-repos, subscription-manager This system is not registered with an entitlement server. You can use subscription-manager to register. Resolving Dependencies --> Running transaction check ---> Package tree.x86_64 0:1.6.0-10.el7 will be installed --> Finished Dependency Resolution Dependencies Resolved =============================================================================================================================================================================================== Package Arch Version Repository Size =============================================================================================================================================================================================== Installing: tree x86_64 1.6.0-10.el7 rhel-source 46 k Transaction Summary =============================================================================================================================================================================================== Install 1 Package Total download size: 46 k Installed size: 87 k Downloading packages: Running transaction check Running transaction test Transaction test succeeded Running transaction Installing : tree-1.6.0-10.el7.x86_64 1/1 Verifying : tree-1.6.0-10.el7.x86_64 1/1 Installed: tree.x86_64 0:1.6.0-10.el7 Complete!
原因:redhat自帶的插件subscription-manager。這個插件的作用就是Red Hat Subscription Manager訂閱管理器,就是它讓你一直register
解決辦法:將配置文件subscription-manager.conf中的enable注釋掉
[root@localhost yum.repos.d]# vi /etc/yum/pluginconf.d/subscription-manager.conf [main] #enabled=1 ~
將安裝的軟件remove,再次進行安裝實驗
[root@tz-yycs-db01 ~]# yum install -y tree Loaded plugins: product-id, search-disabled-repos Resolving Dependencies --> Running transaction check ---> Package tree.x86_64 0:1.6.0-10.el7 will be installed --> Finished Dependency Resolution Dependencies Resolved =============================================================================================================================================================================================== Package Arch Version Repository Size =============================================================================================================================================================================================== Installing: tree x86_64 1.6.0-10.el7 rhel-source 46 k Transaction Summary =============================================================================================================================================================================================== Install 1 Package Total download size: 46 k Installed size: 87 k Downloading packages: Running transaction check Running transaction test Transaction test succeeded Running transaction Installing : tree-1.6.0-10.el7.x86_64 1/1 Verifying : tree-1.6.0-10.el7.x86_64 1/1 Installed: tree.x86_64 0:1.6.0-10.el7 Complete!
