« Previous | Next»

Manually upgrading horde3 on debian

Posted by coldtobi | 19 Feb, 2009, 00:15 Debian is currently in freeze. (As finishing this, debian just released Lenny!) As a consequence many packages are quite outdated.

For example, the horde framework I use on my NAS is quite old and misses some features I'd like to have.

However, there are some pitfalls when using the debian version and trying to update with the upstream version, as the "debian way" stores some files at different locations, which is ok.

The files stored differently are the horde's configuration files. But keeping the configuration is essential for a painless upgrade.

So here's a micro tutorial how to manually update horde3 in debian. Upgrade means, that you already have horde installed with debian packages.

Note: The packaging system will not get aware of the updates, so on this tutorial you should be aware of the possible side-effects when you update the next time using debian packages.

1. Backup your current installation

Please backup your current installation, just in case something gets wrong. Also this howto might be missing some (for your installation) essential step.

You should at least backup
  • the configuration at /etc/horde
  • horde's directory at /usr/share/horde3
I suggest using "tar", as these make a nice single-file archive which can be kept somewhere safe.

2. Get the new packages

Log in into your current horde installation as your administrator user and go to the "Administation->Setup" Tab. Click on the "Check Versions" Button:

As you can see, horde can check the versions and will show you all new versions and also link to the new versions.

Download all the packages you'd like to update. I suggest you create a temporary directory to hold all the downloaded files.

(You should at always update the "horde" framework when installing other updated as they might depend on the newer framework). My suggestion: Update all.

3. Unpack them to a temporary directory

Untar all the archives into a temporary directory.

4. "Debianize" the temporary directory

For each package you get your own directory which contains also the pacakges configuration direcotory. As in all unixes, configurations should be stored under /etc/ rather the package's directory, we'll need to set a link to the configuration directory.

But updating the configuration also requires also, that one file has to be replaced: conf.xml.
If this is not done, horde won't work anymore afterwards.
So for each package to be updated do the following: (fill in the <placeholders>)
  1. copy <application_new_version_dir>/conf/conf.xml to /etc/horde/<application>/conf.xml
  2. delete <application_new_version_dir>/conf/ (whole dir)
  3. make a symbolic link from <application_new_version_dir>/conf/ to /etc/horde/<package>

5. Activate the new installation and update configuration

Now it is time to activate the new files.

For this it is best to work with a staging directory: Make a copy of your current installation and then apply the updated to this directory. (for example: cp -r /usr/share/horde3 ~/horde3_stage)

(BTW <temp/package> is the directory where you unpacked and the new version. <stage> is the staging directory)

If you update the framework itself too, it might be easier to use the temporary directory as staging area.

Updating the horde framework itself
If you are planning to update the horde3 framework first delete all directories in the framework which are NOT horde applications. (these are named as the application itself) and then copy the content of your unpacked horde update (<temp>/horde3) to the <stage>.

Updating the Applications
After you updated the framework, replace the application-directory's content in <stage> with the content in <temp>. (Hint: Delete the dir with and then mv the new content in place -- this is usually faster)

Repeat that for all applications.

Activate the new version.
To activate the new, just move the "old" version out of the way and move in the new version:
mv /usr/share/horde3 ~/horde3_old
mv <stage> /usr/share/horde3
And the new version should running.... Go to the administration tab as you need to recreate the configuration as horde will tell you (see the above screenshot for an example.)

Linux / Debian, Tips and Tricks, Thecus N2100 | Comments (0) | Trackbacks (0)

Related Articles:

0 Comments | "Manually upgrading horde3 on debian" »