How to host a website in linux
Hi,
I have a RHEL4 server which already has a web server running on it(Intranet purpose) and it was configured by webadmin earlier. Now i want to host a web with out changing the existing web.How can i do that??? All the web related stuff is stored in /var/www/html I have some jsp pages created by developers and i want to host a website using it. |
in the /etc/httpd/
you can setup virtual directories in the httpd.conf file for example http://something.com -> var/www/ & http://somthing.bob.com -> var/www/bob/ |
|
1 Attachment(s)
Quote:
I've tried confuguring virtual hosts by editing httpd.conf file but i'm not sure how i can browse my virtual host. please find the attached httpd.conf file with virtual host settings and let me know if it has any errors. |
Based on the httpd.conf, www.myserver.com is the default you will need a dns entry for the www.myserver1.com unless you are only using it on an internal net then host file will work.
NameVirtualHost *:80 Tells apache to use virtual hosts based on names <VirtualHost *:80> Tells apache the 1st virtualhost DocumentRoot /path/to/files Virtual host doc root ServerName www.myserver.com Actual server name that will be used by apache </VirtualHost> <VirtualHost *:80> DocumentRoot /path/to/different/files ServerName www.someone.com </VirtualHost> |
Quote:
|
Quote:
Can any one suggest on this query??? |
You'll need a DNS entry; either on your DNS server if you have one, or in your desktop's /etc/hosts file, so it knows how to find the right system.
In the latter case, only you will see them... Before DNS was invented, every system on the then ARPANET had a complete list of all systems in its hosts file. Obviously that doesn't scale, so DNS (& bind) was invented. |
All times are GMT -5. The time now is 09:10 PM. |