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.

Server move different OS

Discussion in 'General Discussion' started by bazzi, Mar 9, 2006.

  1. bazzi

    bazzi Well-Known Member

    May 23, 2004
    Likes Received:
    Trophy Points:

    I am planning to replace one server to another, but keep the new server on the same ip as the old server, so there there are no problems with domains that are pointing to other ip's.

    But there is a catch:
    I am planning to do the following:

    CentOS 3.5
    MySQL 4.0

    MySQL 4.1

    How can I do this with little or no downtime?
    I have searched but couldn't find anything what suits my exact problem.
  2. dave9000

    dave9000 Well-Known Member

    Apr 7, 2003
    Likes Received:
    Trophy Points:
    cPanel Access Level:
    Root Administrator
    Set the new server up on a seperate ip and get everything working, all customer files transfered over, mysql up and working right ( be sure to use the old-password line in the my.cnf)

    then unplug the server from the public network and do a main ip change either manually or take the old server offline and leave the new server online and use the ip migration tool in whm and you will have probably a hr or so downtime while your reconfiguring everything.

    This is a really basic plan on how to do this with as little downtime as possible

    another option however with no downtime is to upload all the customer files to the new server on the new ip get everything working and all dns entries set to the new ip on the new server and then modify your name servers with your registrar to the new ip and modify the dns records on the old server to the new ip and as the dns propigates the clients will automatically switch to using the new server and will not be able to tell the difference

    72 hrs after the change over take the old box offline and your done

    I'm sure others can add details to this but I have used the last method myself and its transparent to the end users/clients
  3. webignition

    webignition Well-Known Member

    Jan 22, 2005
    Likes Received:
    Trophy Points:
    I recently (yesterday) did the same type of thing, moving from a CentOS 3.6 box to a CentOS 4.2 box.

    In my case, I did the following (firsly getting cPanel installed and everything configured nicely):

    1. Stopped exim and chkservd
    service exim stop
    service chkservd stop
    Stopping exim should force sending MTAs to queue mail, ensuring that new mail doesn't turn up on the server mid-transfer. Stopping chkservd prevents it from restarting exim automagically.

    2. Copied accounts using WHM
    I opted for transferring some accounts using the multiple account transfer option and some individually. Be sure to go through a test transfer before you do it properly.

    I encountered some problems using the multiple account transfer option to move all accounts. It drives the load up a fair bit on both servers due to the moving/archiving/unarchiving of files and, when unachiving on the destination server, it doesn't wait for the load to go down between each account transfer and ended up alomst killing the destination server.

    3. Contacted the data centre and asked them to switch over the IP addresses of the two machines. This was the easy bit!

    4. Use the IP migration tool in WHM to change over all the IP-related settings on the destination server.

    5. Rejiggled the cPanel licences. Due to the IP switchover the licenses were still pointing to the correct IPs but, from the cPanel store account, appeared to be related to the wrong hostnames. This confused cPanel a bit and for a while it reckoned that it wasn't licensed correctly.

    6. Changed the hostnames.

    The only downtime that occurred was when the IP addresses were being switched over. The whole process took about ten minutes and during this time both sets of IPs intermittently timed out at the router, but this was to be expected.

    And that's it.

    You might also want to consider looking into rinetd - this is a tool that lets you forward traffic on a given port to a given IP. Using this method you can move relatively easily from one server to another without having to switch the IPs over and without any downtime, apparently.

Share This Page