Hi, I have an unmanaged VPS with Centos 5 and SSH, I installed Apache 2 using yum. I have only one dedicated IP. Now I can access my web located at /var/www/html through its IP, eg 1.2.3.4 Now I wanna add 3 domain names to my server, like this domain1.com -> /var/www/domain1 domain2.com -> /var/www/domain2 domain3.com -> /var/www/domain3 In my domain control panel, I can edit name server, cname, a. The sreen looks like this (same with A): Add CNAME record for domain1.com [Cancel] 1. Enter a subdomain: [ ].domain1.com 2. Enter the CNAME: [ ] 3. Click to add. [Add] Code (markup): Please help me to set up domain names
Unless you really want to do all the work manually (no problem there, it's just a pain), you should check out Falko's excellent Perfect Server with CentOS 5.2 tutorial. You can follow the instructions to get your system ready set up a free hosting control panel like ISPConfig, which will let you do all the Apache, mail, SSH, and server configuration from your web browser in a nice GUI. Good luck .
Read up on VirtualHost entries. You can place them on the bottom of httpd.conf . Or, you can make sure of Webmin and Virtualmin - up to you.
I think this is not what you want to do.Try to see apache configuration file httpd.conf and learn how to add virtual hosts.Good luck.