tigre
tigre

Reputation: 353

ubuntu returns 500 error when .htaccess enabled

I'm currently moving a dev magento build to my live test subdomain on ubuntu and using Easy Hosting Control Panel (EHCP).

If I rename my .htaccess file to .htaccess and refresh my subdomain url, I get an internal server error 500. If I rename the .htaccess file to .htaccess.bak, and refresh, the subdomain displays my magento store fine. BUT, if I try to navigate, since the index.php isn't removed in the .htaccess file, all my links are dead unless I insert index.php between my root url and the actual page/directory I'm navigating to.

I tried over riding the /etc/apache2/sites-available/000-default and /etc/apache2/sites-available/default files to AllowOverride All:

<VirtualHost *>

    DocumentRoot /var/www
    <Directory />
            Options FollowSymLinks
            AllowOverride All
    </Directory>

    <Directory /var/www/vhosts/>
            Options -Indexes FollowSymLinks MultiViews
            AllowOverride All
            Order Allow,Deny
            Allow from All
    </Directory>

    <FilesMatch "access_log|error_log">
            Deny from All
    </FilesMatch>

    ErrorLog /var/log/apache2/error.log
    LogLevel debug
    CustomLog /var/log/apache2/access.log combineddefault

but changing that in either file, or both, and then reenabling the .htaccess file still gives me the 500 error.

anything I'm doing wrong here? Somewhere else I should be placing the mod rewrite information?

thanks!

Upvotes: 6

Views: 5368

Answers (2)

Taylor
Taylor

Reputation: 81

I know this is kind of dead but for those with this issue check your /etc/apache2/mods-enabled to see if rewrite.load is there if not try to copy it from the /etc/apache2/mods-available folder that fixed the issue for me. You will also have to have the .htaccess override enabled for that

Upvotes: 8

mivec
mivec

Reputation: 327

is it rules available? maybe apache is disabled rewrite mod,you can try to enable.

type 'a2enmod rewrite' to turn on.

Upvotes: 4

Related Questions