Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Is it possible to have two ServerName in the one virtualhost?

Posted on 2011-03-17
6
Medium Priority
?
505 Views
Last Modified: 2013-11-08
Hi All,

Is it possible to have two ServerName in the one virtualhost?

e.g. www.mydomain.net and www.mydomain2.net

<VirtualHost 192.168.0.2:80>
ServerName www.mydomain.net
DocumentRoot /var/www/mydomain.net/
</VirtualHost>
0
Comment
Question by:detox1978
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
6 Comments
 
LVL 29

Accepted Solution

by:
Jan Springer earned 1332 total points
ID: 35156611
Yes.

ServerName www.mydomain.net
ServerAlias www.mydomain2.net

As long as the IP of the two is the same.
0
 
LVL 2

Author Comment

by:detox1978
ID: 35157005
Yeah, it's the same.  Can you have more than two?
0
 
LVL 29

Expert Comment

by:Jan Springer
ID: 35157037
With multiple ServerAlias statements.
0
Get free NFR key for Veeam Availability Suite 9.5

Veeam is happy to provide a free NFR license (1 year, 2 sockets) to all certified IT Pros. The license allows for the non-production use of Veeam Availability Suite v9.5 in your home lab, without any feature limitations. It works for both VMware and Hyper-V environments

 
LVL 2

Author Comment

by:detox1978
ID: 35157189
Is there any limit.  I wanted to add around 100.
0
 
LVL 1

Assisted Solution

by:crazyn3wf
crazyn3wf earned 668 total points
ID: 35157234
I dont think there is a limit. Just use

ServerAlias domain1.com domain2.com domain3.com domain4.com ....
0
 
LVL 29

Assisted Solution

by:Jan Springer
Jan Springer earned 1332 total points
ID: 35157400
I don't think that's a problem.  You can also aggregate similar domains with the wildcard (*):

www.domain*.com
0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you are a web developer, you would be aware of the <iframe> tag in HTML. The <iframe> stands for inline frame and is used to embed another document within the current HTML document. The embedded document could be even another website.
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial
Suggested Courses

722 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question