Apache server imap.so ssl_once_only_init error
nightrecon at hotmail.com
Wed Oct 7 19:03:04 UTC 2009
David Southwell wrote:
>> Robert Huff wrote:
>> > David Southwell writes:
>> >> /libexec/ld-elf.so.1: /usr/local/lib/php/20060613/imap.so:
>> >> Undefined symbol "ssl_onceonlyinit"
>> > I look at this and ask (knowing very little about either) "is
>> > this a problem with Apache, or a problem with PHP?".
>> Easy enough to see - comment out the imap.so module in
>> /usr/local/etc/php/extensions.ini and see if Apache will start. If it
>> does the problem is the imap module. A more generic way to drive this
>> wedge is
>> to temporarily comment out the LoadModule php5_module line from
>> If it starts without this module it isn't Apache. Some PHP modules have
>> dependencies in that they need the other modules loaded before they load.
>> Try moving the imap.so line in extensions.ini to the bottom of the file
>> so all the other crypt modules such as openssl, hash, mcrypt, etc are
>> loaded first.
> Mike you are right on the ball.
> When I comment out the imap.so line in extensions.ini the server starts up
> normally. So now we have the culprit. That is after doing a portupgrade
> -frR mail/php5-imap.
> The question is where do I go from here??
Hrmmm. Probably need to look into more details. I am running Apache-
event-2.2.13 here with PHP5-5.2.11 and extensions-5.2.11, with PHP running
as FastCGI via the apache module mod_fcgid instead of mod_php. I presume you
are just doing the normal mod_php method.
Upon thinking about it a little more, I'm guessing that when you tried
relocating the extension=imap.so to the bottom of extensions.ini it had no
effect. Sometimes this is an easy and quick answer when the problem is just
load order. Another to consider is if you really do not require the imap
module just leave it commented out, although this is not elegant as it does
not attack the root source of the problem.
What I'm thinking (after looking at the actual error message again) is this
is a build-time problem and not runtime. I believe that these kinds of
symbol errors arise mostly from libraries being mismatched at build time.
To elaborate a little, I'm wondering if when you built mod_php at one point
in time and then built the php5-extensions at a later time if they were not
slightly different versions. Also, IIRC there was once a problem with the
imap module in that it could not be used with the recode and yaz modules. I
have the recode module present so I doubt it is a problem, but do not use
the yaz module. Might look and see about yaz.
I suspect the core of the problem is that mod_php and the extensions are
slightly out of sync with one another. A very sloppy thing to do would be to
just remove all the PHP stuff, including mod_php, update the ports tree
fresh and reinstall all of it at one time together. This may not be wise on
a production server however, as this will entail downtime. As I said -
"sloppy, scattergun approach". I have done this a time or two, but don't
really like doing it. YMMV
If mod_php and the extensions were built at different times, with maybe a
ports tree update in between, they may need to be all recompiled so they all
get linked correctly.
P.S. - And the biggest assumption of all I'm making is that Apache was built
with SSL support in the first place. A variable which should be eliminated.
More information about the freebsd-questions