Below are the instructions that worked for me to bring a CentOS 3.4 server with DA up to 4.0. Instructions is a variation of this one.
Disclaimer: I attempted this upgrade several times both remotely and on local test machines--failing plenty of attempts. The below instructions are what ultimately worked for me and may not work for everyone else.
# wget http://mirror.trouble-free.net/cAos/centos/RPM-GPG-KEY-CentOS-4
# wget http://mirror.trouble-free.net/cAos/centos/4.0/os/i386/CentOS/RPMS/centos-release-4-0.1.i386.rpm
# rpm --import RPM-GPG-KEY-CentOS-4
# rpm -Uvh centos-release-4-0.1.i386.rpm
# yum install glibc glibc-common
# yum install (kernel or kernel-smp)
On my server I experienced a conflict with lvm2.
# cd /var/cache/yum/base/packages
# rpm -Fvh --replacefiles lvm2*.rpm
At this stage I downloaded my own kernel source and compiled it using the config file from /boot/config-2.6.9-5.0.3.EL
After installing the kernel I made an initrd image:
# cd /boot
# mkinitrd initrd-2.6.11.5-1.img 2.6.11.5
Optional step:
Configure your bootloader of choice at this point. Waiting until the end may cause further complications. I set up 2 entires for the new kernel but with different initrd images because we'll be creating one later as well.
Remove the 2.4 kernel rpms because they conflict with the new udev system.
# rpm -e kernel-smp-2.4.21-27.0.2.EL (the release number may vary depending on your system)
There will be a conflict with /etc/aliases from the da_exim package and setup-2.5.37-1.1.noarch.rpm.
# cp /etc/aliases /etc/aliases.bak
# rpm -Fvh --replacefiles /var/cache/yum/base/packages/setup-2.5.37-1.1.noarch.rpm
# mv /etc/aliases.bak /etc/aliases
Now it's time to run the yum upgrade and hope for the best.
# yum upgrade
Need to make another initrd image at this point because which one works seems to be anyone's guess.
# mkinitrd /boot/initrd-2.6.11.5-2.img 2.6.11.5
Optional step:
If you waited until now to configure your bootloader you may run into a problem since the /dev system is gone. With grub I did not have a problem and all I did was edit grub.conf and added 2 entries for the new kernel (one for each initrd image) If you use lilo you'll have to run lilo to update the boot record, and it will complain that /dev/hdaX does not exist. Solution:
# MAKDEV -d /dev hda (replace hda with the appropriate drive where your install resides)
Time for the reboot. I set lilo/grub to boot the 2.6.11.5 kernel with initrd-2.6.11.5-2.img (the second initrd image) because using the first one hangs the system on "Switching to new root"
# reboot
The system took some time to come back up, and may even run an fschk.
Once back up apache and da-popb4smtp would not run due to library errors.
For apache recompiling will solve the problem.
# cd /usr/local/directadmin/customapache
# ./build clean
# ./build all
Fixing da-popb4smtp simply required a library to be installed.
# yum install compat-libstdc++-33
# service da-popb4smtp start
As indicated further down in the original thread you'll want to install the newer rpmdb package and remove the old one.
# wget http://mirror.trouble-free.net/cAos...tOS/RPMS/rpmdb-CentOS-4.0-0.20050228.i386.rpm
# rpm --force -ivh rpmdb-CentOS-4.0-0.20050228.i386.rpm
# rpm -e rpmdb-redhat-3.4-0.20050105
Rebuild the rpm database just to be thorough.
# rm -f /var/lib/rpm/__db* && rpm --rebuilddb
* Added:
IMAP server was looking for libcom_err.so.3 just as apache/php was.
# cd /usr/lib
# ln -s libcom_err.so libcom_err.so.3
The end! Hopefully at this point everything is up and running without problem.
Disclaimer: I attempted this upgrade several times both remotely and on local test machines--failing plenty of attempts. The below instructions are what ultimately worked for me and may not work for everyone else.
# wget http://mirror.trouble-free.net/cAos/centos/RPM-GPG-KEY-CentOS-4
# wget http://mirror.trouble-free.net/cAos/centos/4.0/os/i386/CentOS/RPMS/centos-release-4-0.1.i386.rpm
# rpm --import RPM-GPG-KEY-CentOS-4
# rpm -Uvh centos-release-4-0.1.i386.rpm
# yum install glibc glibc-common
# yum install (kernel or kernel-smp)
On my server I experienced a conflict with lvm2.
# cd /var/cache/yum/base/packages
# rpm -Fvh --replacefiles lvm2*.rpm
At this stage I downloaded my own kernel source and compiled it using the config file from /boot/config-2.6.9-5.0.3.EL
After installing the kernel I made an initrd image:
# cd /boot
# mkinitrd initrd-2.6.11.5-1.img 2.6.11.5
Optional step:
Configure your bootloader of choice at this point. Waiting until the end may cause further complications. I set up 2 entires for the new kernel but with different initrd images because we'll be creating one later as well.
Remove the 2.4 kernel rpms because they conflict with the new udev system.
# rpm -e kernel-smp-2.4.21-27.0.2.EL (the release number may vary depending on your system)
There will be a conflict with /etc/aliases from the da_exim package and setup-2.5.37-1.1.noarch.rpm.
# cp /etc/aliases /etc/aliases.bak
# rpm -Fvh --replacefiles /var/cache/yum/base/packages/setup-2.5.37-1.1.noarch.rpm
# mv /etc/aliases.bak /etc/aliases
Now it's time to run the yum upgrade and hope for the best.
# yum upgrade
Need to make another initrd image at this point because which one works seems to be anyone's guess.
# mkinitrd /boot/initrd-2.6.11.5-2.img 2.6.11.5
Optional step:
If you waited until now to configure your bootloader you may run into a problem since the /dev system is gone. With grub I did not have a problem and all I did was edit grub.conf and added 2 entries for the new kernel (one for each initrd image) If you use lilo you'll have to run lilo to update the boot record, and it will complain that /dev/hdaX does not exist. Solution:
# MAKDEV -d /dev hda (replace hda with the appropriate drive where your install resides)
Time for the reboot. I set lilo/grub to boot the 2.6.11.5 kernel with initrd-2.6.11.5-2.img (the second initrd image) because using the first one hangs the system on "Switching to new root"
# reboot
The system took some time to come back up, and may even run an fschk.
Once back up apache and da-popb4smtp would not run due to library errors.
For apache recompiling will solve the problem.
# cd /usr/local/directadmin/customapache
# ./build clean
# ./build all
Fixing da-popb4smtp simply required a library to be installed.
# yum install compat-libstdc++-33
# service da-popb4smtp start
As indicated further down in the original thread you'll want to install the newer rpmdb package and remove the old one.
# wget http://mirror.trouble-free.net/cAos...tOS/RPMS/rpmdb-CentOS-4.0-0.20050228.i386.rpm
# rpm --force -ivh rpmdb-CentOS-4.0-0.20050228.i386.rpm
# rpm -e rpmdb-redhat-3.4-0.20050105
Rebuild the rpm database just to be thorough.
# rm -f /var/lib/rpm/__db* && rpm --rebuilddb
* Added:
IMAP server was looking for libcom_err.so.3 just as apache/php was.
# cd /usr/lib
# ln -s libcom_err.so libcom_err.so.3
The end! Hopefully at this point everything is up and running without problem.
Last edited: