serveradmin
asked on
i want to host more then 1 site on local centos mach.
i want to host more then 1 site on virtual. on my system with operating system centos 5. apache was installed with the installation of the centos. so all the files are on default location.
how can i host test1.abc.com and test2.abc.com on a same vps so that i can test this site.
how can i host test1.abc.com and test2.abc.com on a same vps so that i can test this site.
ASKER
i am getting error when i restart the httpd after doing the configuration u told
starting httpd: [Fri May 01 09:54:54 2009] [Warn] _default_ VirtualHost overlap on port 80, the first as precedence
[Fri May 01 09:54:54 2009] [Warn] _default_ VirtualHost overlap on port 80, the first as precedence
but all the domains are openng to the default apache page rather then the index page i placed in the folder location.
starting httpd: [Fri May 01 09:54:54 2009] [Warn] _default_ VirtualHost overlap on port 80, the first as precedence
[Fri May 01 09:54:54 2009] [Warn] _default_ VirtualHost overlap on port 80, the first as precedence
but all the domains are openng to the default apache page rather then the index page i placed in the folder location.
they are warnings but it is a bit annoying...
can you post you complete config here?
can you post you complete config here?
ASKER
in my /etc/hosts file i place following code
101.168.1.25 www.solutionsbeyond.local
101.168.1.25 forum.solutionsbeyond.loca l
101.168.1.25 forum2.solutionsbeyond.loc al
and in /etc/httpd/conf/httpd.conf
<VirtualHost *:80>
ServerAdmin admin@solutionsbeyond.loca l
DocumentRoot /home/httpd/sb
ServerName www.solutionsbeyond.local
</VirtualHost>
<VirtualHost *:80>
ServerAdmin admin@solutionsbeyond.loca l
DocumentRoot /home/httpd/test
ServerName forum2.solutionsbeyond.loc al
</VirtualHost>
<VirtualHost *:80>
ServerAdmin admin@solutionsbeyond.loca l
DocumentRoot /home/httpd/phpbb
ServerName forum.solutionsbeyond.loca l
</VirtualHost>
rest is default as it was
101.168.1.25 www.solutionsbeyond.local
101.168.1.25 forum.solutionsbeyond.loca
101.168.1.25 forum2.solutionsbeyond.loc
and in /etc/httpd/conf/httpd.conf
<VirtualHost *:80>
ServerAdmin admin@solutionsbeyond.loca
DocumentRoot /home/httpd/sb
ServerName www.solutionsbeyond.local
</VirtualHost>
<VirtualHost *:80>
ServerAdmin admin@solutionsbeyond.loca
DocumentRoot /home/httpd/test
ServerName forum2.solutionsbeyond.loc
</VirtualHost>
<VirtualHost *:80>
ServerAdmin admin@solutionsbeyond.loca
DocumentRoot /home/httpd/phpbb
ServerName forum.solutionsbeyond.loca
</VirtualHost>
rest is default as it was
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Open in new window