Plone ZODB Database records in the future
I have a problem with a plone-instance. On startup i get this CRITICAL Message
2011-03-25 10:23:06 CRITICAL ZODB.FileStorage /srv/plone/var/filestorage/Data.fs Database records 1258954454 seconds in the future
In the ZMI i can see that the plone - instance folder and everything in it has the date "2051-02-14 15:57" (it is the value of bobobase_modification_time). Every new object has the very same timestamp.
Due to that the packing of the ZODB doesn't make the Data.fs smaller and starting of the instance takes a long time right before the CRITICAL message above appears. Other than that, the site seems to work okay. Especially within Plone the time values seem to be correct.
I che开发者_开发问答cked to following (syntax-higlighted version of debug-session here: http://pastie.org/1709881):
>>> plone = app.plonesite
>>> plone.created() DateTime('2010/11/15 13:39:42.694 GMT+1') >>> plone.modified() DateTime('2010/11/15 13:39:42.694 GMT+1') >>> plone.bobobase_modification_time() DateTime('2051/02/14 15:57:21.077 GMT+1')# Try to set creation date according to
# http: //plone.org/documentation/kb/set-creation-date # setCreationDate doesn't work anymore>>> from DateTime import DateTime
>>> d = DateTime('2010/11/16') >>> plone.setModificationDate(d) >>> plone.setCreationDate(d) Traceback (most recent call last): File "", line 1, in ? AttributeError: setCreationDate >>> plone.setEffectiveDate(d) >>> plone.reindexObject()>>> plone.created()
DateTime('2010/11/15 13:39:42.694 GMT+1') >>> plone.modified() DateTime('2010/11/16') >>> plone.bobobase_modification_time() DateTime('2051/02/14 15:57:21.077 GMT+1')
What can I do about the wrong time of the bobobase_modification_time()? Can I set this value somhow to a reasonable time?
Update: Writing this post brought to me some new ideas what to search for. I think the thread http://thread.gmane.org/gmane.comp.web.zope.general/12994/focus=12999 describes what happend with my site. I will now try to fix it with exporting an then importing the object.
You ran Zope on a server with the clock way off into the future, and the ZODB really doesn't like that.
Someone once wrote a patch to auto-correct for this situation, see:
http://www.mail-archive.com/zodb-dev@zope.org/msg03916.html
YMMV applying that one though.
精彩评论