Solved

Why do I get "RewriteLog not allowed here" when I try to start Apache

Posted on 2007-11-18
3
7,092 Views
Last Modified: 2011-10-03
I am trying to use mod_rewrite in Apache. When I try to turn on rewrite logging I get the "Rewritelog not allowed here" message.

I am running multiple virtual hosts and this is the vhosts file for host in question:
AddHandler fcgid-script .php .php5
SuexecUserGroup proman psacln
<Directory /var/<...>/httpdocs>
     FCGIWrapper /var/<...>/bin/php5 .php
     FCGIWrapper /var/<...>/bin/php5 .php5
     Options +ExecCGI
     allow from all

     RewriteEngine On    

     RewriteLog "/var/log/httpd/promanage_rewrite.log" # this is the line referenced in the error message.
     RewriteLogLevel 9

     RewriteRule ^/js/analytics\.js$ lytics.php [QSA,L]

</Directory>

I have tried to put the log file in various places and nothing changes.
I have duplicated the permissions of other log files in the system to no avail.

If more info is needed, let me know.

0
Comment
Question by:bsysd
  • 2
3 Comments
 
LVL 13

Accepted Solution

by:
John Mc Hale earned 500 total points
ID: 20309667
RewriteLog and RewriteLogLevel are Server/Virtual Host config directive that cannot be used inside <Directory> or <Location> structures. Move them outside this block and restart the server.

regards.
0
 
LVL 13

Expert Comment

by:John Mc Hale
ID: 20309678
In particular, see the Context section at the following page http://httpd.apache.org/docs/trunk/mod/mod_rewrite.html#rewritelog
0
 

Author Comment

by:bsysd
ID: 20314768
Thanks fredthered. That got the server started and the logging turned on.    
0

Featured Post

Give your grad a cloud of their own!

With up to 8TB of storage, give your favorite graduate their own personal cloud to centralize all their photos, videos and music in one safe place. They can save, sync and share all their stuff, and automatic photo backup helps free up space on their smartphone and tablet.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

When it comes to showing a 404 error page to your visitors, you do not want that generic page to show, and you especially do not want your hosting provider’s ad error page to show either. In this article, I will show you how to enable the custom 40…
Meet the world's only “Transparent Cloud™” from Superb Internet Corporation. Now, you can experience firsthand a cloud platform that consistently outperforms Amazon Web Services (AWS), IBM’s Softlayer, and Microsoft’s Azure when it comes to CPU and …
Hi friends,  in this video  I'll show you how new windows 10 user can learn the using of windows 10. Thank you.
Both in life and business – not all partnerships are created equal. As the demand for cloud services increases, so do the number of self-proclaimed cloud partners. Asking the right questions up front in the partnership, will enable both parties …

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now