0
I’m trying to enable the . htacces on Ubuntu 14.10,.
I’m putting the files in the /var/www/
I’ve tried but I can’t seem to make it work.
apache2ctl -S:
VirtualHost configuration:
*:80 127.0.1.1 (/etc/apache2/sites-enabled/000-default.conf:1)
ServerRoot: "/etc/apache2"
Main DocumentRoot: "/var/www/html"
Main ErrorLog: "/var/log/apache2/error.log"
Mutex rewrite-map: using_defaults
Mutex default: dir="/var/lock/apache2" mechanism=fcntl
Mutex mpm-accept: using_defaults
Mutex watchdog-callback: using_defaults
PidFile: "/var/run/apache2/apache2.pid"
Define: DUMP_VHOSTS
Define: DUMP_RUN_CFG
User: name="www-data" id=33
Group: name="www-data" id=33
000-default.conf:
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /var/www/
<Directory "/var/www/">
AllowOverride All
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
# vim: syntax=apache ts=4 sw=4 sts=4 sr noet
/etc/apache2/apache2.conf:
<Directory />
Options FollowSymLinks
AllowOverride All
Require all granted
</Directory>
<Directory /usr/share>
AllowOverride All
Require all granted
</Directory>
<Directory /var/www/>
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>
Tried to
sudo a2enmod rewrite && service apache2 restart
?– Guilherme Nascimento
Yes, but it doesn’t work... @Guilhermenascimento
– user3092202
What appears in the logs?
sudo a2enmod rewrite
presents some error?– Guilherme Nascimento
it seems all right, the only thing I realized is that by default the root folder is
/var/www/html/
– Pedro Sanção
The return of sudo a2enmod rewrite: Module rewrite already enabled
– user3092202
How is the content of your . htaccess?
– Guilherme Nascimento