Results 1 to 25 of 62
-
05-25-2004, 06:30 PM #1Web Hosting Master
- Join Date
- Apr 2001
- Posts
- 2,611
HOW-TO: yum upgrade; redhat 9 -> CentOS 3.1
What is CentOS?: CentOS is essentially a rebuild of the RHEL source code. I've been using this OS for a couple weeks now with no issues running cpanel.
More info on CentOS can be found on the web site:
http://www.centos.org
Here are the steps i took to update a Redhat 9 box running on a minimal install ( no X, etc ) as suitable for a server to CentOS 3.1 ( which is a fork of RedHat Enterprise Linux v3 )..
I took a fresh install of redhat 9, slapped it on a test box then updated it with up2date. I then installed yum for redhat 9 which can be found here:
Yum Download
Now, you might want to rebuild the rpm database, just incase, thats up to you:
# rpm -vv --rebuilddb
I then modified /etc/yum.conf to look like this:
Code:[main] exclude=httpd* mysql* php* perl* cachedir=/var/cache/yum debuglevel=2 logfile=/var/log/yum.log pkgpolicy=newest distroverpkg=redhat-release installonlypkgs=kernel kernel-smp kernel-hugemem kernel-enterprise kernel-debug kernel-unsupported kernel-smp-unsupported kernel-hugemem-unsupported tolerant=1 exactarch=1 [base] name=CentOS-$releasever - Base baseurl=http://mirror.pacific.net.au/linux/cAos/centos-3/3.1/os/i386/ gpgcheck=1 #released updates [update] name=CentOS-$releasever - Updates baseurl=http://mirror.pacific.net.au/linux/cAos/centos-3/3.1/updates/i386/ gpgcheck=1 #packages used/produced in the build but not released [addons] name=CentOS-$releasever - Addons baseurl=http://mirror.pacific.net.au/linux/cAos/centos-3/3.1/addons/i386/ gpgcheck=1 #additional packages that may be useful [extras] name=CentOS-$releasever - Extras baseurl=http://mirror.pacific.net.au/linux/cAos/centos-3/3.1/extras/i386/ gpgcheck=1
CentOS Mirrors
After that you need to import the GPG key for the centos RPMs. Issue the following command:
# rpm --import http://mirror.centos.org/centos/3.1/i386/RPM-GPG-KEY-CentOS-3
Nows the time you want to check you have made appropriate backups, etc ( i hope you all test this out before rolling production servers! ).
Next step is to run the following command:
# yum upgrade
This will download the rpm headers and determine what needs to be done, play carefull attention of course here and in all parts if this process for errors. Yum will then ask you if you are sure you want to go ahead, if no errors are present, press "y" then "enter".
This process will take a while, depending on your connection and the gear your installing it on of course. Go brew a fresh pot of coffee, order a pizza, grab a movie or GET BACK TO WORK YOU!!!!
After thats done, check for errors, make sure the new kernel is installed by issueing:
# rpm -qa|grep kernel
You should be presented with a kernel versioned like this: 2.4.21-15.EL.c0 as well as your other kernels previously installed. Check your boot loader to make sure the new kernel is default.
Finally run:
# yum update
Just to ensure you have everything you need.
Now your set to reboot ( hopefully ):
shutdown -rf now
This worked like a charm for me, hope you all can make use of this somehowLast edited by anon-e-mouse; 05-28-2004 at 08:36 PM.
-
05-28-2004, 12:06 PM #2Newbie
- Join Date
- May 2004
- Posts
- 5
its little hard to do thast i think
-
05-28-2004, 06:47 PM #3Web Hosting Master
- Join Date
- Apr 2001
- Posts
- 2,611
Its fairly straight forward actually, what are you stuck on?
-
05-28-2004, 08:23 PM #4Problem Solver
- Join Date
- Mar 2003
- Location
- California USA
- Posts
- 13,681
yes looks very stright forword
Steven Ciaburri | Industry's Best Server Management - Rack911.com
Software Auditing - 400+ Vulnerabilities Found - Quote @ https://www.RACK911Labs.com
Fully Managed Dedicated Servers (Las Vegas, New York City, & Amsterdam) (AS62710)
FreeBSD & Linux Server Management, Security Auditing, Server Optimization, PCI Compliance
-
05-29-2004, 01:24 AM #5Problem Solver
- Join Date
- Mar 2003
- Location
- California USA
- Posts
- 13,681
[root@opium root]# uname -r
2.4.21-15.EL.c0
[root@opium root]# cat /etc/*release*
CentOS release 3.1 (final)
[root@opium root]#
Here's a direct admin box upgraded from rh9Steven Ciaburri | Industry's Best Server Management - Rack911.com
Software Auditing - 400+ Vulnerabilities Found - Quote @ https://www.RACK911Labs.com
Fully Managed Dedicated Servers (Las Vegas, New York City, & Amsterdam) (AS62710)
FreeBSD & Linux Server Management, Security Auditing, Server Optimization, PCI Compliance
-
05-29-2004, 04:42 AM #6Web Hosting Master
- Join Date
- Apr 2001
- Posts
- 2,611
thnx TLG for testing that out.. ur a legend!!
And just incase, cuz i've had a couple people have this issue now, if the EL kernel doesn't install ( rpm -qa | grep kernel <- to check + cat grub.conf ; else lilo.conf ), make sure you download the rpm and rpm -ivh kernelfilename.rpm and modify your boot loader ( be it lilo or grub ) before you reboot! The rpm can be found on any of the CentOS mirrors.
-
05-30-2004, 03:36 AM #7Problem Solver
- Join Date
- Mar 2003
- Location
- California USA
- Posts
- 13,681
The upgrade seems very stable. On a side note, it does not break anything with directadmin. I did not have to fix anything. I did however have to add a few http related thing to the skiplist and webalizer.
Steven Ciaburri | Industry's Best Server Management - Rack911.com
Software Auditing - 400+ Vulnerabilities Found - Quote @ https://www.RACK911Labs.com
Fully Managed Dedicated Servers (Las Vegas, New York City, & Amsterdam) (AS62710)
FreeBSD & Linux Server Management, Security Auditing, Server Optimization, PCI Compliance
-
07-17-2004, 09:12 PM #8New Member
- Join Date
- Jul 2004
- Posts
- 1
Originally posted by thelinuxguy
The upgrade seems very stable. On a side note, it does not break anything with directadmin. I did not have to fix anything. I did however have to add a few http related thing to the skiplist and webalizer.
now to play around with Tomcat and Java
-
07-19-2004, 01:27 AM #9Web Hosting Master
- Join Date
- Feb 2003
- Location
- Potsdam, NY
- Posts
- 648
has anyone tried this on cpanel boxes?
-
07-19-2004, 02:25 AM #10Web Hosting Master
- Join Date
- Apr 2001
- Posts
- 2,611
So far i've done 1 personal production redhat 9 cpanel box no problems. That box also had ircd's and eggdrops on it. No reported problems.
I've been in contact with others that have successfully migrated their cpanel rh9 to centos via this howto as well with no issues.
-
07-19-2004, 05:17 PM #11WHT Addict
- Join Date
- May 2003
- Posts
- 150
A good yum.conf for the USA
[main]
exclude=httpd* mysql* php* perl*
cachedir=/var/cache/yum
debuglevel=2
logfile=/var/log/yum.log
pkgpolicy=newest
distroverpkg=redhat-release
installonlypkgs=kernel kernel-smp kernel-hugemem kernel-enterprise kernel-debug kernel-unsupported kernel-smp-unsupported kernel-hugemem-unsupported
tolerant=1
exactarch=1
[base]
name=CentOS-$releasever - Base
baseurl=http://caos.nplus1.net/centos-3/3.1/os/i386/
gpgcheck=1
#released updates
[update]
name=CentOS-$releasever - Updates
baseurl=http://caos.nplus1.net/centos-3/3.1/updates/i386/
gpgcheck=1
#packages used/produced in the build but not released
[addons]
name=CentOS-$releasever - Addons
baseurl=http://caos.nplus1.net/centos-3/3.1/addons/i386/
gpgcheck=1
#additional packages that may be useful
[extras]
name=CentOS-$releasever - Extras
baseurl=http://caos.nplus1.net/centos-3/3.1/extras/i386/
gpgcheck=1Linux/cPanel How-To's - cPanelPlanet.com
-
08-21-2004, 11:43 AM #12Disabled
- Join Date
- Dec 2002
- Location
- Amsterdam/Rotterdam, NL
- Posts
- 2,135
Would this work for Fedora to Centos too?
-
08-21-2004, 07:49 PM #13Web Hosting Master
- Join Date
- Apr 2001
- Posts
- 2,611
Simple Answer: No! This how-to will not work with fedora as it is much newer than centos 3.1.
As fedora has newer technologies ( newer gcc, kernel, etc ) this would be a very trickey transition. In essence, you will be *downgrading* the box. I have not had the chance to test this as we only use 1 fedora box that we are migrating clients to a brand new box shortly, thus I have not personally had the need to do so.
Complicated answer: I know it has been done, but just what needs to be done to enable a smooth transition I am unsure of. You may want to contact thelinuxguy on these boards or through his web site: http://www.rack911.com as I am sure he's told me he has done it with success.
-
08-22-2004, 02:38 AM #14Disabled
- Join Date
- Dec 2002
- Location
- Amsterdam/Rotterdam, NL
- Posts
- 2,135
Hm that's too bad. The reason that I wanted to try it is that CentOS is much less of a beta product than Fedora is. The problem here would be that I'd have to upgrade the OS on about 50 machines every time they release a new version..
-
08-22-2004, 04:35 AM #15Problem Solver
- Join Date
- Mar 2003
- Location
- California USA
- Posts
- 13,681
if i had another test box with me i could make a tutorial probably.
Steven Ciaburri | Industry's Best Server Management - Rack911.com
Software Auditing - 400+ Vulnerabilities Found - Quote @ https://www.RACK911Labs.com
Fully Managed Dedicated Servers (Las Vegas, New York City, & Amsterdam) (AS62710)
FreeBSD & Linux Server Management, Security Auditing, Server Optimization, PCI Compliance
-
08-22-2004, 05:12 AM #16Retired Moderator
- Join Date
- Jul 2001
- Location
- Singapore
- Posts
- 1,889
Haze, did you try with:
Code:installonlypkgs=kernel*
Code:installonlypkgs=kernel kernel-smp kernel-hugemem kernel-enterprise kernel-debug kernel-unsupported kernel-smp-unsupported kernel-hugemem-unsupported
-
08-22-2004, 09:53 PM #17Web Hosting Master
- Join Date
- Apr 2001
- Posts
- 2,611
Choon,
That'd probably work just fine, infact, i see no reason why it wouldn't. I just basically used a default config that was either provided by yum-conf rpm or was modified by one of cpanels checkyum or safeyum scripts. At the time, since its a rather big transition, i just thought it'd be better to be safe than sorry.
-
08-23-2004, 01:12 AM #18Web Hosting Master
- Join Date
- Dec 2003
- Location
- Brisbane, Queensland, Australia
- Posts
- 550
Hi,
I was following the instructions and the following came up:
.....Unable to satisfy dependencies
Package mod_python needs httpd >= 2.0.40, this is not available.
Package mod_python needs httpd-mmn = 20020903, this is not available.
Package mod_ssl needs httpd = 2.0.46-32.ent.3.centos.1, this is not available.
Package mod_ssl needs httpd-mmn = 20020903, this is not available.
I am guessing i will need to update apache to 2.0.46 and higher for this CentOS configuration to work.
Is that correct?
-
08-23-2004, 01:29 AM #19Web Hosting Master
- Join Date
- Apr 2001
- Posts
- 2,611
Hrm.. is there any perticular reason you have those modules installed in the first place ?
Also, are you using apache from source or from rpm ? If you build apache from source, generally, you build modules from source anyways is why I ask.
-
08-23-2004, 02:03 AM #20Web Hosting Master
- Join Date
- Dec 2003
- Location
- Brisbane, Queensland, Australia
- Posts
- 550
This server is a stock cpanel server. So those modules are what came with the server when i took over it.
-
08-23-2004, 02:09 AM #21Web Hosting Master
- Join Date
- Apr 2001
- Posts
- 2,611
Well.. if you don't need them, why have them installed? Its wise to ensure you don't have anything installed you don't need. Especially with a new server and even moreso if you've been handed a server from someone else. A lot of linux distro's install a lot of programs that you will find useless especially with cpanel installed. So, seeing as your doing such a large move, you'd be best of to sort through what rpms you have installed and what you don't need. That way your upgrade will be a hell of a lot faster and less prone to problems such as you have already experienced.
-
08-23-2004, 02:31 AM #22Problem Solver
- Join Date
- Mar 2003
- Location
- California USA
- Posts
- 13,681
just rpm -e all the dependencys and continue installing.
Steven Ciaburri | Industry's Best Server Management - Rack911.com
Software Auditing - 400+ Vulnerabilities Found - Quote @ https://www.RACK911Labs.com
Fully Managed Dedicated Servers (Las Vegas, New York City, & Amsterdam) (AS62710)
FreeBSD & Linux Server Management, Security Auditing, Server Optimization, PCI Compliance
-
08-23-2004, 03:44 AM #23Web Hosting Master
- Join Date
- Dec 2003
- Location
- Brisbane, Queensland, Australia
- Posts
- 550
Thanks thelinuxguy,
Thanks all for this great howto and guidance. It was so easy to do. It worked without a hitch. Just need to test it.
Thanks again.
-
08-23-2004, 04:21 AM #24Disabled
- Join Date
- Dec 2002
- Location
- Amsterdam/Rotterdam, NL
- Posts
- 2,135
Just make sure not to rpm -e perl (it came up as a dependency once for me), so I removed it, but that messed up the whole yum script ofcourse..
Instead of rpm -e mod_python you could also add it to the exclude list..
-
08-23-2004, 01:46 PM #25Problem Solver
- Join Date
- Mar 2003
- Location
- California USA
- Posts
- 13,681
Adding it to the exclude list is not a good idea, it wont be updated and you could have a vulnerable version installed.
Steven Ciaburri | Industry's Best Server Management - Rack911.com
Software Auditing - 400+ Vulnerabilities Found - Quote @ https://www.RACK911Labs.com
Fully Managed Dedicated Servers (Las Vegas, New York City, & Amsterdam) (AS62710)
FreeBSD & Linux Server Management, Security Auditing, Server Optimization, PCI Compliance