Answered by the Webhosting Experts
Tags +

Managed Services
at Hivelocity

Bare Metal Shouldn’t be a Grind
Let Hivelocity take the busy work out of your daily server maintenance with our Managed Services plans. Choose from 1 of 6 different managed service offerings. Standard and Premium plans available.

Questions about something specific? Chat now with one of our expert account managers and learn which plan is right for you and your customers!

With Managed Server Technicians on-site 24/7/365, your server is always in good hands.

Tags +
Tags
...
...

How do I configure Virtual Host entry (Zone) for a domain?

Apache Configuration
————————–

Once you have the DNS pointing to your virtual domain server, you need to tell your Web server where to find the Web files for the domain. The way Apache works, if you have set up virtual domains, the first domain entered is the default. This is the directory that will be displayed when a virtual domain is not listed in the configuration. (In other words, if the DNS entry made above sends the URL to your IP, but you don’t have the virtual host in your httpd.conf file.)

You must edit your Apache httpd.conf file:

Go to the section of the httpd.conf file on Virtual hosting (/etc/httpd/conf/httpd.conf). Make sure that the NameVirtualHost points to your IP:NameVirtualHost 10.1.1.1
The first virtual host entry should be your default domain:

ServerName www.defaultdomain.com
DocumentRoot /www/domain

Then list the new domain, with any options you’d like to add:

ServerName www.testdomain.com
DocumentRoot /home/testdomain/public_html/
ErrorLog logs/testdomain.com-error_log
TransferLog logs/testdomain.com-access_log

Note, I added two lines to the second virtual host. These allow you to separate out the Error and Transfer logs for the new domain from your default domain. If you are going to host virtual domains for other people, they will almost certainly want their server logs, and this makes it easy to provide that to them as well.

Share

Facebook
Twitter
LinkedIn
Email
WhatsApp

Need More Personalized Help?

If you have any further issues, questions, or would like some assistance checking on this or anything else, please reach out to us from your my.hivelocity.net account and provide your server credentials within the encrypted field for the best possible security and support.

If you are unable to reach your my.hivelocity.net account or if you are on the go, please reach out from your valid my.hivelocity.net account email to us here at: support@hivelocity.net. We are also available to you through our phone and live chat system 24/7/365.