Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

wsgi.conf (mapfish) problem with apache 2.2 in rhel5

Status
Not open for further replies.

ElGerys

Technical User
Jun 7, 2012
1
DE
Hello,

I'm new around here and would like your support please with an issue about wsgi and apache. I have set up a mapfish application ( in my red hat (rhel5) and there are some things I don't know how to solve. The first one is this message:

Code:
service httpd restart
Stopping httpd:                                            [FAILED]
Starting httpd: Syntax error on line 32 of /var/[URL unfurl="true"]www/html/mapfish/MapFishSample/apache/wsgi.conf:[/URL]
Invalid command 'WSGIDaemonProcess', perhaps misspelled or defined by a module not included in the server configuration
                                                           [FAILED]

The mapfish app works under an env file, thus they have an apache configuration (i.e. directory) that has to be adapted to the OS Linux. It has several *.conf files, the one that is causing me problems is this one:

Code:
#
# The Apache mod_wsgi configuration file.
#
# We use mod_wsgi's daemon mode. And we assign a specific process
# group to the WSGI application.
#
# Note: once we use mod_wsgi 3 we'll be able to get rid of the
# Location block by passing process-group and application-group
# options to the WSGIScriptAlias directive.
#

RewriteEngine on

# serve pylons static files via apache:
Alias /mapfishsample/2.2/wsgi/app/   /var/[URL unfurl="true"]www/html/mapfish/MapFishSample/mapfishsample/public/app/[/URL]
Alias /mapfishsample/2.2/wsgi/build/ /var/[URL unfurl="true"]www/html/mapfish/MapFishSample/mapfishsample/public/build/[/URL]
Alias /mapfishsample/2.2/wsgi/lib/   /var/[URL unfurl="true"]www/html/mapfish/MapFishSample/mapfishsample/public/lib/[/URL]

# uncomment this if you need HTTP authentication/authorization to work (with
# repoze.who or any other security toolkit), see the Apache mod_wsgi FAQ to
# understand why mod_wsgi doesn't pass the user credentials to the WSGI
# application by default.
# [URL unfurl="true"]http://code.google.com/p/modwsgi/wiki/FrequentlyAskedQuestions#Access_Control_Mechanisms[/URL]
#WSGIPassAuthorization On

RewriteRule ^/wsgi$ /mapfishsample/2.2/wsgi/ [PT]
RewriteRule ^/wsgi/$ /mapfishsample/2.2/wsgi/ [PT]
RewriteRule ^/wsgiapihelp.html$ /mapfishsample/2.2/wsgi/apihelp.html [PT]
RewriteRule ^/wsgiapiloader.js$ /mapfishsample/2.2/wsgi/apiloader.js [PT]

# define a process group
WSGIDaemonProcess mapfishsample:2.2 display-name=%{GROUP} user=localhost

# define the path to the WSGI app
WSGIScriptAlias /mapfishsample/2.2/wsgi /var/[URL unfurl="true"]www/html/mapfish/MapFishSample/buildout/parts/modwsgi/wsgi[/URL]

# assign the WSGI app instance the process group defined aboven, we put the WSGI
# app instance in the global application group so it is always executed within
# the main interpreter
<Location /mapfishsample/2.2/wsgi>
    WSGIProcessGroup mapfishsample:2.2
    WSGIApplicationGroup %{GLOBAL}
</Location>

As I understand, in Apache 2.2 all INCLUDE flags must be saved in a file and put that file in /etc/httpd/conf.d/, and no longer add those in /etc/httpd/conf/httpd.conf. I did that but still the apache server doesn't work (so it doesn't appear the Apache server welcome web under
I'm stuck here, I'd appreciate any suggestions to circumvent this error.

Thanks in advance,

Gery

PS. I have this variable "modwsgi_user", what should I write there with regard to my linux? thanks.
 
There may be a problem with case. With linux, case does matter. For example, /This/Dir/Path is not the same as /this/dir/path.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top