Windows Linux Tips: Virtual hosts in Apache

twitter tips,twitter tricks,twitter tips and tricks,twitter latest updates,facebook tips and tricks,facebook tricks,facebook tips,Windows 7 Tips,Windows 7 tips and tricks,Windows 7 tips with staps,Windows XP Tips,Windows XP tips and tricks,Windows XP tips with staps,Windows Linux Tips,Windows Linux Tips and tricks

Apache, the popular Web server for Linux and Unix, allows you to host virtual hostnames with multiple IP
addresses. You can set one IP to each hostname. But what if you want to host multiple hostnames on a singleIP? Apache allows you to do it.

The trick is a single command that goes in the httpd.conf configuration file:


Replacing with your real IP address, this will allow Apache to know on which IP it should serve the
virtual hostnames. Then you can add the virtual commands for every 

hostname you want to host:

DocumentRoot /home/httpd/virtual ServerName</VirtualHost>

This will add in your list of virtual hosts and serve 
the pages in /home/httpd/virtual.Ofcourse you need to have the actual hostname pointing 
to that system.

"Windows Linux Tips: Virtual hosts in Apache"

Reference :