2013-02-22 84 views
-1

我在Ubuntu中设置我的apache2服务器时遇到问题。Apache2安装程序Ubuntu

我做了一个sudo apt-get install,它安装正常。访问本地主机时,我能够看到该网站正在工作。

然后我不确定发生了什么,但我不再能够看到“它的工作!”网站。当我尝试重新启动apache2时,它会返回:

Syntax error on line 17 of /etc/apache2/sites-enabled/000-default: 
AddHandler requires at least two arguments, a handler name followed by one or more file extensions 
Action 'configtest' failed. 
The Apache error log may have more information. 
...fail! 

任何想法?

这里是/ 000默认我的/ etc/apache2的/启用的站点 - :

的ServerAdmin网站管理员@本地

DocumentRoot /var/www 
<Directory /> 
    Options FollowSymLinks 
    AllowOverride None 
</Directory> 
<Directory /var/www/> 
    Options Indexes FollowSymLinks MultiViews 
    AllowOverride None 
    Order allow,deny 
    allow from all 

    DirectoryIndex index.html index.py 

    AddHandler mod_python.py 
    PythonHandler mod_python.publisher 
    PythonDebug On 
</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> 

ErrorLog ${APACHE_LOG_DIR}/error.log 

# Possible values include: debug, info, notice, warn, error, crit, 
# alert, emerg. 
LogLevel warn 

CustomLog ${APACHE_LOG_DIR}/access.log combined 

+1

你可以给我们你的/ etc/apache2/sites-enabled/000-default吗? – Ifnot 2013-02-22 12:58:47

回答

0

上有你的配置文件有问题。尝试改变行14:

AddHandler mod_python .py