为什么我的trac无法运行

时间:2017-05-03 11:58:21

标签: apache python-2.7 trac

我已按照trac官方网站的说明进行操作:thisthis。但是当我重新启动apache2服务时,我收到了这些apache2错误日志:

[Wed May 03 11:46:18.641715 2017] [mpm_event:notice] [pid 30937:tid 140202045007744] AH00491: caught SIGTERM, shutting down
[Wed May 03 11:46:19.730816 2017] [:error] [pid 31070:tid 140509321906048] python_init: Python version mismatch, expected '2.7.6', found '2.7.12'.
[Wed May 03 11:46:19.730936 2017] [:error] [pid 31070:tid 140509321906048] python_init: Python executable found '/usr/bin/python'.
[Wed May 03 11:46:19.730943 2017] [:error] [pid 31070:tid 140509321906048] python_init: Python path being used '/usr/lib/python2.7/:/usr/lib/python2.7/plat-x86_64-linux-gnu:/usr/lib/pyth    on2.7/lib-tk:/usr/lib/python2.7/lib-old:/usr/lib/python2.7/lib-dynload'.
[Wed May 03 11:46:19.730951 2017] [:notice] [pid 31070:tid 140509321906048] mod_python: Creating 8 session mutexes based on 6 max processes and 25 max threads.
[Wed May 03 11:46:19.730954 2017] [:notice] [pid 31070:tid 140509321906048] mod_python: using mutex_directory /tmp
[Wed May 03 11:46:19.746158 2017] [mpm_event:notice] [pid 31070:tid 140509321906048] AH00489: Apache/2.4.18 (Ubuntu) mod_python/3.3.1 Python/2.7.12 configured -- resuming normal operatio    ns
有人说这些错误只是警告,但是我的trac没有运行。浏览器显示"无法连接",任何人都可以帮我修复,一些提示,非常感谢!

我的trac版本是" trac-admin - Trac管理控制台1.2.1"

我的VirtualHost如下:

    <VirtualHost *:8090>
    #ServerName * 
    #DocumentRoot /mohism_trac
    <Location />
       SetHandler mod_python
       PythonInterpreter main_interpreter
       PythonHandler trac.web.modpython_frontend
       #PythonOption TracUriRoot /
       PythonOption TracEnv /var/www/mohism_trac
       # PythonOption TracEnvIndexTemplate /var/local/trac/templates/index-template.html
       PythonOption TracLocale en_US.UTF8
       PythonOption PYTHON_EGG_CACHE /tmp
       #Order allow,deny
       #Allow from all
       Require all granted
       PythonDebug on
    </Location>
    <Location /login>
      AuthType Basic
      AuthName "Mohism Research"
      AuthUserFile /var/www/mohism_trac/.htpasswd
      Require valid-user
    </Location>

    ErrorLog "/var/log/apache2/trac_errors.log"
    CustomLog "/var/log/apache2/trac_accesses.log" common 
</VirtualHost>

更正我的配置后,来自/var/log/apache2/error.log的错误:

[Thu May 04 06:56:15.091624 2017] [mpm_event:notice] [pid 23791:tid 140324578609024] AH00491: caught SIGTERM, shutting down
[Thu May 04 06:56:16.170664 2017] [so:warn] [pid 23958:tid 140090664261504] AH01574: module python_module is already loaded, skipping
[Thu May 04 06:56:16.172837 2017] [:notice] [pid 23959:tid 140090664261504] mod_python: Creating 8 session mutexes based on 6 max processes and 25 max threads.
[Thu May 04 06:56:16.172848 2017] [:notice] [pid 23959:tid 140090664261504] mod_python: using mutex_directory /tmp
[Thu May 04 06:56:16.186403 2017] [mpm_event:notice] [pid 23959:tid 140090664261504] AH00489: Apache/2.4.18 (Ubuntu) mod_python/3.5.0- Python/2.7.12 configured -- resuming normal operati    ons
[Thu May 04 06:56:16.186436 2017] [core:notice] [pid 23959:tid 140090664261504] AH00094: Command line: '/usr/sbin/apache2'

0 个答案:

没有答案