I have made a virtual host on a machine and reloaded apache, but I can't seems to be able to access it from another computer on the same network. (It does work when I set the ip of the server and in the host file of the other machine)

to make the virtualhost I have edited /etc/httpd/conf/httpd.conf and added:

    DocumentRoot /home/sites/mysite
    ServerName mysite.test.corp
    ErrorLog logs/mysite.test.corp-error_log
    CustomLog logs/mysite.test.corp-access_log common
    <Directory /home/sites/mysite>
        AllowOverride All

If it works when you set the IP in your hosts file, then there is a DNS problem somewhere on the local network. Did you create the record "mysite.test.corp." on your local authoratative DNS servers?

  • To add to that: I have a router that forwards port 80 to my public web server; I publish the external IP address of the router in my external DNS. My router can't handle internal traffic attempting to access the external address (it doesn't port forward correctly). So I had to set up internal DNS to mirror (but lie about) the external DNS. – Roger Lipscombe Oct 7 '09 at 14:38

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.