DNS
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsSystem AdministrationDNS

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old January 22nd, 2004, 01:44 AM
sandipguha sandipguha is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2003
Location: India
Posts: 14 sandipguha User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 5 m 14 sec
Reputation Power: 0
Question 2 Domains and 1 Web Server

Hi guys...
i am a newbie in DNS... I ve a RedHat 8 Linux Apache Web Server with a domain (abc.com). Now I have made another registration with a domain named (itssandip.tk).
Now if I want to host that domain in my existing web server with abc.com domain how should I proceed.
Should I made itssandip.tk Virtual. If yes please help me how???
Thanks for support

Last edited by sandipguha : January 22nd, 2004 at 02:03 AM.

Reply With Quote
  #2  
Old January 22nd, 2004, 08:37 AM
trininox trininox is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2004
Posts: 42 trininox User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 5
Send a message via ICQ to trininox Send a message via AIM to trininox
Same Site?

Do you want both domains to display the same site?

You should be able to just make another record using the other domain instead.

If you want different sites then you need to ask about setting up apache for Name Base Hosting.

You would still setup DNS for both domains to resolve to your IP.

In apaches http.conf it has at the end an example and a url for the manual on how to setup

<virtual host>
Directives
</virtual host>

If thats what you need I can help you out if you need some explaining or something.
__________________
-Trininox
http://gto.dynu.com

Reply With Quote
  #3  
Old January 22nd, 2004, 09:39 PM
sandipguha sandipguha is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2003
Location: India
Posts: 14 sandipguha User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 5 m 14 sec
Reputation Power: 0
Thanks a lot for ur early reply Trininox...
I don't want to display the same website by both that address.
I made that that entry in the Virtual Host section of Apache's httpd.conf file. But it is not showing the the second one. May be I'm mistaking something....
It will be a great help if u guide me the entire procedure.....
Thanx in advance...

Reply With Quote
  #4  
Old January 22nd, 2004, 10:26 PM
trininox trininox is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2004
Posts: 42 trininox User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 5
Send a message via ICQ to trininox Send a message via AIM to trininox
Copy the virutal host section of you conf so i can see how you have it set.
This is the page that you can read all about Named based hosting
http://httpd.apache.org/docs-2.0/vhosts/name-based.html

Make sure your globally you have the following set.

Uncomment
#LoadModule vhost_alias_module modules/mod_vhost_alias.so

Make sure the following is set to Off
UseCanonicalName Off

Example of Virtual Host section
NameVirtualHost *:80

<VirtualHost *:80>
ServerName www.abc.com
DocumentRoot /www/domain
</VirtualHost>

<VirtualHost *:80>
ServerName www.itssandip.tk
DocumentRoot /www/otherdomain
</VirtualHost>

Instead of * you can specify the real IP, and the port :80 isnt required. The document root is Linux style, you need to enter the absolute location of the folder on windows c:\apache\htdocs

I think that should be all you need to make it work

Reply With Quote
  #5  
Old January 22nd, 2004, 11:22 PM
sandipguha sandipguha is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2003
Location: India
Posts: 14 sandipguha User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 5 m 14 sec
Reputation Power: 0
<QUOTE>

NameVirtualHost *:80

<VirtualHost *:80>
ServerName www.abc.com
DocumentRoot /www/domain
</VirtualHost>

<VirtualHost *:80>
ServerName www.itssandip.tk
DocumentRoot /www/otherdomain
</VirtualHost>

thanks again...
I'm using the ip address in NameVirtualHost
NameVirtualHost <ipaddress>:80

But in the VirtualHost section I'm using like following:

<VirtualHost www.abc.com>
ServerName www.abc.com
DocumentRoot /usr/local/apache2/htdocs/abc
</VirtualHost>

<VirtualHost www.itssandip.tk>
ServerName www.itssandip.tk
DocumentRoot /usr/local/apache2/htdocs/itssandip
</VirtualHost>


Is this right...?? if yes then all the settings are OK in httpd.conf file.
What else should I do .. I mean anything to do with /etc/named.conf file and files in /var/named directory ????

Waiting for ur early reply..

Reply With Quote
  #6  
Old January 22nd, 2004, 11:28 PM
trininox trininox is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2004
Posts: 42 trininox User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 5
Send a message via ICQ to trininox Send a message via AIM to trininox
your <virtual host ###> need to be set to the same thing as
NameVirtualHost

NameVirtualHost ###

<VirtualHost ###>
ServerName www.abc.com
DocumentRoot /usr/local/apache2/htdocs/abc
</VirtualHost>

<VirtualHost ###>
ServerName www.itssandip.tk
DocumentRoot /usr/local/apache2/htdocs/itssandip
</VirtualHost>

That should be all you need to do.
Once your domains are set to resolve to the same IP apache should handle the rest.

Let me know if it works out for you.

Reply With Quote
  #7  
Old January 22nd, 2004, 11:45 PM
sandipguha sandipguha is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2003
Location: India
Posts: 14 sandipguha User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 5 m 14 sec
Reputation Power: 0
Thanks..
If I ve understood u then I have to use IP Addess in both places..
But the IP address of both the domain is same lets say 192.168.1.100... will it not be a problem....the entire thing would look like..

NameVirtualHost 192.168.1.100

<VirtualHost 192.168.1.100>
ServerName www.abc.com
DocumentRoot /www/domain
</VirtualHost>

<VirtualHost 192.168.1.100>
ServerName www.itssandip.tk
DocumentRoot /www/otherdomain
</VirtualHost>

Reply With Quote
  #8  
Old January 23rd, 2004, 11:40 AM
trininox trininox is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2004
Posts: 42 trininox User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 5
Send a message via ICQ to trininox Send a message via AIM to trininox
Its supposed to be the same because your setting up two different domains for the same IP, so you specifiy the IP, then in each virtual host you setup you tell it the domain and the location of the documentroot

Reply With Quote
  #9  
Old January 24th, 2004, 12:41 AM
sandipguha sandipguha is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2003
Location: India
Posts: 14 sandipguha User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 5 m 14 sec
Reputation Power: 0
Thanks again...
As you have suggested I did the same thing.. But while I'm entering www.itssandip.tk it showing that ---

www.itssandip.tk could not be found. Please check the name and try again

I think I ashould write some extra line in
/etc/named.conf file for that domain ( itssandip.tk ) and also need something to change in /var/named folder.
If yes then pls tell me what should I write....

Thanks

Reply With Quote
  #10  
Old January 24th, 2004, 02:32 PM
trininox trininox is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2004
Posts: 42 trininox User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 5
Send a message via ICQ to trininox Send a message via AIM to trininox
That would be about DNS which isnt my speciality. I would assume that if you copy the information about your other day and change of course the domain to the new one you should be able to get your new domain to resolve.

Reply With Quote
Reply

Viewing: Dev Shed ForumsSystem AdministrationDNS > 2 Domains and 1 Web Server


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway