Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Steve Smith 75 posts 158 karma points
    Jan 18, 2012 @ 11:20
    Steve Smith
    0

    Advice on replication

    Hi all,

    My company is working on a project to migrate our bespoke CMS to Umbraco.  The Umbraco installation will end up running the main website for our group of companies, plus the websites of our subsidiary companies - So its a fairly big deal if it breaks!

    We have two offices with a VPN connection running between them - which will give at least 10Mbit bandwidth. We plan to put a server at each office, and replicate between the two so that if site 1 is down for any reason, site 2 can take over.

    I've been looking at:

    • DFS replication for the file system (avoiding the files/folders that its recommended aren't replicated)
    • SQL Server 2008 R2 "Merge" replication for the database
    • Enabling distributed calls in the Umbraco config file

    I've set this up in a test environment (two virtual machines) and although replication seems to work, I've had some problems with the publishing of nodes (they appear OK in the Umbraco back office at both ends, but in the front end, some data is missing). 

    So I thought I'd come and ask if  I'm looking along the right lines, and to see whether anyone has successfuly done this before?  If so, could you offer any information/pointers that might help us?  Is there a better way to make sure that both the database and file system are replicated?

    We're also using uSiteBuilder if that makes any difference.

    Thanks in advance,

    Steve.

  • Rodion Novoselov 694 posts 859 karma points
    Jan 18, 2012 @ 11:30
    Rodion Novoselov
    0

    Hi. I think you'd better turn the "enable distributed call" option off. This option is for an envirounment where two or more copies of the site are connected to the same database (i.e web farm or web garden). If you perform full replication including the database you don't need it (I suspect in such a case it can bring inconsistency between the database, umbraco.config xml file and in-memory content cache).

  • Steve Smith 75 posts 158 karma points
    Jan 18, 2012 @ 15:27
    Steve Smith
    0

    Thanks for your reply.

    OK, I've turned off the distributed call function, and have done some more testing.  

    I published a new node on server-1, and then logged in to the Umbraco back-office on server-2.  After performing a "refresh nodes", the new node appears in the back-office content tree, but has no URL.  If I then choose "Republish entire site", the URL field is filled, and the front-end page works (I guess this function causes the memory/disk copy of the cache to be rebuilt from the database?).

    So not ideal but kind of working. 

    Is there a better way to do this?  

    Basically, we want a system where by if one of our offices is destroyed, the website(s) we host will still work at the second office, with minimal loss of data (hence replicating SQL, and the website file system).

    Alternatively, can you call the "republish entire site" function via say an ASP.NET page, which we could run say once every 15 minutes on server-2?  Or is there a better way to get Umbraco to rebuild its cache at set intervals? ... or is there a better way to handle the whole thing.  Open to suggestions basically!

    Cheers,

    Steve.

     

  • Rodion Novoselov 694 posts 859 karma points
    Jan 18, 2012 @ 15:57
    Rodion Novoselov
    0

    Actually umbraco's content is stored in several places: 1) the database, 2) xml content file on the disk (umbraco.config), 3) in-memory cache. To work properly all these places have to be in-sync but in some circumstances it can be broken. The "republish entire site" features is dedicated to completely recreate the umbraco.config file from the database and hence to reload in-memory cache from this file via observed cache dependency. And afaik the "enable distributed call" option coordinates updating only in-memory cache from the file on several servers. So, I think you should at least include the umbraco.config file in your replication so that to avoid having to republish the entire site after database replication (memory cache is going to be updated automatically on changing this file).

Please Sign in or register to post replies

Write your reply to:

Draft