Difference between revisions of "Convert RH/OL To CentOS"
m |
|||
Line 1: | Line 1: | ||
− | + | Note: 'cat /etc/redhat-release' shows RedHat or Oracle before these steps | |
− | 'cat /etc/redhat-release' shows RedHat or Oracle before these steps | + | |
1. browse to the centos repo to get the link for the latest centos-release package, right-click/copy link/url | 1. browse to the centos repo to get the link for the latest centos-release package, right-click/copy link/url | ||
Line 11: | Line 10: | ||
[http://mirror.centos.org/centos/5/os/x86_64/CentOS/centos-release-notes-5.11-0.x86_64.rpm | [http://mirror.centos.org/centos/5/os/x86_64/CentOS/centos-release-notes-5.11-0.x86_64.rpm | ||
ENT 6 | ENT 6 | ||
− | # wget http://mirror.centos.org/centos/6/os/x86_64/Packages/centos-release-6- | + | # wget http://mirror.centos.org/centos/6/os/x86_64/Packages/centos-release-6-9.el6.centos.12.3.x86_64.rpm |
ENT 7 | ENT 7 | ||
# wget http://mirror.centos.org/centos/7/os/x86_64/Packages/centos-release-7-3.1611.el7.centos.x86_64.rpm | # wget http://mirror.centos.org/centos/7/os/x86_64/Packages/centos-release-7-3.1611.el7.centos.x86_64.rpm |
Revision as of 12:48, 14 June 2017
Note: 'cat /etc/redhat-release' shows RedHat or Oracle before these steps
1. browse to the centos repo to get the link for the latest centos-release package, right-click/copy link/url
http://mirror.centos.org/centos/5/os/x86_64/CentOS http://mirror.centos.org/centos/6/os/x86_64/Packages http://mirror.centos.org/centos/7/os/x86_64/Packages
2. wget the package/url (may need to specify a proxy, or use 'curl --proxy sc9-proxy.example.net:3128 -O http://mirror.centos.org/centos/6/os/x86_64/Packages/centos-release-6-8.el6.centos.12.3.x86_64.rpm')
ENT 5 # wget http://mirror.centos.org/centos/5/os/x86_64/CentOS/centos-release-5-11.el5.centos.x86_64.rpm [http://mirror.centos.org/centos/5/os/x86_64/CentOS/centos-release-notes-5.11-0.x86_64.rpm ENT 6 # wget http://mirror.centos.org/centos/6/os/x86_64/Packages/centos-release-6-9.el6.centos.12.3.x86_64.rpm ENT 7 # wget http://mirror.centos.org/centos/7/os/x86_64/Packages/centos-release-7-3.1611.el7.centos.x86_64.rpm
3. install centos-release (plus release notes dependency for RedHat 5) and remove redhat-release
Note: 'cat /etc/redhat-release' shows CentOS after this step
RedHat 5 # rpm -i --force centos-release-5-11.el5.centos.x86_64.rpm centos-release-notes-5.11-0.x86_64.rpm # rpm -e redhat-release-5Server redhat-release-notes-5Server RedHat 6 # rpm -i --force centos-release-6-8.el6.centos.12.3.x86_64.rpm # rpm -e redhat-release-server RedHat 7 # rpm -e --nodeps redhat-release-server # rm -rf /usr/share/redhat-release /usr/share/doc/redhat-release /etc/system-release-cpe.rpmsave /etc/os-release.rpmsave # rpm -i --force centos-release-7-2.1511.el7.centos.2.10.x86_64.rpm
4. system can now be subscribed to CentOS spacewalk channel with --force option, or add CentOS-Base.repo to /etc/yum.repos.d/CentOS-Base.repo
5. remove additional RedHat packages and replace with corresponding CentOS packages
RedHat 5 # yum update redhat-logos # rpm -e redhat-support-tool redhat-support-lib-python Deployment_Guide-en-US htmlview redhat-menus NOTE : order is important for RPM dependencies RedHat 6 # rpm -e --nodeps redhat-indexhtml # yum install centos-indexhtml # yum update redhat-logos # rpm -e redhat-support-tool redhat-support-lib-python redhat-access-insights subscription-manager IF you see a yum message about lynx-2.x.x-xx.el6.x86_64 has missing requires of redhat-indexhtml # yum reinstall lynx RedHat 7 # rpm -e --nodeps redhat-indexhtml redhat-logos # yum install centos-indexhtml centos-logos # yum update abrt redhat-menus # rpm -e redhat-support-tool redhat-support-lib-python redhat-access-insights subscription-manager