Page 1 of 1

Can't access www folder via localhost, but 192.168.0.100

Posted: 15. Sep 2013, 23:53
by GrandTheftUbuntu
Hello everyone!

I have just installed ubuntu webserver in Virtualbox. I can access my www folder if I enter 192.168.0.100/index.php in my browser. However, if I try to do it via localhost, it does not work.

This is my hosts file:
ServerName localhost

127.0.0.1 localhost

127.0.1.1 ubuntuwebserver
zf2-tutorial.localhost localhost


# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
~
My virtualbox is set as network bridge adapter.

Does anybody know how I can access this folder via localhost?

Thank you!

Re: Can't access www folder via localhost, but 192.168.0.100

Posted: 16. Sep 2013, 23:13
by noteirak
This has nothing to do with Virtualbox I am afraid. It's only a matter of network configuration in the OS. A Network forum would be advised here.
But I would definitly NOT reconfigure localhost, you're going to have _a lot_ of issues...

Re: Can't access www folder via localhost, but 192.168.0.100

Posted: 17. Sep 2013, 09:23
by Martin
Did you check that your webserver software is configured to listen also on the localhost loopback interface?