2014-10-24 3 views
0

Это question связано с моим вопросом.mod_wsgi - ошибка mod_wsgi-express AH00526: Синтаксическая ошибка в строке 16

На самом деле я использую Apacha версию над Ubuntu 14.04 LTS 64бит: версии Сервера: Apache/2.4.7 (Ubuntu) Сервера построен: 22 Июл 2014 14:36:38

Когда я набираю команду mod_wsgi- экспресс-сервер, чтобы проверить, работает ли он. Это, похоже, не работает, и у меня есть ошибка:

[email protected]:/home/website# mod_wsgi-express start-server 
Server URL  : http://localhost:8000/ 
Server Root  : /tmp/mod_wsgi-localhost:8000:0 
Server Conf  : /tmp/mod_wsgi-localhost:8000:0/httpd.conf 
Error Log File : /tmp/mod_wsgi-localhost:8000:0/error_log 
AH00526: Syntax error on line 16 of /tmp/mod_wsgi-localhost:8000:0/httpd.conf: 
Error:\tApache has not been designed to serve pages while\n\trunning as root. There are known race conditions that\n\twill allow any local user to read any file on the system.\n\tIf you still desire to serve pages as root then\n\tadd -DBIG_SECURITY_HOLE to the CFLAGS env variable\n\tand then rebuild the server.\n\tIt is strongly suggested that you instead modify the User\n\tdirective in your httpd.conf file to list a non-root\n\tuser.\n 

У меня есть та же проблема при установке на doom. Любые предложения приветствуются!

Дополнительная информация:

модули, используемые в Apache:

Compiled in modules: 
    core.c 
    mod_so.c 
    mod_watchdog.c 
    http_core.c 
    mod_log_config.c 
    mod_logio.c 
    mod_version.c 
    mod_unixd.c 

Python Версия:

>>> print (sys.version) 
2.7.6 (default, Mar 22 2014, 22:59:56) 
[GCC 4.8.2] 
+0

Ошибка кажется вполне понятной: не запускайте ее как root. Почему вы все так делаете? Вы никогда не должны регистрироваться как root. –

+0

Да, я отмечаю позже! Благодаря! – Marcelo

ответ

0

У меня была аналогичная проблема, пытаясь раскрутить приложение питона TurboGears. Наконец, я смог запустить его, выполнив команду start-server с включенной опцией пользователя. Я установил параметр пользователя равным пользователю, использующему apache. В моем случае пользователь «apache». Смотри ниже.

[[email protected] ~]# mod_wsgi-express start-server --user=apache <path_to_my_wsgi_file> 
Смежные вопросы