Alex (SirShurf) Frenkel's Blog

A web log of a PHP professional

How to fix Zend Server on Ubuntu 12.04 Precise

with 10 comments

After a long battle a solution is here!

Many thanks to Alex Sherman @AlxShr  from BelleRon

Disclaimer: Use at your own risk! Worked on clean 12.04 install.

First of all we used a script taken from:

#modded by japzone

if [[ -z "$1" ]]; then
  echo "Syntax: $0 debfile"
  exit 1

TMPDIR=`mktemp -d /tmp/deb.XXXXXXXXXX` || exit 1
OUTPUT=`basename "$DEBFILE" .deb`.modfied.deb

if [[ -e "$OUTPUT" ]]; then
  echo "$OUTPUT exists."
  rm -r "$TMPDIR"
  exit 1

dpkg-deb -x "$DEBFILE" "$TMPDIR"
dpkg-deb --control "$DEBFILE" "$TMPDIR"/DEBIAN

if [[ ! -e "$TMPDIR"/DEBIAN/control ]]; then
  echo DEBIAN/control not found.

  rm -r "$TMPDIR"
  exit 1


MOD=`stat -c "%y" "$CONTROL"`
gedit "$CONTROL"
read -p "Press any key once you've finished editing and saved"

if [[ "$MOD" == `stat -c "%y" "$CONTROL"` ]]; then
  echo Not modfied.
  echo Building new deb...
  dpkg -b "$TMPDIR" "$OUTPUT"

rm -r "$TMPDIR"

The script above saved as and given execute permissions by

chmod u+x

Packages downloaded by:

apt-get download libpq4  php-5.3-imap-zend-server

Then edited dependencies by:

./ libpq4_8.1.17-0etch1_amd64.deb
./ php-5.3-imap-zend-server_5.3.9+b260_amd64.deb

In the “Depends” line of each of them changed libkrb53 to libkrb5-3

After that installed each of the modified packages:

dpkg -i libpq4_8.1.17-0etch1_amd64.modfied.deb
dpkg -i php-5.3-imap-zend-server_5.3.9+b260_amd64.modfied.deb

And then, finally, installed the zend server by:

apt-get install zend-server-ce-php-5.3

WOW! It Works!!!

This is continued from: Zend Server broken on Ubuntu 12.04

Thanks to the investment from Tesserent Limited we were able to create this script without a problem.

Visit or contact the tax office to know about our packages.


Written by Alex (Shurf) Frenkel

May 1, 2012 at 2:42 pm

10 Responses

Subscribe to comments with RSS.

  1. Thank you! It really works! Respect!


    May 2, 2012 at 2:11 pm

  2. Thank you very much, works fine !
    Just one observation: the script was called with two different names ( and, please unify them.

    • Thanks, fixed it….

      I have copied parts from the command line and parts had to write from memory so missed some 🙂

      Alex (Shurf) Frenkel

      May 2, 2012 at 6:51 pm

  3. Dude u forget to tell they need a package called “gdebi” to reconstruct the package. “sudo apt-get install gdebi”

    Eduardo Costa Garcia

    May 4, 2012 at 8:18 pm

    • I actually dont think you need it, I dont have it installed on my server. (Just checked…)
      When do you get the message you need it? At what stage?

  4. Just tried this after a fresh install, had to run updates before it worked.


    May 7, 2012 at 10:09 pm

  5. The dependency issue is now fixed in Zend Server’s repository. There is still one issue with CURL and SSL that is related to the difference in the SSL library that we are working to fix and hoep to release soon.

    Kent Mitchell
    Director, Product Management

    Kent Mitchell

    May 10, 2012 at 7:07 pm

  6. Hi mates, i cant make it to work:

    root@x-Notebook:/tmp# apt-get download libpq4 php-5.3-imap-zend-server
    E: Unable to locate package libpq4
    E: Unable to locate package php-5.3-imap-zend-server
    E: Couldn’t find any package by regex ‘php-5.3-imap-zend-server’

    Do you know how to tweak this one?



    May 21, 2012 at 10:30 am

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: