crazy rewrite error

Discussion in 'General' started by crypted, Apr 18, 2009.

  1. crypted

    crypted New Member

    So this problem started a year ago but I figured it was not related to apache or ISPCONFIG. I finally decided to resolve it today, and it's apache or something.

    Here's what the deal is. My translation application for Areyouliberal.com ends up giving an "500 error - Internal Server Error!" error.

    Error log shows this:
    Code:
    [Fri Apr 17 13:02:44 2009] [alert] [client 72.198.79.154] /var/www/web6/web/wp-content/plugins/translator/.htaccess: Options not al$
    [Fri Apr 17 13:02:44 2009] [warn] RewriteOptions: MaxRedirects option has been removed in favor of the global LimitInternalRecursio$
    [Fri Apr 17 13:02:44 2009] [alert] [client 72.198.79.154] /var/www/web6/web/wp-content/plugins/translator/.htaccess: Options not al$
    [Fri Apr 17 13:02:44 2009] [warn] RewriteOptions: MaxRedirects option has been removed in favor of the global LimitInternalRecursio$
    [Fri Apr 17 13:02:44 2009] [alert] [client 72.198.79.154] /var/www/web6/web/wp-content/plugins/translator/.htaccess: Options not al$
    [Fri Apr 17 13:02:44 2009] [warn] RewriteOptions: MaxRedirects option has been removed in favor of the global LimitInternalRecursio$
    [Fri Apr 17 13:02:44 2009] [alert] [client 72.198.79.154] /var/www/web6/web/wp-content/plugins/translator/.htaccess: Options not al$
    [Fri Apr 17 13:02:45 2009] [warn] RewriteOptions: MaxRedirects option has been removed in favor of the global LimitInternalRecursio$
    The .htaccess for the website documentroot has the following:
    Code:
    #Options +FollowSymlinks
    RewriteOptions MaxRedirects=50
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    Vhosts.conf in the httpd/conf/vhosts/ directory has the following for Areyouliberal.com:
    Code:
    ErrorDocument 405 /error/methodNotAllowed.html
    ErrorDocument 500 /error/internalServerError.html
    ErrorDocument 503 /error/overloaded.html
    AliasMatch ^/~([^/]+)(/(.*))? /var/www/web6/user/$1/web/$3
    AliasMatch ^/users/([^/]+)(/(.*))? /var/www/web6/user/$1/web/$3
    RewriteEngine on
    RewriteCond %{HTTP_HOST}   ^areyouracist\.com [NC]
    RewriteRule ^/(.*)         http://areyouliberal.com/$1 [L,R]
    <IfModule mod_rewrite.c>
      RewriteEngine on
      RewriteCond %{REQUEST_METHOD} ^(TRACE|TRACK)
      RewriteRule .* - [F]
    </IfModule>
    </VirtualHost>
    How can I get Rewrite to work appropriately? According to httpd.conf there is a LOADMODULE for modrewrite.so so that should not be an issue.

    I have no Apache Directives added to the website through ISPCONFIG's interface.
     
  2. crypted

    crypted New Member

    Okay, after modifying Apache Directives on the ISPCONFIG web interface I added:
    Code:
    <Directory /var/www/web6/web/>
    AllowOverride All
    </Directory>
    This resolved several issues, however, I am still having rewrite issues on sub-directories that should be rewritten. Is there a way to do a full override for the entire website?
     
  3. falko

    falko Super Moderator ISPConfig Developer

    Please check if there are .htaccess files in some subdirectories or other parts in the Apache configuration that override this configuration.

    BTW,

    Code:
    RewriteEngine on
    RewriteCond %{HTTP_HOST}   ^areyouracist\.com [NC]
    RewriteRule ^/(.*)         http://areyouliberal.com/$1 [L,R]
    <IfModule mod_rewrite.c>
      RewriteEngine on
      RewriteCond %{REQUEST_METHOD} ^(TRACE|TRACK)
      RewriteRule .* - [F]
    </IfModule>
    can be shortened to

    Code:
    <IfModule mod_rewrite.c>
      RewriteEngine on
      RewriteCond %{HTTP_HOST}   ^areyouracist\.com [NC]
      RewriteRule ^/(.*)         http://areyouliberal.com/$1 [L,R]
      RewriteCond %{REQUEST_METHOD} ^(TRACE|TRACK)
      RewriteRule .* - [F]
    </IfModule>
     
  4. crypted

    crypted New Member

    There are some .htaccess files but just standard little options +indexes types, nothing for rewrite.
     
  5. till

    till Super Moderator Staff Member ISPConfig Developer

    You should not set things Like Options +Indexes in .htaccess files. Beter set them in the apache directives field.
     
  6. crypted

    crypted New Member

    Okay. Would it be like doing a directive for that be as:
    <Directory /var/www/web6/web/>
    Options +indexes
    </Directory>

    Yes?

    And what's the word on a script to move from 2.2.x to 3.x.x ISPCONFIG versions? :-D
     
  7. falko

    falko Super Moderator ISPConfig Developer

    Yes.

    This is not possible. We've mentioned that in many threads now. Please accept it.
     

Share This Page