hosted by liquidweb


Go Back   Web Hosting Talk : Web Hosting Main Forums : VPS Hosting : VPS Tutorials : Updating to CentOS Continuos Release (5.7and UP)
Reply

VPS Tutorials Tutorials related to VPS.
Forum Jump

Updating to CentOS Continuos Release (5.7and UP)

Reply Post New Thread In VPS Tutorials Subscription
 
Send news tip View All Posts Thread Tools Search this Thread Display Modes
  #1  
Old 08-16-2011, 05:16 PM
wartungsfenster wartungsfenster is offline
Web Hosting Master
 
Join Date: Mar 2010
Location: Germany
Posts: 553

Updating to CentOS Continuos Release (5.7and UP)


Hi,

I've made a howto for the update. Since the guidelines don't allow external documents, but I already formatted it in my howto site, I'll go mixed, and paste it in here. If you want the original, well, http://confluence.wartungsfenster.de...tinuos+Releaseclick.
The content is identical as of now but I'd recommend you check both places in case of updates. Or if you need it as pdf, for example.

---- here we go ----

Updating CentOS, forever
Yesterday the CentOS project released the Continuous Release (CR) repo which allows much faster tracking for Security updates that are added to RHEL.

It works as a yum repo that gets constant additions, but does not directly replace CentOS 5.7 which is planned to be released in the next 2 weeks or so.

To me, the release info seemed a little rushed and just to be on the safe side I'll start doing my updates right away.

I wrote down the steps and added some notes that might be helpful if you're updating more than just 1 or 2 boxes.

Impatient people with few servers and no care for experience, just look at the steps 1, 5 and 7.

People who already know how to restore a system broken during a rushed update and don't want to do that today might want to read the other steps, too.

Step 1:
Download the repository for your cpu arch (i686 & x86_64 only)

32bit users do:

cd /tmp && wget http://mirror.centos.org/centos/5.6/...tos.1.i386.rpm

64bit users do:

cd /tmp && wget http://mirror.centos.org/centos/5.6/...s.1.x86_64.rpm

Step 2:
Check you're already on CentOS 5.6 right now.



It's possible, but not fun, to jump more than 1 or 2 minor releases during a single upgrade.
If an RPM does any "fixes" in it's %pre or %post section it may fail badly.
So 5.5 to 5.6 or 5.7 is still quite ok, whereas 5.3 to 5.6 is already asking for major troble.

A almost current CentOS 5.6 would look like this:

# cat /etc/redhat-release ; uname -r
CentOS release 5.6 (Final)
2.6.18-238.12.1.el5xen
The most current 5.6 kernel is version 238.19.1

Step 3 (optional):
Test everything is really up-to-date
Run yum update.

On my box there was the following updates:

Installed:
kernel-xen.x86_64 0:2.6.18-238.19.1.el5

Updated:
curl.x86_64 0:7.15.5-9.el5_6.3
device-mapper-multipath.x86_64 0:0.4.7-42.el5_6.3
glibc.i686 0:2.5-58.el5_6.4
glibc.x86_64 0:2.5-58.el5_6.4
glibc-common.x86_64 0:2.5-58.el5_6.4
kpartx.x86_64 0:0.4.7-42.el5_6.3
krb5-libs.i386 0:1.6.1-55.el5_6.2
krb5-libs.x86_64 0:1.6.1-55.el5_6.2
krb5-workstation.x86_64 0:1.6.1-55.el5_6.2
ksh.x86_64 0:20100202-1.el5_6.6
nscd.x86_64 0:2.5-58.el5_6.4
perl.x86_64 4:5.8.8-32.el5_6.3

Complete!
Step 4 (recommended):
We're adding two yum plugins now:
yum-security plugin - this plugin is able to identify if you're missing any security updates.
It used to be a joke on CentOS but will now make a lot more sense once you get continous updates.

To use it you can later run:

yum --security check-update
Also we'll add the yum-download only plugin that allows to pre-fetch updates.

yum -y install yum-security yum-downloadonly
Step 5:
Installing the release rpm for CR will place the correct entry in /etc/yum/repos.d for yum to find.

