Installing Zimbra 4.5.x on Ubuntu 7.04 & 7.10 (Feisty Fawn & Gutsy Gibbon)

Admin Article

Article Information

This article applies to the following ZCS versions.

ZCS 4.5 Article ZCS 4.5

Make Ubuntu 7 Appear as if your running 6

The install.sh script triggers zcs_get_plat_tag.sh in zcs/bin to find the release version, and the script is hardwired to version numbers.

So here we're going to trick it into thinking it's ubuntu 6 instead of 7. (You can do something similar with, for example, Fedora Core 7 by lowering the version number in /etc/redhat-release down to 5.)

Method 1 (easiest)

  • Zimbra is intended for the ancient Ubuntu 6.06LTS
  • A newer Ubuntu works fine, but the installer must believe it is 6.06
  • Additionally, the installer interprets later Ubuntus as Debian (the upstream Linux)

Two things causes installer issues

  • /etc/lsb-release contains a line DISTRIB_RELEASE=7.10
    • the characters 7.10 needs to be 6.06
  • /etc/debian_version exists
    • needs to be renamed while the installer runs

This has been proven for through Ubuntu 7.10 and Zimbra through 5.0 RC2

bash suggestion:

edit /etc/lsb-release and change the DISTRIB_RELEASE= to just 6

For Zimbra 4.5.9 or later, the zcs_get_plat_tag.sh checks for /etc/debian_version as well. Therefore, you need to move /etc/debian_version out of the way while you run the installer. The alternative method 3 listed below will not work since the installer re-copies the original zcs_get_plat_tag.sh for use by the post-installation tasks. This will prevent your installation from completing correctly.

mv /etc/debian_version /etc/debian_version.zimbra

Run ./install.sh with sudo. If you have a password for the root account, and have used that to edit /etc/lsb-release, please logout and login again to update the enviroment, install.sh will complain otherwise

I've noticed that the installation will fail, at least for me on a couple of newly installed Ubuntu 7.10, even when dependencies are met - broken packages! In case the installation fail on core-package, execute:

apt-get check
apt-get -f install
./install.sh --uninstall
./install.sh

Then just remember to rename /etc/debian_version.zimbra back to the original file name and change /etc/lsb-release to the original values after the installation.

Just another Perl programmer suggestion:

Gutsy 7.10 also has /etc/debian_version but as of Tribe5 that is not picked up properly by the get_plat_tag.sh script.

mv /etc/debian_version /etc/debian_version.zimbra
perl -pi -e 's/DISTRIB_RELEASE=7/DISTRIB_RELEASE=6/' /etc/lsb-release

Problem is that Feisty also has a /etc/debian_version that reads '4.0' and the new 5.0b3 incorrectly reads this - allegedly Debian 4.0 support is new in zimbra 5.0b. Gutsy also has /etc/debian_version but as of Tribe5 it has version that is not picked up by the get_plat_tag.sh script

Method 2

edit util/utilfunc.sh
change
if [ $PLATFORM = "DEBIAN3.1" -o $PLATFORM = "UBUNTU6" ]; then
to
if [ $PLATFORM = "DEBIAN3.1" -o $PLATFORM = "UBUNTU6" -o $PLATFORM = "UBUNTUUNKNOWN" ]; then

change
if [ $PLATFORM = "UBUNTU6" ]; then
to
if [ $PLATFORM = "UBUNTU6" -o $PLATFORM = "UBUNTUUNKNOWN" ]; then

edit
util/modules/platform.sh
change
if [ $PLATFORM = "DEBIAN3.1" -o $PLATFORM = "MANDRIVA2006" -o $PLATFORM = "UBUNTU6" ]; then
to
if [ $PLATFORM = "DEBIAN3.1" -o $PLATFORM = "MANDRIVA2006" -o $PLATFORM = "UBUNTU6" -o $PLATFORM = "UBUNTUUNKNOWN" ]; then


They both do pretty much same thing so 1 is easier, especially as you'll need to change back to showing as 7.04/7.10 as soon as your finished with the install.



Method 3: Edit the Installer

If you don't want to touch the config files, the alternative is to edit zcs_get_plat_tag.sh itself.

For example, with Ubuntu, find the two lines:

       grep "DISTRIB_RELEASE=6" /etc/lsb-release > /dev/null 2>&1
       if [ $? = 0 ]; then

and replace them with:

       ver=$(grep "DISTRIB_RELEASE" /etc/lsb-release | cut -d= -f2 | cut -d\. -f1)
       if [ ${ver} -ge 6 ]; then




Ubuntu 64bit

(HOWTO grabbed from a forum post by dijichi)-Mmorse

5.0beta running on Ubuntu 7.10 gutsy tribe 3 64bit.

Confirmed to work for Zimbra 4.5.6, and also Ubuntu 6.06LTS 64bit.

No obvious reason why it shouldn't work for 6.10 or 7.04 'feisty' either.

Do the whole thing below as root: sudo su - I know Ubuntu is often used by 'newbies' but I find it horrendously irritating and patronizing not to be given root shell

Install Ubuntu 64bit Setup DNS etc as normal

Download these files, put them in the same directory (eg. /tmp/zimbra-install or something): SourceForge.net: Files (Zimbra 4.5.6 Ubuntu6 32-bit package) ActiveState ActivePerl (you want Linux x86 version, NOT x64 version, deb packaging) 32bit OS Libs

If 6.10 or 7.x feisty or gutsy release:

cp /etc/lsb-release /etc/prezimbra.lsb-release
change /etc/lsb-release to:
DISTRIB_RELEASE=6
apt-get install ia32-libs
apt-get install libidn11 curl fetchmail libpcre3 libgmp3c2 libexpat1 libxml2 libstdc++6 libstdc++5
# download zimbra-32bit-libs.tar.gz, should be attached to this post
tar -xzf zimbra-32bit-libs.tar.gz
mv lib32/* /usr/lib32
ldconfig
dpkg --force-architecture -i ActivePerl-5.8.8.......blah.blah....deb

mv /usr/bin/perl /usr/bin/perl.ubuntu
ln -s /opt/ActivePerl-5.8/bin/perl /usr/bin/perl.activestate
ln -s /usr/bin/perl.activestate /usr/bin/perl
# make sure sh is bash, not dash
ls -l /bin/sh
if: /bin/sh -> bash then ok, otherwise
rm /bin/sh
ln -s /bin/bash /bin/sh
tar -xzf zcs-5.0.0_BETA3_1276.UBUNTU6.20070822122320
cd zcs-5.0.0_BETA3_1276.UBUNTU6.20070822122320
export LANG='C'
perl -pi -e 's/dpkg -i/dpkg --force-architecture -i/' util/utilfunc.sh
sh install.sh
# Run through installer as normal. When finished, it starts zimbra, initialises documents, restarts tomcat then says 'Configuration complete - press return to exit'. Press return to get back to root prompt.
# Stop zimbra
/etc/init.d/zimbra stop
# make sure everything has stopped
ps -ef |grep zimbra |grep -v grep
# if anything still running, kill it
kill (pid)
# if it won't die
kill -9 (pid)
# refactor perl paths
perl -pi -e 's#/usr/bin/perl#/opt/ActivePerl-5.8/bin/perl#' `find /opt/zimbra -type f -exec grep -l '/usr/bin/perl' {} \;`
# put ubuntu perl back
rm /usr/bin/perl
ln -s /usr/bin/perl.ubuntu /usr/bin/perl
# restart zimbra
/etc/init.d/zimbra start
# make sure everything running ok
su - zimbra zmcontrol status

Jump to: navigation, search