Multiple IP addresses on Apache2

cooxer

Junior Member
Joined
Jul 5, 2016
Messages
121
Reaction score
85
Hello. I store my website on VPS, Debian 6 distribution. And I have bought second IP address for my second website. IP is correctly parked and works, I tried to ping it. But I don't know how to configure apache2 to run 2 webs from 2 ip addresses. Does anyone has experience with this?
 
By default apache 2 listen on all interfaces (= all IP) so there is nothing to do on this side. You just have to configure a new website by adding a VirtualHost to apache(google "debian set up virtualhost"). After you just have to configure your DNS to make website1 point to IP1 and website2 point to IP2.
 
By default apache 2 listen on all interfaces (= all IP) so there is nothing to do on this side. You just have to configure a new website by adding a VirtualHost to apache(google "debian set up virtualhost"). After you just have to configure your DNS to make website1 point to IP1 and website2 point to IP2.
Yes, I already solved this. The problem was that I tried to load site content from var/www2 (my created folder) and it didn't worked that way. I created separate folder in /www and now it works.
 
Back
Top