We are in the process of migrating this forum. A new space will be available soon. We are sorry for the inconvenience.

Apache2 + mod_python = Python version mismatch


jhad
11-03-2012, 14:10
Problem: aplikacja (django) rzuca error 500. W logach vhosta pusto.

Kod:
Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.
Kod:
#apache2 -v
Server version: Apache/2.2.16 (Debian)
Server built:   Feb  5 2012 21:35:44
Moduly:
Kod:
# ls -l /etc/apache2/mods-enabled/
razem 0
(...)
lrwxrwxrwx 1 root root 29 02-08 18:09 python.load -> ../mods-available/python.load
(...)
lrwxrwxrwx 1 root root 27 01-24 22:48 wsgi.conf -> ../mods-available/wsgi.conf
lrwxrwxrwx 1 root root 27 01-24 22:48 wsgi.load -> ../mods-available/wsgi.load
(...)
Tutaj przyczyna, error.log:
Kod:
[Sun Mar 11 06:25:02 2012] [error] python_init: Python version mismatch, expected '2.6.5+', found '2.6.6'.
[Sun Mar 11 06:25:02 2012] [error] python_init: Python executable found '/usr/bin/python'.
[Sun Mar 11 06:25:02 2012] [error] python_init: Python path being used '/usr/lib/python2.6/:/usr/lib/python2.6/plat-linux2:/usr/lib/python2.6/lib-tk:/usr/lib/python2.6
/lib-old:/usr/lib/python2.6/lib-dynload'.
[Sun Mar 11 06:25:02 2012] [notice] mod_python: Creating 8 session mutexes based on 7 max processes and 50 max threads.
[Sun Mar 11 06:25:02 2012] [notice] mod_python: using mutex_directory /tmp
[Sun Mar 11 06:25:02 2012] [notice] Apache/2.2.16 (Debian) mod_fcgid/2.3.6 mod_python/3.3.1 Python/2.6.6 mod_wsgi/3.3 configured -- resuming normal operations
Kod:
# python -V
Python 2.6.6
2.6.6 > 2.6.5+
czyli ok

Z tego co wyczytalem przy bledzie dotyczycym blednego interpretownia wersji mod_python potrzeba przekompilowac pythona, ale szczerze mowiac bladze juz od jakiegos czasu, moze ktos mi podpowie, nie jestem guru

Repozytoria debiana sa aktualne, oto sources.list:
Kod:
deb http://mirror.ovh.net/debian/ squeeze main
deb-src http://mirror.ovh.net/debian/ squeeze main

deb http://security.debian.org/ squeeze/updates main
deb-src http://security.debian.org/ squeeze/updates main

deb http://packages.dotdeb.org stable all
deb-src http://packages.dotdeb.org stable all