zodb

What is the correct way to backup ZODB blobs?

扶醉桌前 提交于 2019-12-10 03:58:04
问题 I am using plone.app.blob to store large ZODB objects in a blobstorage directory. This reduces size pressure on Data.fs but I have not been able to find any advice on backing up this data. I am already backing up Data.fs by pointing a network backup tool at a directory of repozo backups. Should I simply point that tool at the blobstorage directory to backup my blobs? What if the database is being repacked or blobs are being added and deleted while the copy is taking place? Are there files in

Pyramid + ZODB Image storing

流过昼夜 提交于 2019-12-08 13:46:29
I have an upload form that accepts a zip file and has a method that unzips it and get each file from it. Make a unique id from the md5 hash of it and stores them in a dictionary; dict[uid] = imagebinary and returns it so that the form can store them into ZODB. I can't store the image just like that, as this error spits out; 2013-01-31 08:59:59,061 ERROR [waitress][Dummy-5] Exception when serving / Traceback (most recent call last): File "/home/maverick/inigo/sources/devenv/lib/python2.7/site-packages/waitress-0.8.2-py2.7.egg/waitress/channel.py", line 329, in service task.service() File "/home

Pyramid + ZODB Image storing

China☆狼群 提交于 2019-12-08 07:50:32
问题 I have an upload form that accepts a zip file and has a method that unzips it and get each file from it. Make a unique id from the md5 hash of it and stores them in a dictionary; dict[uid] = imagebinary and returns it so that the form can store them into ZODB. I can't store the image just like that, as this error spits out; 2013-01-31 08:59:59,061 ERROR [waitress][Dummy-5] Exception when serving / Traceback (most recent call last): File "/home/maverick/inigo/sources/devenv/lib/python2.7/site

Zope Conflict Errors

落爺英雄遲暮 提交于 2019-12-08 02:53:34
问题 My site's zope log reports a number of conflict errors. Average of 120 per day of which 2-3 are unresolved. I've come across many articles on why conflict errors occur but nothing has been clear. Most of these conflict errors occur on pages which run select queries on MySQL database. It is said that the number of conflict errors rise with an increase in concurrency of http requests because one ZODB object is created and the other tries to write to it. (I could not understand why and how ZODB

Where is the main space used up in Plone file upload?

懵懂的女人 提交于 2019-12-08 02:08:29
问题 In plone I have uploaded only 800 GB of data (mainly pdfs), it has occupied already 2 TB of hard disk space. Where exactly is the space being used up? I am using collective.documentviewer with its default settings. and plone 4.3. Are files stored by documentviewer changed to various image sizes ie Thumbnail, large image etc and stored in the blobstorage folder? 回答1: With collective.documentviewer, space is nearly doubled(or more) for every PDF. In order for collective.documentviewer to do

What is the suggested way to cron-automate ZODB packs for a production Plone instance?

微笑、不失礼 提交于 2019-12-06 17:14:25
问题 Looking at plone.org to find a way to periodically pack my instance's ZODB I could only find http://plone.org/documentation/faq/how-do-i-pack-the-zodb that doesn't talk about automated packs, but just manually initiated ones. I know I can simulate the manual pack with wget or curl, but I'd like to know if that is the best practice in use for production sites. 回答1: If you are using ZEO you can add the following to your Crontab to do this: 0 1 * * 6 <path-to-buildout>/bin/zeopack If you don't

Zope Conflict Errors

ぃ、小莉子 提交于 2019-12-06 11:55:14
My site's zope log reports a number of conflict errors. Average of 120 per day of which 2-3 are unresolved. I've come across many articles on why conflict errors occur but nothing has been clear. Most of these conflict errors occur on pages which run select queries on MySQL database. It is said that the number of conflict errors rise with an increase in concurrency of http requests because one ZODB object is created and the other tries to write to it. (I could not understand why and how ZODB objects are modified. Can anyone explain this ?) But even when there is only one user using it, there

ZODB not able to commit

我们两清 提交于 2019-12-06 11:54:57
问题 I am using ZODB first time. Just trying to commit the data with FileStorage. But when I do the same script second time I am not able to commit the new object. Here is my script from ZODB import FileStorage,DB import transaction storage = FileStorage.FileStorage('/tmp/test.fs') db = DB(storage) conn = db.open() root = conn.root() #root['layer']={} root['layer']['2b']={"id":'2b','name':'some name'} transaction.commit() conn.close() db.close() storage.close() when I repeat the code once again,

Where is the main space used up in Plone file upload?

折月煮酒 提交于 2019-12-06 05:54:34
In plone I have uploaded only 800 GB of data (mainly pdfs), it has occupied already 2 TB of hard disk space. Where exactly is the space being used up? I am using collective.documentviewer with its default settings. and plone 4.3. Are files stored by documentviewer changed to various image sizes ie Thumbnail, large image etc and stored in the blobstorage folder? With collective.documentviewer, space is nearly doubled(or more) for every PDF. In order for collective.documentviewer to do what it does, it converts each document into a series of images which are stored in addition to the original

“Unhandled exception in thread started by Error in sys.excepthook” during relstorage zodb pack

白昼怎懂夜的黑 提交于 2019-12-06 05:16:42
We have a reasonably large Plone instance running on its own mount point. The ZMI interface lists the size of the database as 7101.4M. We run a weekly pack of the database using the Relstorage zodbpack.py script, removing objects older than 7 days. The last two weeks the cron job that runs the pack has output the following: Sun Jun 26 07:00:38 BST 2011 packing cms mount /home/zope/home/parts/zope2/lib/python/zope/configuration/xmlconfig.py:323: DeprecationWarning: zope.app.annotation has moved to zope.annotation. Import of zope.app.annotation will become unsupported in Zope 3.5 __import__