How to maintain an up-to-date mirror site in Zope? (not-so-newbie question!) question!)
Here is the situation, can you offer advice? Machine A is running a Zope server for a wide-area network in Company A. This is an Intranet site which changes regularly. Machine B serves a separate wide-area network in Company B, and Company B employees need access to Company A's intranet. The link between Machine A and Machine B is too slow/low-bandwidth for all of company B's employees to access A's intranet directly. Therefore we want to have a Zope server on Machine B with a mirror copy of the Company A intranet. The problem is, how can we keep this mirror copy updated on a daily basis? Ideally we need an automatic process to run each night and update the mirror on B. The ideas I had were : 1) stop B's Zope server, copy across data.fs and restart B. But can this be done automatically? 2) somehow keep a log of changes made in A, and at the end of day, export the changed files, import them on B, overwriting the originals. Can this be done in Zope code? Can this be automated? Does anyone have any thoughts/opinions on these ideas? Or does anyone know of a better way, perhaps an existing Zope package or solution? Thanks again, Alex ================================== Alex Bowyer IT Contractor, Logica Australasia Tel : +61 2 9202 8130 Fax : +61 2 9922 7466 E-mail : bowyera@logica.com WWW : http://www.logica.com.au/ ==================================
Have a look at the excellent Client_Server product. It allows you to export chunks of objects from one to another. http://www.zope.org/Members/MacGregor/Client_Server Then: - write a script that each evening - gets a list of every object in the data.fs and its bobobase_modification_time - runs export on each of those objects from A - B. -- Andy McKay, Developer. ActiveState. ----- Original Message ----- From: "Bowyer, Alex" <BowyerA@logica.com> To: <zope@zope.org> Sent: Monday, November 13, 2000 4:00 PM Subject: [Zope] How to maintain an up-to-date mirror site in Zope? (not-so-newbie question!) question!)
Here is the situation, can you offer advice?
Machine A is running a Zope server for a wide-area network in Company A. This is an Intranet site which changes regularly. Machine B serves a separate wide-area network in Company B, and Company B employees need access to Company A's intranet. The link between Machine A and Machine B is too slow/low-bandwidth for all of company B's employees to access A's intranet directly. Therefore we want to have a Zope server on Machine B with a mirror copy of the Company A intranet. The problem is, how can we keep this mirror copy updated on a daily basis?
Ideally we need an automatic process to run each night and update the mirror on B.
The ideas I had were :
1) stop B's Zope server, copy across data.fs and restart B. But can this be done automatically?
2) somehow keep a log of changes made in A, and at the end of day, export the changed files, import them on B, overwriting the originals. Can this be done in Zope code? Can this be automated?
Does anyone have any thoughts/opinions on these ideas? Or does anyone know of a better way, perhaps an existing Zope package or solution?
Thanks again,
Alex
================================== Alex Bowyer IT Contractor, Logica Australasia Tel : +61 2 9202 8130 Fax : +61 2 9922 7466 E-mail : bowyera@logica.com WWW : http://www.logica.com.au/ ==================================
_______________________________________________ Zope maillist - Zope@zope.org http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
Hi Alex, If the changes that are made are always 'one-way' you could rsync Data.fs, or you could 'export' certain folders that could then be 'imported' at the mirror site. These could both be automated pretty easily. As you noted, if you take the rsync route you'll need to shut down and restart Zope. If you do the export/import you can leave Zope running (though you may want to pack the DB afterwards.) Another nice feature of export/import is that you can have some parts of the site that are managed at company B and other parts managed by company A. An even better approach might be some kind of ZEO solution.. but I don't know anything about ZEO other than the name. ;-) -steve
"Bowyer," == Bowyer, Alex <BowyerA@logica.com> writes:
Bowyer,> Here is the situation, can you offer advice? Bowyer,> Machine A is running a Zope server for a wide-area Bowyer,> network in Company A. This is an Intranet site which Bowyer,> changes regularly. Machine B serves a separate wide-area Bowyer,> network in Company B, and Company B employees need access Bowyer,> to Company A's intranet. The link between Machine A and Bowyer,> Machine B is too slow/low-bandwidth for all of company Bowyer,> B's employees to access A's intranet directly. Therefore Bowyer,> we want to have a Zope server on Machine B with a mirror Bowyer,> copy of the Company A intranet. The problem is, how can Bowyer,> we keep this mirror copy updated on a daily basis? Bowyer,> Ideally we need an automatic process to run each night Bowyer,> and update the mirror on B. Bowyer,> The ideas I had were : Bowyer,> 1) stop B's Zope server, copy across data.fs and restart Bowyer,> B. But can this be done automatically? Bowyer,> 2) somehow keep a log of changes made in A, and at the Bowyer,> end of day, export the changed files, import them on B, Bowyer,> overwriting the originals. Can this be done in Zope code? Bowyer,> Can this be automated? Bowyer,> Does anyone have any thoughts/opinions on these ideas? Or Bowyer,> does anyone know of a better way, perhaps an existing Bowyer,> Zope package or solution? Bowyer,> Thanks again, Bowyer,> Alex Bowyer,> ================================== Alex Bowyer IT Bowyer,> Contractor, Logica Australasia Tel : +61 2 9202 8130 Fax Bowyer,> : +61 2 9922 7466 E-mail : bowyera@logica.com WWW : Bowyer,> http://www.logica.com.au/ Bowyer,> ================================== Bowyer,> _______________________________________________ Zope Bowyer,> maillist - Zope@zope.org Bowyer,> http://lists.zope.org/mailman/listinfo/zope ** No cross Bowyer,> posts or HTML encoding! ** (Related lists - Bowyer,> http://lists.zope.org/mailman/listinfo/zope-announce Bowyer,> http://lists.zope.org/mailman/listinfo/zope-dev ) <
Thats another more efficient option, and if you are on Unix you only have stop the Zope you are syncing to. -- Andy McKay, Developer. ActiveState. ----- Original Message ----- From: "Steve Spicklemire" <steve@spvi.com> To: <BowyerA@logica.com> Cc: <zope@zope.org>; <steve@spvi.com> Sent: Monday, November 13, 2000 4:48 PM Subject: Re: [Zope] How to maintain an up-to-date mirror site in Zope? (not-so-newbie question!) question!)
Hi Alex,
If the changes that are made are always 'one-way' you could rsync Data.fs, or you could 'export' certain folders that could then be 'imported' at the mirror site. These could both be automated pretty easily. As you noted, if you take the rsync route you'll need to shut down and restart Zope. If you do the export/import you can leave Zope running (though you may want to pack the DB afterwards.) Another nice feature of export/import is that you can have some parts of the site that are managed at company B and other parts managed by company A. An even better approach might be some kind of ZEO solution.. but I don't know anything about ZEO other than the name. ;-)
-steve
"Bowyer," == Bowyer, Alex <BowyerA@logica.com> writes:
Bowyer,> Here is the situation, can you offer advice?
Bowyer,> Machine A is running a Zope server for a wide-area Bowyer,> network in Company A. This is an Intranet site which Bowyer,> changes regularly. Machine B serves a separate wide-area Bowyer,> network in Company B, and Company B employees need access Bowyer,> to Company A's intranet. The link between Machine A and Bowyer,> Machine B is too slow/low-bandwidth for all of company Bowyer,> B's employees to access A's intranet directly. Therefore Bowyer,> we want to have a Zope server on Machine B with a mirror Bowyer,> copy of the Company A intranet. The problem is, how can Bowyer,> we keep this mirror copy updated on a daily basis?
Bowyer,> Ideally we need an automatic process to run each night Bowyer,> and update the mirror on B.
Bowyer,> The ideas I had were :
Bowyer,> 1) stop B's Zope server, copy across data.fs and restart Bowyer,> B. But can this be done automatically?
Bowyer,> 2) somehow keep a log of changes made in A, and at the Bowyer,> end of day, export the changed files, import them on B, Bowyer,> overwriting the originals. Can this be done in Zope code? Bowyer,> Can this be automated?
Bowyer,> Does anyone have any thoughts/opinions on these ideas? Or Bowyer,> does anyone know of a better way, perhaps an existing Bowyer,> Zope package or solution?
Bowyer,> Thanks again,
Bowyer,> Alex
Bowyer,> ================================== Alex Bowyer IT Bowyer,> Contractor, Logica Australasia Tel : +61 2 9202 8130 Fax Bowyer,> : +61 2 9922 7466 E-mail : bowyera@logica.com WWW : Bowyer,> http://www.logica.com.au/ Bowyer,> ==================================
Bowyer,> _______________________________________________ Zope Bowyer,> maillist - Zope@zope.org Bowyer,> http://lists.zope.org/mailman/listinfo/zope ** No cross Bowyer,> posts or HTML encoding! ** (Related lists - Bowyer,> http://lists.zope.org/mailman/listinfo/zope-announce Bowyer,> http://lists.zope.org/mailman/listinfo/zope-dev )
<
_______________________________________________ Zope maillist - Zope@zope.org http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
participants (3)
-
Andy McKay -
Bowyer, Alex -
Steve Spicklemire