-1

I am using openSUSE Linux. I failed to create a virtual host so I put my project to the document root at /srv/www/htdocs.

The .htaccess File is not getting loaded. My website does still load without an internal server error (status code 500) if I add garbage to the .htaccess file.

I added this block in /etc/apache2/httpd.conf:

<Directory "/srv/www/htdocs">
    Options Indexes FollowSymLinks
    AllowOverride All
    Require all granted
</Directory>

and restarted apache2, but the .htaccess file is still not producing a server error, so it was not loaded.

4
  • Are you sure you're sending the request to the right server? Do you see your requests coming in in the access log?
    – Oldskool
    Oct 19 '18 at 9:38
  • Did you check the error logs?
    – dkokmadis
    Oct 19 '18 at 9:38
  • @Oldskool, yes it is the right server. There is new log content in /var/log/apache2/access_log if I reload the page.
    – Black
    Oct 19 '18 at 9:42
  • @dkokmadis, there is no new content in /var/log/apache2/error_log if I reload the page. Even though there is garbage in the .htaccess file.
    – Black
    Oct 19 '18 at 9:43
0

Our senior web-developer was able to solve it. We had to change AllowOverride to All in the file /etc/apache2/default-server.conf. The entry in /etc/apache2/httpd.conf had no effect, because /etc/apache2/default-server.conf has a higher priority.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.