Hi Graham

I confirm the fix works for my system.

Thanks for seeing to it.

Liam

On Tuesday, 1 July 2014 13:53:52 UTC+2, Graham Dumpleton wrote:
>
> Fix has been released with mod_wsgi 4.2.5.
>
> https://pypi.python.org/pypi/mod_wsgi
>
> Remove the envvars file override you put in place when upgrading.
>
> Thanks for bringing the issue to my attention. In my own Apache 2.4 
> installation, with dynamically loadable MPM modules, I only had worker MPM 
> .so installed and not prefork MPM .so as well, so didn't notice the 
> problem. I have both installed now so will notice if I break something down 
> the track related to this.
>
> Graham
>
> On 01/07/2014, at 7:14 PM, Liam Thompson <[email protected] <javascript:>> 
> wrote:
>
>
>
> On Tuesday, 1 July 2014 02:51:29 UTC+2, Graham Dumpleton wrote:
>>
>> I am after the settings at the head of:
>>
>>   /tmp/mod_wsgi-localhost:8000:1000/apachectl
>>
>> Specifically, what is HTTPD in that file set to.
>>
>
>
> Right sorry
>
> HTTPD="/usr/sbin/apache2 -f /tmp/mod_wsgi-localhost:8000:1000/httpd.conf 
> -DWSGI_MPM_EVENT_MODULE -DWSGI_MPM_WORKER_MODULE -DWSGI_MPM_PREFORK_MODULE"
>
>  
>
>>
>> I suspect the problem is the code:
>>
>> def _mpm_module_defines(modules_directory):
>>     result = []
>>     workers = ['event', 'worker', 'prefork']
>>     for name in workers:
>>         if os.path.exists(os.path.join(modules_directory,
>>                 'mod_mpm_%s.so' % name)):
>>             result.append('-DWSGI_MPM_%s_MODULE' % name.upper())
>>     return result
>>
>> It should be breaking out of the loop after result.append().
>>
>> It is likely adding more than one of:
>>
>> WSGI_MPM_EVENT_MODULE
>> WSGI_MPM_WORKER_MODULE
>> WSGI_MPM_PREFORK_MODULE
>>
>> and so trying to load more than one.
>>
>> The solution you can like use for now is to create/edit the file:
>>
>>   /tmp/mod_wsgi-localhost:8000:1000/envvars
>>
>> Take from /tmp/mod_wsgi-localhost:8000:1000/apachectl the HTTPD variable 
>> line and copy it into the envvars file.
>>
>> Edit the HTTPD setting in envvars to drop out all but one of the MPM -D 
>> options. Give preference to event or worker MPM over prefork.
>>
>
> I created the envvars file and put in
>
> HTTPD="/usr/sbin/apache2 -f /tmp/mod_wsgi-localhost:8000:1000/httpd.conf 
> -DWSGI_MPM_WORKER_MODULE"
>
> and I get "my web site runs on Malt Whiskey", so it's working now.
>
> Thanks for the suggestions
>
> Liam
>
>  
>
>>
>> Graham
>>
>> On 30/06/2014, at 11:51 PM, Liam Thompson <[email protected]> wrote:
>>
>> Hi Graham
>>
>> On Monday, 30 June 2014 13:54:27 UTC+2, Graham Dumpleton wrote:
>>>
>>>
>>> On 30/06/2014, at 9:21 PM, Graham Dumpleton <[email protected]> 
>>> wrote:
>>>
>>>
>>> On 30/06/2014, at 8:31 PM, Liam Thompson <[email protected]> wrote:
>>>
>>> Hi there
>>>
>>> I am trying to get the mod_wsgi-express PyPi package working on my 
>>> system in virtualenv with Apache 2.4.6 running Ubuntu 13.10, fully updated. 
>>> The system I'm developing for unfortunately needs to run 2.6.9, so there 
>>> is a discrepancy between the needed python and the system default (2.7.5) 
>>> and the compiled mod_wsgi.
>>>
>>> In any event, following the instructions on PyPi I am getting 
>>>
>>> "AH00534: apache2: Configuration error: More than one MPM loaded."
>>>
>>>
>>> Exactly what version of mod_wsgi are you installing?
>>>
>>> The mod_wsgi in the pip installation is 4.2.4
>>
>> The base mod_wsgi version installed on my system 3.4 (a little behind the 
>> times I know, I generally rely on the Ubuntu repos rather than bleeding 
>> edge).
>>
>>
>>> What do you get when you run:
>>>
>>>   /usr/sbin/apache2 -M 
>>>
>>> Loaded Modules:
>>  core_module (static)
>>  so_module (static)
>>  watchdog_module (static)
>>  http_module (static)
>>  log_config_module (static)
>>  logio_module (static)
>>  version_module (static)
>>  unixd_module (static)
>>  access_compat_module (shared)
>>  alias_module (shared)
>>  auth_basic_module (shared)
>>  authn_core_module (shared)
>>  authn_file_module (shared)
>>  authz_core_module (shared)
>>  authz_host_module (shared)
>>  authz_user_module (shared)
>>  autoindex_module (shared)
>>  cgi_module (shared)
>>  dav_module (shared)
>>  dav_fs_module (shared)
>>  deflate_module (shared)
>>  dir_module (shared)
>>  env_module (shared)
>>  filter_module (shared)
>>  headers_module (shared)
>>  mime_module (shared)
>>  mpm_prefork_module (shared)
>>  negotiation_module (shared)
>>  php5_module (shared)
>>  rewrite_module (shared)
>>  setenvif_module (shared)
>>  socache_shmcb_module (shared)
>>  ssl_module (shared)
>>  status_module (shared)
>>  upload_progress_module (shared)
>>  wsgi_module (shared)
>>  xsendfile_module (shared)
>>  
>>
>>> when trying to run 
>>>
>>> "mod_wsgi-express start-server apache/apache.wsgi --port 8001 
>>> --httpd-executable=/usr/sbin/apache2 --user=www-data --group=www-data"
>>>
>>>
>>> You don't need the options:
>>>
>>>    --user=www-data --group=www-data
>>>
>>> if you are running as normal user, they will do nothing. They should 
>>> only be needed in special cases if using 'setup-server' to allow creation 
>>> of scripts to later run as root.
>>>
>>> What are the following set to in the 'apachectl' directory created under 
>>> the temporary 'Server Root' created by mod_wsgi express when you don't 
>>> supply any options?
>>>
>>>
>>> And the missing bit was what are these set to when you don't supply any 
>>> options.
>>>
>>> HTTPD="/usr/sbin/httpd -f /tmp/mod_wsgi-localhost:8000:502/httpd.conf 
>>> -DWSGI_SERVER_METRICS"
>>>
>>> WSGI_RUN_USER="${WSGI_RUN_USER:-graham}"
>>> WSGI_RUN_GROUP="${WSGI_RUN_GROUP:-staff}"
>>>
>>> Graham
>>>
>>
>> A simple mod_wsgi-express start-sevrer gives me below (I hope this is 
>> what you meant)
>>
>> Server URL        : http://localhost:8000/
>> Server Root       : /tmp/mod_wsgi-localhost:8000:1000
>> Server Conf       : /tmp/mod_wsgi-localhost:8000:1000/httpd.conf
>> Error Log File    : /tmp/mod_wsgi-localhost:8000:1000/error_log
>> AH00534: apache2: Configuration error: More than one MPM loaded.
>>
>> My username id is 1000.
>>
>> Thanks
>> Liam
>>
>>  
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "modwsgi" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected].
>> To post to this group, send email to [email protected].
>> Visit this group at http://groups.google.com/group/modwsgi.
>> For more options, visit https://groups.google.com/d/optout.
>>
>>
>>
> -- 
> You received this message because you are subscribed to the Google Groups 
> "modwsgi" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected] <javascript:>.
> To post to this group, send email to [email protected] <javascript:>
> .
> Visit this group at http://groups.google.com/group/modwsgi.
> For more options, visit https://groups.google.com/d/optout.
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"modwsgi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/modwsgi.
For more options, visit https://groups.google.com/d/optout.

Reply via email to