我們嘗試將舊服務器遷移到新服務器,但我們遇到了mod_python的一些問題。在mod_python下正確運行Apache服務器的問題
問題是這樣的網頁下:
http://auction.tinyerp.org/auction-in-europe.com/aie/
這裏是我們的Apache2配置:
NameVirtualHost *
<VirtualHost *>
DocumentRoot /var/www/
<Directory />
Options FollowSymLinks
AllowOverride all
</Directory>
<Directory "/var/www/auction-in-europe.com/aie">
Options Indexes FollowSymLinks MultiViews
#AddHandler mod_python .py
PythonOption mod_python.legacy.importer *
SetHandler mod_python
PythonHandler mod_python.publisher
PythonDebug On
AllowOverride all
Order allow,deny
allow from all
# This directive allows us to have apache2's default start page
# in /apache2-default/, but still have/go to the right place
</Directory>
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride None
Options ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>
ScriptAlias /bin/ /home/www/auction-in-europe.com/aie/bin/
ServerAdmin [email protected]
ErrorLog /home/logs/auction-in-europe.com/error_log
CustomLog /home/logs/auction-in-europe.com/access_log combined
ServerName auction-in-europe.com
ServerAlias www.auction-in-europe.com antique-in-europe.com www.antique-in-europe.com art-in-europe.com www.art-in-europe.com en.art-in-europe.com
ServerAlias en.antique-in-europe.com en.auction-in-europe.com fr.antique-in-europe.com fr.art-in-europe.com fr.auction-in-europe.com auction.tinyerp.org
#RewriteEngine on
#RewriteRule ^/(.*)\.html /index.py [E=pg:$1]
ErrorLog /var/log/apache2/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog /var/log/apache2/access.log combined
ServerSignature On
Alias /doc/ "/usr/share/doc/"
<Directory "/usr/share/doc/">
Options Indexes MultiViews FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
Allow from 127.0.0.0/255.0.0.0 ::1/128
</Directory>
<Directory /home/www/postfixadmin>
</Directory>
</VirtualHost>
日誌是相當空:
[Mon Oct 12 13:25:58 2009] [notice] mod_python: (Re)importing module 'mod_python.publisher'
[Mon Oct 12 13:25:58 2009] [notice] [client 212.166.58.166] Publisher loading page /home/www/auction-in-europe.com/aie/index.py
我真的沒有想法從哪裏開始。
請幫忙!
「/var/www/auction-in-europe.com/aie」中有哪些文件?它是否包含一個index.py?該文件的內容是什麼? – Mark 2009-10-12 14:10:55