I was having trouble with a server running Debian 4.0 (etch). Using the standard sources in the /etc/apt/sources.list the supported PHP5 version was 5.2.0-8+etch13 which contained a very annoying bug for my application.
A daily running script – let’s call it the Importer – regularly exited randomly with a “Fatal error: Out of memory (allocated 12320768) (tried to allocate 2851436 bytes) in …” and I had to restart it manually nearly every morning. I had…
- …checked my application for memory wasting operations and loops and fixed them,
- …used ini_set(‘memory_limit’, ’64M’); at runtime, and
- …finally increased memory_limit = 64M in my php.ini.
But all this did not change the bahaviour of the Importer!
So I took a look at the PHP5 Changelog to find potentially fixed bugs in newer releases. Bug #39438 described exactly my problem. So a simple upgrade would help me. But it did not work with ‘apt-get upgrade’ or ‘apt-get install php5=5.2.8′ since the highest version in the apt source I used was the one that I already had: 5.2.0-8+etch13, issued in November 2006… (pretty ancient)
Finally it was this page that had the information we needed: an alternative apt source
deb http://packages.dotdeb.org etch all
deb-src http://packages.dotdeb.org etch all
After getting an impression whether dotdeb was a trustworthy source, we first tried it on our dev-system with ‘apt-get update; apt-get upgrade;’. At this point I was once more glad to have written so many UnitTests. They all passed and everything looked good.
Thanks Kim for your help!