The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Making a site appear on an IP

Discussion in 'General Discussion' started by thealee, Jun 18, 2007.

  1. thealee

    thealee Member

    Oct 5, 2006
    Likes Received:
    Trophy Points:
    Hi there,

    I've done this before, just wanted to check how its properly done.

    Basically, a reseller has their own IP that he uses for his websites, he wants his website to appear when you goto to the IP as well.

    So goes to, and is on

    I hope I was clear. If I'm correct I believe this is something to do with the virtual hosts section of httpd.conf.

    Thanks for reading.
  2. sparek-3

    sparek-3 Well-Known Member

    Aug 10, 2002
    Likes Received:
    Trophy Points:
    cPanel Access Level:
    Root Administrator
    In the httpd.conf file you will see a lot of VirtualHost containers. Find the one that refers to the reseller account, it will begin with:


    Now cut and paste this entire VirtualHost container so that it is the first VirtualHost listed that uses the IP. Remove the duplicate VirtualHost container for the reseller account if necessary.

    Whatever VirtualHost container is listed first in the httpd.conf file for a given IP, that is the website that will be displayed when going directly to the IP.

    Be sure you make a backup copy of your httpd.conf file prior to making changes:

    cp /etc/httpd/conf/httpd.conf /etc/httpd/conf/httpd.conf.thisoldone

Share This Page