views:

29

answers:

2

Hi,

I am trying to change from windows to linux server. And for that i am trying to enable mod_write in ubuntu. I have taken all the necessary steps to enable the mod_rewrite as mod_rewrite is displayed under loaded modules. I have set all the permissions for the .htacess file. But for some reason the rewrite does not appear to be working in the linux server. It was working fine while i was using the same code in windows server.

Can anyone please help me in this issue. Your help will be really appreciated.

Thanks. Rajan.

+1  A: 

Check if you have the AllowOverride directive set to None. This is usually done in a file which sets your VirtualHosts

NameVirtualHost 192.168.0.1:80
<VirtualHost 192.168.0.1:80>
    ServerName some.local.site

    DocumentRoot /home/user/site
    <Directory /home/user/site>
            AllowOverride None  <-- set this to All

    </Directory>
</VirtualHost>
Igor Zinov'yev
I had changed this as well but still there appears to be some problem. Anyways thanks for your time and help. Can you provide any further solution please.
Rajan
Can you add relevant config sections and the .htaccess to the question body? I think nobody can tell anything beyond what's already has been told without extra information.
Igor Zinov'yev
+1  A: 

If setting AllowOverride to ALL didn't work, you might want to debug mod_rewrite like so:

add after RewriteEngine On

RewriteLog "/var/log/httpd/mod_rw.log"
RewriteLogLevel 9
Ryan Fernandes