LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices



Reply
 
Search this Thread
Old 01-03-2010, 11:07 PM   #1
X-M4-X
LQ Newbie
 
Registered: Jan 2010
Posts: 3

Rep: Reputation: 0
Subdomains centos/apache2


i cannot figure out how to xxx.myhost.com domains can someone please help me?
 
Old 01-04-2010, 02:12 AM   #2
Dave_Devnull
Member
 
Registered: May 2009
Posts: 142

Rep: Reputation: 24
What have you tried so far?
 
Old 01-04-2010, 08:01 PM   #3
X-M4-X
LQ Newbie
 
Registered: Jan 2010
Posts: 3

Original Poster
Rep: Reputation: 0
I tried setting it up as two seperate virtual host directives and that doesnt work for me - i dont know what else to do.
 
Old 01-05-2010, 02:27 AM   #4
Dave_Devnull
Member
 
Registered: May 2009
Posts: 142

Rep: Reputation: 24
Take a look at this post:
http://www.linuxquestions.org/questi...domain-210787/

Which points to the NameVirtualHost directive:

NameVirtualHost *:80

<VirtualHost *:80>
ServerName egemen
DocumentRoot /var/www/egemen
</VirtualHost>

<VirtualHost *:80>
ServerName mail.egemen
ServerAlias mail.*
ServerAdmin postmaster@egemen
DocumentRoot /var/www/html/webmail/
</VirtualHost>
 
Old 01-06-2010, 02:15 AM   #5
X-M4-X
LQ Newbie
 
Registered: Jan 2010
Posts: 3

Original Poster
Rep: Reputation: 0
my exact config
NameVirtualHost *:80
<VirtualHost *:80>
ServerName devteamsn.com
DocumentRoot /var/www/html/devteam
</VirtualHost>

<VirtualHost *:80>
ServerName sales.devteamsn.com
ServerAlias sales.*
ServerAdmin xp_xd2@devteamsn.com
DocumentRoot /var/www/html/devteam/sales
</VirtualHost>

I got it.
To anyone who uses godaddy as their registrar and wishes to use subdomains.

Add a new A record *.yourdomain.tld in the total dns control panel

add your vhost and your all set!

Last edited by X-M4-X; 01-06-2010 at 02:56 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Apache2 Local Subdomains miragej Linux - Server 8 06-22-2009 03:02 PM
CentOS 5/ Apache2 and Virtual hosts metallica1973 Linux - Networking 8 08-13-2008 09:57 AM
apache2 setup/test subdomains on LAN DeltaXFX Linux - Server 5 11-04-2007 11:16 AM
how to start apache2 on centOS 4 entz Linux - Server 2 04-27-2007 07:29 PM
Subdomains on Apache2 with virtual hosts - how? <Ol>Origy Linux - Networking 2 08-18-2005 06:53 AM


All times are GMT -5. The time now is 06:47 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration