Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

Change IP for certain add-on domain

Discussion in 'General Discussion' started by yoachan, Jul 17, 2013.

  1. yoachan

    yoachan Well-Known Member

    Joined:
    Jan 10, 2010
    Messages:
    65
    Likes Received:
    0
    Trophy Points:
    56
    Dear all,

    I have a machie that has two ips. Let's just call it 128.1.1.1 (default) and 128.1.1.2.
    For a reason I'd like to change ip for an/several add-on domain from 128.1.1.1 to 128.1.1.2, just some domains.
    My question is, how can I change my domain (let's just call it 'domain.com') to another ip in the same machine.

    If I can manually change the httpd.conf file, I'll be gladly edit it to add
    Code:
        Listen 128.1.1.2:80
    
    and change vhost for domain.com to
    Code:
        <VirtualHost 128.1.1.2:80>
    
    But using WHM/CPanel, I'm not sure.
    I had added "Listen 128.1.1.2:80" to to "Pre Main Include" in the "Include Editor" so that apache will also listen to 128.1.1.2.

    Now apache will also listen to 128.1.1.2. My problem is my domain will still only listen to 128.1.1.1 from the virtual host section. If only I can change <VirtualHost 128.1.1.1:80> to <VirtualHost 128.1.1.1:80> for my domain.com, I'll be done with it.

    Anyone has any solution(s)?
    Thanks in advanced. :)

    Regards,

    Yoachan
     
  2. quietFinn

    quietFinn Well-Known Member

    Joined:
    Feb 4, 2006
    Messages:
    998
    Likes Received:
    11
    Trophy Points:
    168
    Location:
    Finland
    cPanel Access Level:
    Root Administrator
    You change site's IP address in WHM-> Account Functions-> Change Site’s IP Address
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    43,617
    Likes Received:
    1,787
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. yoachan

    yoachan Well-Known Member

    Joined:
    Jan 10, 2010
    Messages:
    65
    Likes Received:
    0
    Trophy Points:
    56
    Yay! Thank you all!

    Thank you for your reply.

    To change a domain with an add-on domain(s), this function won't do for it will change ip for whole domains in an account.
    CMIIW
    But your solution is the fastest and easiest way to change site's ip in an account. It's a new knowledge for me.
    Thanks :)

    I followed your link, and yes it works.
    Thanks :)
     
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice