ISPConfig multi-server: how to move a website?

Discussion in 'General' started by Rashef, Nov 8, 2012.

  1. Rashef

    Rashef New Member

    Hi all!
    I just added a secondary (not a mirror) server to my ISPConfig3.
    I cannot find any suggestion about how to move a website from the main server to the secondary one (same client, same everything, only different server). I cannot create another entry for the same website (of course I get an error).

    Any hint?

    Many thanks!
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    There is no function to move sites between servers available yet. The procedure to move a website is:

    1) Make a backup of the site content (and databases if you want to move them as well).
    2) Delete the site on the old server.
    3) Create the site again on the new server.
    4) restore the site contents.
     
  3. local.host

    local.host New Member

    We recently had to move websites as well but couldn't afford the downtime. We acheived this by doing the following:

    1) setup another ispconfig server as a "migration" server. This ispconfig server WAS NOT part of the mutliserver configuration.
    2) setup a duplicate of the website and copied the website files to the migration server
    3) DNS change to host the website temporarially on the migration server
    4) delete the website on the original multiserver setup
    5) re-created it on the desired final server in the multiserver setup
    6) DNS change to host the website in it's final location
    7) remove the website from the migration server

    By using DNS in this way we were able to move the server around without any downtime to our site visitors. It's a little extra work, but in the end worth having the site up 100%
     
  4. maverickws

    maverickws New Member

    Hi Till when u say "yet" ... is there a way now? I was having this exact same issue and looking for an answer until I stumbled here.

    If there is where can I get to know it, and if not where can I file feature requests?
    This would be a good one. And also a request for ISPConfig to be compliant with nsupdate & RFC 2136... that would be super.
    I was thinking of rsync'ing the folders from a server to the other (the DB's are independent is just the web content I wanna move) just create appropriate permissions for sql users for the new server then editing the db entry on which server the website is.

    Do you think that could work?
     
  5. nhybgtvfr

    nhybgtvfr Well-Known Member HowtoForge Supporter

    reduce the TTL on the A records for the domain (best if no more than 10 minutes max) , ideally give that 24 hours or more to propagate.

    update the server_id from the old server to the new server for the domain (and any alias / sub domains ) in the web_domain table of the master ispconfig database.
    also the web_database table if moving the database as well, and the ftp_user and ssh_user tables is any such users already exist for the site.
    you can find all the server_id's in the server table.

    resync the services on the new server. it'll create the new web folders, ftp/ssh users and database.
    make sure no-one will make any more changes to the site until you tell them it's ok.
    copy the website files over from the old server to the new server.
    copy the database over from the old server to the new server.
    change the A records for the domain to point to the new server.
    (if it's an ecommerce site. stop the old site, put it in maintenance mode. just make sure no-one will access it. having two databases getting orders and going out of sync will be a nightmare to fix, do this before copying the site over and changing the dns)
    if's it's basically a read-only site, you can leave it accessible while the dns changes propagate.
    once you're confident no-one is being directed to the old server any more, and the site is working on the new server without problems, you can manually remove the site from the old server.
     
    Planea likes this.
  6. Jesse Norell

    Jesse Norell Well-Known Member Staff Member Howtoforge Staff

    There is ISPCopy, a part of the migration toolkit.

    https://git.ispconfig.org/ispconfig/ispconfig3/issues

    There is a discussion on this recently in I think the dev forum (possibly another); I don't think this is planned for the short term, there are some other scenarios for letsencrypt dns auth to address first, but feel free to file a feature request, I don't think there is one yet.
     

Share This Page