Trouble with Apache and Virtual Hosts

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,
I wanted to install subdomains to be used locally.

I configured my hosts file and added a new address:

127.0.1.1 local.loc
127.0.1.1 part1.local.loc
127.0.1.1 part2.local.loc
127.0.1.1 blog.local.loc

There is no 127.0.0.1 in my hosts file anymore. I removed it.

I configured my vhosts file to include:

<VirtualHost *:80>
ServerAdmin [email address]
DocumentRoot "../htdocs/local"
ServerName local.loc
ServerAlias local.loc
DirectoryIndex index.php index.html index.html index.htm index.shtml
</VirtualHost>

and for all the subdomains.

The problem is that when I type 127.0.1.1 in my browser after installing Apache with this address, I get the 'It works' message. However, the same doesn't happen when I type 'local.loc'. I still get the 'It works' message for 127.0.0.1 and for 'localhost'.

Any suggestions?

Regards,
Ganesh.

[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux