Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Zope: DB

Unable to fix a POSKeyError

 

 

Zope db RSS feed   Index | Next | Previous | View Threaded


ben.lobo at hobointernet

May 18, 2007, 9:33 AM

Post #1 of 3 (1071 views)
Permalink
Unable to fix a POSKeyError

Hi,

I'm getting a POSKeyError when I try to access a particular file in a Plone
site within the ZMI (see error report at
http://hobointernet.com/POSKeyError.htm).

>From what I've found out so far this happens when the ZODB has become
corrupted somehow. I've tried clearing the catalogue and reindexing (in
Plone), packing the whole database and using fsrecover.py but none of these
things has solved the problem and I can't access or delete the offending
file.

Can anyone offer any advice on how to fix this?

I'm running Zope 2.7 on Windows 2000. The Plone version is 2.0.5.

Thanks

--
Ben Lobo
Application Developer
Adaptive Technologies Ltd.
+44 (0)1273 728128
http://www.adaptivetechnologies.com



_______________________________________________
Zope-DB mailing list
Zope-DB[at]zope.org
http://mail.zope.org/mailman/listinfo/zope-db


dieter at handshake

May 20, 2007, 12:10 PM

Post #2 of 3 (993 views)
Permalink
Re: Unable to fix a POSKeyError [In reply to]

Ben Lobo wrote at 2007-5-18 17:33 +0100:
> ...
>I'm getting a POSKeyError when I try to access a particular file in a Plone
>site within the ZMI (see error report at
>http://hobointernet.com/POSKeyError.htm).

You replace this file by a new object using an interative Python interpreter:

container._setOb(idOfBrokenObject, someNewObject)

After that, you can delete the broken object

container._delObject(idOfBrokenObject)

and commit.



--
Dieter
_______________________________________________
Zope-DB mailing list
Zope-DB[at]zope.org
http://mail.zope.org/mailman/listinfo/zope-db


ben.lobo at hobointernet

May 21, 2007, 5:09 AM

Post #3 of 3 (990 views)
Permalink
Re: Unable to fix a POSKeyError [In reply to]

"Dieter Maurer" <dieter[at]handshake.de> wrote in message
news:18000.40200.346809.267362[at]gargle.gargle.HOWL...
> Ben Lobo wrote at 2007-5-18 17:33 +0100:
> > ...
> >I'm getting a POSKeyError when I try to access a particular file in a
Plone
> >site within the ZMI (see error report at
> >http://hobointernet.com/POSKeyError.htm).
>
> You replace this file by a new object using an interative Python
interpreter:
>
> container._setOb(idOfBrokenObject, someNewObject)
>
> After that, you can delete the broken object
>
> container._delObject(idOfBrokenObject)
>
> and commit.
>
> --
> Dieter

Thanks Dieter.

I wasn't too sure how to go about doing this as I'm running Plone on Windows
so I don't think zopectl works (which I believe is what would normally be
used in this situation on linux). So for anyone else with the same problem
in the future, I downloaded PloneShell -
http://plone.org/products/ploneshell - and then used Dieter's suggestions
above and then committed the changes with:

get_transaction().commit()

Cheers

Ben



_______________________________________________
Zope-DB mailing list
Zope-DB[at]zope.org
http://mail.zope.org/mailman/listinfo/zope-db

Zope db RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.