Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm editing /opt/lampp/etc/extra/httpd-vhosts.conf

I've added VirtualHost directive to this file

<VirtualHost 127.0.0.2:80>
    ServerAdmin kirzilla@gmail.com
    ServerName rem
    DocumentRoot "/home/kir/www/rem/public"
    ErrorLog logs/rem-error_log
    CustomLog logs/rem-access_log common
    <Directory "/home/kir/www/rem/public">
      Options Indexes FollowSymLinks Includes execCGI
      AllowOverride None
      Order Allow,Deny
      Allow From All
    </Directory>
</VirtualHost>

Then I've created directory /home/kir/www/rem/public 0755 kir:kir

Then I've added 127.0.0.2 rem to /etc/hosts/.

Then I've restarted xampp sudo /opt/lampp restart

When I'm trying to enter http://rem I'm being redirected to http://rem/xampp As I figured out redirect is produced by file which can be found at /opt/lampp/htdocs/index.php; this file redirects us to /xampp directory.

Please help me to figure out why DocumentRoot directive (and, probably other directives too) are ignored and Apache considers /opt/lampp/htdocs as DocumentRoot.

Thank you.

UPDATED: xampp is running apache2

share|improve this question
add comment

1 Answer

up vote 0 down vote accepted

My bad!

Including of httpd-vhosts.conf was commented in httpd.conf :)

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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