[Mailman-Users] ImportError: No module named ldap
mike.rosile at interzonegames.com
Thu Jul 26 04:55:12 CEST 2007
Mark Sapiro wrote:
> Mike Rosile wrote:
>> Mark Sapiro wrote:
>>> I'm guessing that the command line python invocation finds the ldap
>>> module because its path is in the PYTHONPATH environment variable.
>>> This doesn't work with the Mailman CGI wrapper because the wrapper
>>> resets PYTHONPATH to contain only the path to the Mailman modules.
>>> If this is the issue, I suggest you install the ldap module in your
>>> python library site-packages/ directory.
>> Unfortunately I tried that, both /usr/lib/python2.4/site-packages and
>> /usr/local/lib/python2.4/site-packages, no luck.
> Was there a site-packages/ directory in either of these places to begin
Yes, both locations already had a sites-packages directory, although I'm
not sure if that was the case during the initial install of mailman.
> Is there currently a PYTHONPATH environment variable set in your shell
> pointing to the ldap module?
No, no PYTHONPATH environment variable for my shell or the system.
>>> Another possibility is that mailman was configured with a different
>>> python from the current command line python, in which the ldap module
>>> is installed.
>> Both mailman and python2.4 were installed using binary packages that are
>> apart of Ubuntu. Mailman's error log shows the same version as when I
>> execute python from the command line. Do you think it would be
>> beneficial to re-install mailman, perhaps from a tar ball?
> No. I don't think this will help, but I do think that possibly
> reinstalling python-ldap will help. How was this initially installed?
> Was it from source or a Debian/Ubuntu package
Yes, python-ldap was also installed as an Ubuntu package.
I do have python2.4 and python2.5 Ubuntu packages installed, however as
far as I can tell *everything* points to python2.4.
The python-ldap module exists in:
and is named _ldap.so, if that helps any.
I can certainly try a re-install of python-ldap, perhaps this time from
More information about the Mailman-Users