32bit users:
rpm -i /tmp/centos-release-cr-5-6.el5.centos.1.i386.rpm
64bit users:
rpm -i /tmp/centos-release-cr-5-6.el5.centos.1.x86_64.rpm
Download the package list

yum makecache
Step 6 (optional):
Predownload the updates to your local cache directory.
&nbsp
This will be helpful if you want to run a backup before the update, and also if you want the update to be as fast as possible. Using the downloadonly plugin we'll just fetch the updates to yum's cache directory.
It'll be able to grab them from there and also you'll be able to distribute them to other system's cache directories.

yum update -y --downloadonly
Don't forget to clear the cache later on.

Step 7:
This is now the simple update.

yum -y update
In my case, on one of the test boxes the / filesystem would have run out of space.
Reason: I only provision around 500MB of space for / and during the first yum update I already had downloaded yet another kernel. Together these two bloaty kernels used up all available space as you can see above.
As you can see I took the lazy and fast way of this situation.

Error Summary
-------------
Disk Requirements:
At least 9MB needed on the / filesystem.
# cd /
# du -kx | sort -rn | head
369132 .
218222 ./lib
195754 ./lib/modules
97530 ./lib/modules/2.6.18-238.19.1.el5xen
97530 ./lib/modules/2.6.18-238.12.1.el5xen
# lvextend -L 1024 /dev/vg00/lvol00
Extending logical volume lvol00 to 1.00 GB
Logical volume lvol00 successfully resized
# /sbin/resize2fs /dev/vg00/lvol00
resize2fs 1.39 (29-May-2006)
Filesystem at /dev/vg00/lvol00 is mounted on /; on-line resizing required
Performing an on-line resize of /dev/vg00/lvol00 to 1048576 (1k) blocks.
The filesystem on /dev/vg00/lvol00 is now 1048576 blocks long.
Here you can see the skipped waste of timedownload:

Transaction Summary
================================================================================
Install 1 Package(s)
Upgrade 57 Package(s)

Total size: 87 M
Downloading Packages:
Running rpm_check_debug
Reference:
http://lists.centos.org/pipermail/ce...st/017689.html

Reply With Quote


Sponsored Links
  #2  
Old 08-17-2011, 12:35 PM
wartungsfenster wartungsfenster is offline
Web Hosting Master
 
Join Date: Mar 2010
Location: Germany
Posts: 553
any chance to edit out the typo from the subject?

Reply With Quote
Reply

Similar Threads
Thread Thread Starter Forum Replies Last Post
updating kernel on CentOS Lem0nHead Hosting Security and Technology 8 03-03-2010 02:42 PM
Question about updating centos 5.2 to 5.4 with cpanel tegralens VPS Hosting 7 02-17-2010 10:14 AM
CentOS v5.3 Release Information jcy1978 Hosting Security and Technology 0 03-25-2009 06:16 PM
updating php4 to php5 on centos ZonePlate Hosting Security and Technology 4 08-27-2007 04:54 PM
Updating centOS 3.4 with Yum That Guy VPS Hosting 2 01-06-2007 07:01 AM

Related posts from TheWhir.com
Title Type Date Posted
Solar VPS Becomes Official Mirror for Centos and Ubuntu Web Hosting News 2013-04-16 11:03:34
Web Host Rackspace Adds FreeBSD 9, CentOS 6.3 Support to Cloud Servers Web Hosting News 2012-07-30 12:47:10
Web Host ServerPronto Donates Hosting Resources to CentOS Web Hosting News 2012-07-05 14:06:27
Web Host myhosting.com Updates Shared Hosting Plans Web Hosting News 2011-10-20 18:46:01
Web Host NetHosting Announces Support for CentOS 6 Web Hosting News 2011-07-05 20:15:20


Tags
5.7, centos, continuous release, update

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes
Postbit Selector

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump
Login:
Log in with your username and password
Username:
Password:



Forgot Password?
Advertisement:
Web Hosting News:



 

X

Welcome to WebHostingTalk.com

Create your username to jump into the discussion!

WebHostingTalk.com is the largest, most influentual web hosting community on the Internet. Join us by filling in the form below.


(4 digit year)

Already a member?