Search code examples
webservermirroring

What are the advantages and disadvantages of site mirroring


Question 1:

When sites are mirrored, the content of their respective servers is synchronized (possibly automatically (live mirrors) or manually). Is this true? Are all servers 'equal', or does a main server exists? which then sends it changes to other 'children servers'? So all changes have to happen on the main server, and children servers are not allowed changes?

Question 2:

Expected advantages:

  • Global advantage: when a site that is originally hosted in the US is mirrored to a server in London, Europeans will benefit from this. They will have a better response time and because the amount of downloaders is cut down into two pieces (American and European servers) their download speeds can be higher.
  • Security: When one server crashes or is hacked, the other server can continue to operate normally.

Expected disadvantages:

  • If live mirroring is not used, some users will have to wait for renewed content.
  • More servers equals higher upkeep costs.

What other items can be added to these lists?


Solution

  • When sites are mirrored, the content of their respective servers is synchronized. Is this true?

    Yes, mirror sites should always be synchronized with their masters even if, for several reasons (eg. updates propagation times, network failures, etc.) they may not be.
    There are several ways to achieve this; for example, a simple method could be using a rsync command in a cron job; a better solution is the "push mirroring" technique, used by the Debian and Ubuntu Linux distributions.

    Are all servers 'equal', or does a main server exists, which then sends it changes to other 'children servers'?

    No, not all server are equals; generally the content provider updates one or more master servers which, in turn, provide the updated content to the other mirrors.
    For example, in the Fedora infrastructure there are master servers, tier-1 servers (fastest mirrors) and tier-2 servers.

    So all changes have to happen on the main server, and children servers are not allowed changes?

    Yes, in a mirrored context the content must be updated only on the master servers (one or more).

    Expected advantages

    Maybe the most comprehensive list of reasons for mirroring can be found on the Wikipedia:

    • To preserve a website or page, especially when it is closed or is about to be closed.
    • To allow faster downloads for users at a specific geographical location.
    • To counteract censorship and promote freedom of information.
    • To provide access to otherwise unavailable information.
    • To preserve historic content.
    • To balance load.
    • To counterbalance a sudden, temporary increase in traffic.
    • To increase a site's ranking in a search engine.
    • To serve as a method of circumventing firewalls.

    Expected disadvantages

    • Cost: you have to buy additional servers and spend time to operate them.
    • Inconsistency: when one or more mirrors are not synchronized with the master (and this could happen not only with manual sync, but also with live sync).

    As a further reference, since mirroring is a simple form of a Web Distributed System, you could also be interested in this reading.