Read more

Debugging Apache's mod_rewrite

Arne Hartherz
November 29, 2012Software engineer at makandra GmbH

Debugging .htaccess is hell, and RewriteRules in particular if they are not working as expected. But fear not! RewriteLog will help you out. \
Add this to your vhost's configuration:

RewriteLog "/tmp/rewrite.log"
RewriteLogLevel 9
Illustration web development

Do you need DevOps-experts?

Your development team has a full backlog? No time for infrastructure architecture? Our DevOps team is ready to support you!

  • We build reliable cloud solutions with Infrastructure as code
  • We are experts in security, Linux and databases
  • We support your dev team to perform
Read more Show archive.org snapshot

After that, restart your Apache httpd and tail the above logfile.

When you are done and all is well: remember to remove those entries again, or set the log level to 0, to switch off rewrite logging.

Posted by Arne Hartherz to makandra dev (2012-11-29 13:20)