0

When I try to turn the RewriteEngine on, it tells me that mod_rewrite is not installed.

I've looked in my apache2.conf file and there is not line to uncomment that resembles

LoadModule rewrite_module modules/mod_rewrite.so

I am not savvy at system admin and I want to make sure I don't screw up my server. Can I just copy (or symlink) mod_rewrite.so into my mods_enabled directory? Should I load the module as I tried above?

Jeff Atwood
  • 13,104
  • 20
  • 75
  • 92
  • 1
    The problem is that the module is not installed and for us to being able to help you, you need to tell us what distro you are using. And then this question is better suited for Server fault. – rzetterberg Apr 30 '11 at 20:46
  • i've seen similar questions posed here. I'm using ubuntu 10.4. –  Apr 30 '11 at 20:54

1 Answers1

2

First you need to check if the module is installed do this by:

cd /etc/apache2/mods-available 
ls -la 

If the module is not installed you do:

apt-get install libapache2-mod-rewrite 

Then you need to active the module:

a2enmod rewrite 

If you want to disable it:

a2dismod rewrite 

Note that you shouldn't add modules in apaches config manually, you should use the a2enmod/a2dismod command.

rzetterberg
  • 137
  • 3
  • 11
  • done and done, thanks Ancide. I was going to install manually! –  Apr 30 '11 at 21:27
  • I'm glad I could be of help :) Also you have the mods-enabled folder where you find all mods that are installed if you ever would want to. – rzetterberg Apr 30 '11 at 21:30