Re: [ZODB-Dev] Re: KeyError / POSKeyError
Tim Tisdall wrote at 2007-3-29 16:03 -0400: > It took me all day, but I finally managed to figure out how to do >what you suggested. Unfortunately, I still get the very same error: >POSKeyError, Error Value: 0x01edf2 . Just to make sure I did it >right, 0x01edf2 is the OID I should use in your solution, right? Yes, but you need to pack it with "ZODB.utils.p64" to get an 8 byte binary string. -- Dieter ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
Tim Tisdall wrote at 2007-3-29 12:02 -0400: > Okay... I've managed to create a persistent object called 'p' with >the OID of the missing object. I have no idea how to determine the >database connection object to pass it to the >ZODB.Connection.Connection.add() . If you have a persistent object (like the root object), then "obj._p_jar" is this object's ZODB connection. -- Dieter ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
It took me all day, but I finally managed to figure out how to do what you suggested. Unfortunately, I still get the very same error: POSKeyError, Error Value: 0x01edf2 . Just to make sure I did it right, 0x01edf2 is the OID I should use in your solution, right? -Tim On 3/29/07, Tim Tisdall <[EMAIL PROTECTED]> wrote: Okay... I've managed to create a persistent object called 'p' with the OID of the missing object. I have no idea how to determine the database connection object to pass it to the ZODB.Connection.Connection.add() . -Tim On 3/27/07, Dieter Maurer <[EMAIL PROTECTED]> wrote: > Tim Tisdall wrote at 2007-3-27 14:59 -0400: > > When I try to access any part of the plone instance I'm given the > >same exceptions I mentioned before. I can't seem to access any > >subobjects. Am I doomed? > > You mean a "POSKeyError"? > > Then, you are not (yet) completely doomed. You can try the following: > > You create a persistent object, assign it the missing oid as > "_p_oid" (you can use the "ZODB.utils.p64" to convert an integer > to the required 8 byte binary representation) and > then you emulate a call to "ZODB.Connection.Connection.add" for > your object (of course without the "assert obj._p_oid is None" > and the "obj._p_pid = self._storage.new_oid()"). > Then you commit the transaction. > > This should create an object with the missing oid (of course, not > the correct one). If you are lucky, your object will be loadable > after this operation. > > > > -- > Dieter > ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
Okay... I've managed to create a persistent object called 'p' with the OID of the missing object. I have no idea how to determine the database connection object to pass it to the ZODB.Connection.Connection.add() . -Tim On 3/27/07, Dieter Maurer <[EMAIL PROTECTED]> wrote: Tim Tisdall wrote at 2007-3-27 14:59 -0400: > When I try to access any part of the plone instance I'm given the >same exceptions I mentioned before. I can't seem to access any >subobjects. Am I doomed? You mean a "POSKeyError"? Then, you are not (yet) completely doomed. You can try the following: You create a persistent object, assign it the missing oid as "_p_oid" (you can use the "ZODB.utils.p64" to convert an integer to the required 8 byte binary representation) and then you emulate a call to "ZODB.Connection.Connection.add" for your object (of course without the "assert obj._p_oid is None" and the "obj._p_pid = self._storage.new_oid()"). Then you commit the transaction. This should create an object with the missing oid (of course, not the correct one). If you are lucky, your object will be loadable after this operation. -- Dieter ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
Maybe I missed mentioning it, but if there was no fammed-old object then it would give a KeyError: 'fammed-old'. If I created a new plone instance in the spot where it was expecting, it would instead give me a POSKeyError. I really don't know anything about Python... how do I create a persistent object? -Tim On 3/27/07, Dieter Maurer <[EMAIL PROTECTED]> wrote: Tim Tisdall wrote at 2007-3-27 15:31 -0400: > That's what I've been using... the zopectl debug. It basically >says that there is a KeyError: 'fammed-old' when I try to access a >part of the object. The traceback seems to indicate that it's trying >to "connect" to that object but isn't able to. But, that should not result in a "KeyError" (but something different). Once, you have also spoken about a "POSKeyError". This "POSKeyError" may be more tractable. -- Dieter ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
Tim Tisdall wrote at 2007-3-27 15:31 -0400: > That's what I've been using... the zopectl debug. It basically >says that there is a KeyError: 'fammed-old' when I try to access a >part of the object. The traceback seems to indicate that it's trying >to "connect" to that object but isn't able to. But, that should not result in a "KeyError" (but something different). Once, you have also spoken about a "POSKeyError". This "POSKeyError" may be more tractable. -- Dieter ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
Tim Tisdall wrote at 2007-3-27 14:59 -0400: > When I try to access any part of the plone instance I'm given the >same exceptions I mentioned before. I can't seem to access any >subobjects. Am I doomed? You mean a "POSKeyError"? Then, you are not (yet) completely doomed. You can try the following: You create a persistent object, assign it the missing oid as "_p_oid" (you can use the "ZODB.utils.p64" to convert an integer to the required 8 byte binary representation) and then you emulate a call to "ZODB.Connection.Connection.add" for your object (of course without the "assert obj._p_oid is None" and the "obj._p_pid = self._storage.new_oid()"). Then you commit the transaction. This should create an object with the missing oid (of course, not the correct one). If you are lucky, your object will be loadable after this operation. -- Dieter ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
That's what I've been using... the zopectl debug. It basically says that there is a KeyError: 'fammed-old' when I try to access a part of the object. The traceback seems to indicate that it's trying to "connect" to that object but isn't able to. I can get a list via dir(obj), but that seems to be about it. -Tim On 3/27/07, Paul Winkler <[EMAIL PROTECTED]> wrote: On Tue, Mar 27, 2007 at 02:59:51PM -0400, Tim Tisdall wrote: > When I try to access any part of the plone instance I'm given the > same exceptions I mentioned before. I can't seem to access any > subobjects. Am I doomed? Are you getting these exceptions via the ZMI? You should also try exploring in zopectl debug. That might help you determine whether the plone instance itself is broken, or some vital sub-object. As long as you don't call transaction.commit() carelessly, this is safe. more here: http://docs.neuroinf.de/programming-plone/debug#1-6 -- Paul Winkler http://www.slinkp.com ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
On Tue, Mar 27, 2007 at 02:59:51PM -0400, Tim Tisdall wrote: > When I try to access any part of the plone instance I'm given the > same exceptions I mentioned before. I can't seem to access any > subobjects. Am I doomed? Are you getting these exceptions via the ZMI? You should also try exploring in zopectl debug. That might help you determine whether the plone instance itself is broken, or some vital sub-object. As long as you don't call transaction.commit() carelessly, this is safe. more here: http://docs.neuroinf.de/programming-plone/debug#1-6 -- Paul Winkler http://www.slinkp.com ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
When I try to access any part of the plone instance I'm given the same exceptions I mentioned before. I can't seem to access any subobjects. Am I doomed? -Tim On 3/27/07, Dieter Maurer <[EMAIL PROTECTED]> wrote: Tim Tisdall wrote at 2007-3-27 09:17 -0400: > The broken object is a 1gb plone instance. Which is what I'm trying >to recover. You may try to find the (non broken) persistent subobjects of the broken objects and relink them to a new object. Then you can delete the broken object. Whether you have a chance to succeed depends on how badly the content is destroyed. -- Dieter ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
Tim Tisdall wrote at 2007-3-27 09:17 -0400: > The broken object is a 1gb plone instance. Which is what I'm trying >to recover. You may try to find the (non broken) persistent subobjects of the broken objects and relink them to a new object. Then you can delete the broken object. Whether you have a chance to succeed depends on how badly the content is destroyed. -- Dieter ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
The broken object is a 1gb plone instance. Which is what I'm trying to recover. -Tim On 3/26/07, Dieter Maurer <[EMAIL PROTECTED]> wrote: Tim Tisdall wrote at 2007-3-23 20:08 -0400: > ... broken objects ... Another possibility would be to try to delete the broken object(s). There is a HowTo around (on "zopelabs", I think) on how to delete objects the inofficial way (in cases when the standard way is not workable, e.g. for broken objects). -- Dieter ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
Tim Tisdall wrote at 2007-3-23 20:08 -0400: > ... broken objects ... Another possibility would be to try to delete the broken object(s). There is a HowTo around (on "zopelabs", I think) on how to delete objects the inofficial way (in cases when the standard way is not workable, e.g. for broken objects). -- Dieter ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
--On 24. März 2007 12:39:32 -0400 Tim Tisdall <[EMAIL PROTECTED]> wrote: Where can I find a "fixed" version of fsrefs.py? I've been looking via Google but haven't found anything yet. If there is one then you'll find it on svn.zope.org. -aj pgpiocEhbJI6L.pgp Description: PGP signature ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
Where can I find a "fixed" version of fsrefs.py? I've been looking via Google but haven't found anything yet. -Tim On 3/23/07, Dieter Maurer <[EMAIL PROTECTED]> wrote: Tim Tisdall wrote at 2007-3-23 16:03 -0400: > When I run the fsrefs.py on the database I get the following: >- >oid 0x0L persistent.mapping.PersistentMapping >last updated: 2007-01-02 18:59:32.016077, tid=0x36AA393889A1800L >refers to invalid object: > oid ('\x00\x00\x00\x00\x00\x00\x00\x01', None) missing: '' > >oid 0x1L OFS.Application.Application >last updated: 2007-01-02 18:59:32.016077, tid=0x36AA393889A1800L >refers to invalid objects: > oid ('\x00\x00\x00\x00\x00\x00\x00\x06', None) missing: '' > oid ('\x00\x00\x00\x00\x00\x00\x00\x02', None) missing: '' > oid ('\x00\x00\x00\x00\x00\x00\x00\x02', None) missing: '' > oid ('\x00\x00\x00\x00\x00\x00\x00\x03', None) missing: '' Looks like a buggy "fsrefs": It complains that oid 0x0L refers to missing oid 0x1L and then it complains that oid 0x1L refers to other missind oids. Apparently, oid 0x1L is there. Otherwise, it would be difficult for it to refer to missing objects. Do not trust this "fsrefs" version. -- Dieter ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
Okay, I didn't think it'd work, but I tried using a backup. It didn't work. I only have backups of the ZODB with the plone instance I want to keep. Unfortunately, it and all the backups seem to be hung up on finding the broken plone instance in a completely different ZODB. I didn't bother making backups of the broken plone instance because... well, why recover something that's already broken. The relation is that the broken plone instance was as far as I could get with migrating a website from an old version of Plone and I was able to copy most of the contents over to a new instance of Plone. All I used was the "copy" and "paste" inside the ZMI. I don't understand why it's still looking for that broken version, but I have no idea how to alter the "good" site so it stops looking for that broken version that's no longer there (at least, not in the state that it wants it to be). -Tim On 3/23/07, Dieter Maurer <[EMAIL PROTECTED]> wrote: Tim Tisdall wrote at 2007-3-23 16:32 -0400: > I tried running a pack on the database via fsrecover.fs and here's >what I get: > >- >Recovering Data_fammedmain.fs into Data_fammedmain-recovery.fs >. 1 . 2 . 3 . 4 . 5 . 6 . 7 . 8 . 9 . 0 >0 bytes removed during recovery >Packing ... >Traceback (most recent call last): > ... >return referencesf(self._file.read(dh.plen)) > File "/opt/Plone-2.5.2/lib/python/ZODB/serialize.py", line 645, in referencesf >oid = oid_loaders[reference_type](*args) >KeyError: 'n' Looks like the physical structure of your storage is okay but some object data is corrupted. Try to restore the storage from a backup. -- Dieter ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
Tim Tisdall wrote at 2007-3-23 16:32 -0400: > I tried running a pack on the database via fsrecover.fs and here's >what I get: > >- >Recovering Data_fammedmain.fs into Data_fammedmain-recovery.fs >. 1 . 2 . 3 . 4 . 5 . 6 . 7 . 8 . 9 . 0 >0 bytes removed during recovery >Packing ... >Traceback (most recent call last): > ... >return referencesf(self._file.read(dh.plen)) > File "/opt/Plone-2.5.2/lib/python/ZODB/serialize.py", line 645, in > referencesf >oid = oid_loaders[reference_type](*args) >KeyError: 'n' Looks like the physical structure of your storage is okay but some object data is corrupted. Try to restore the storage from a backup. -- Dieter ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
Tim Tisdall wrote at 2007-3-23 16:03 -0400: > When I run the fsrefs.py on the database I get the following: >- >oid 0x0L persistent.mapping.PersistentMapping >last updated: 2007-01-02 18:59:32.016077, tid=0x36AA393889A1800L >refers to invalid object: > oid ('\x00\x00\x00\x00\x00\x00\x00\x01', None) missing: '' > >oid 0x1L OFS.Application.Application >last updated: 2007-01-02 18:59:32.016077, tid=0x36AA393889A1800L >refers to invalid objects: > oid ('\x00\x00\x00\x00\x00\x00\x00\x06', None) missing: '' > oid ('\x00\x00\x00\x00\x00\x00\x00\x02', None) missing: '' > oid ('\x00\x00\x00\x00\x00\x00\x00\x02', None) missing: '' > oid ('\x00\x00\x00\x00\x00\x00\x00\x03', None) missing: '' Looks like a buggy "fsrefs": It complains that oid 0x0L refers to missing oid 0x1L and then it complains that oid 0x1L refers to other missind oids. Apparently, oid 0x1L is there. Otherwise, it would be difficult for it to refer to missing objects. Do not trust this "fsrefs" version. -- Dieter ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev
Re: [ZODB-Dev] Re: KeyError / POSKeyError
I tried running a pack on the database via fsrecover.fs and here's what I get: - Recovering Data_fammedmain.fs into Data_fammedmain-recovery.fs . 1 . 2 . 3 . 4 . 5 . 6 . 7 . 8 . 9 . 0 0 bytes removed during recovery Packing ... Traceback (most recent call last): File "/opt/Plone-2.5.2/lib/python/ZODB/fsrecover.py", line 390, in ? main() File "/opt/Plone-2.5.2/lib/python/ZODB/fsrecover.py", line 259, in main recover(inp, outp, verbose, partial, force, pack) File "/opt/Plone-2.5.2/lib/python/ZODB/fsrecover.py", line 385, in recover ofs.pack(pack, referencesf) File "/opt/Plone-2.5.2/lib/python/ZODB/FileStorage/FileStorage.py", line 1348, in pack opos = p.pack() File "/opt/Plone-2.5.2/lib/python/ZODB/FileStorage/fspack.py", line 482, in pack self.gc.findReachable() File "/opt/Plone-2.5.2/lib/python/ZODB/FileStorage/fspack.py", line 228, in findReachable self.findReachableAtPacktime([z64]) File "/opt/Plone-2.5.2/lib/python/ZODB/FileStorage/fspack.py", line 304, in findReachableAtPacktime todo.extend(self.findrefs(pos)) File "/opt/Plone-2.5.2/lib/python/ZODB/FileStorage/fspack.py", line 377, in findrefs return referencesf(self._file.read(dh.plen)) File "/opt/Plone-2.5.2/lib/python/ZODB/serialize.py", line 645, in referencesf oid = oid_loaders[reference_type](*args) KeyError: 'n' On 3/23/07, Laurence Rowe <[EMAIL PROTECTED]> wrote: You need to provide the full traceback so we can tell where it is coming from. My guess (though I'm surprised by the particular error) is that you have perhaps got content owned by users in a user folder outside the site that is no longer accessible when you mount the database on its own. If that is the case then you need to write a script to fix up the __ac_local_roles__ on the affected objects. Laurence Tim Tisdall wrote: > Here's the thing... I get a KeyError if that ZODB is on it's own, > but if I create a fammed-old object that's similar to what it's > looking for, it will then throw a POSKeyError. > > The Plone instance was created fresh and then only the file > contents of the old site were copied over to the new instance. The > migration of the old Plone site didn't work, but it did manage to make > it so I could access the files contained within and copy them over. I > didn't copy over any stylings, products, users, widget things... I'm > pretty sure I just copied over AT types and a few basic zope files > (like DTML files and zope page templates). > > -Tim > > On 3/23/07, Christian Theune <[EMAIL PROTECTED]> wrote: >> Hi, >> >> Can you tell whether you get a KeyError or a POSKeyError? >> >> If you get a KeyError, it's likely that the app (Plone) is broken, e.g. >> during the migration you mentioned. >> >> A POSKeyError would (very likely) not talk about a a key like >> 'fammed-old', so I suspect you don't have a corruption in your >> storage/database but your application. >> >> Christian >> >> Am Freitag, den 23.03.2007, 12:04 -0400 schrieb Tim Tisdall: >> > I've got a 1gb ZODB that contains a single plone site and I'm not >> > able to access any part of it via the ZMI. It keeps saying that it's >> > looking for key "fammed-old" which is another plone site in another >> > ZODB file. Basically I managed to partly migrate a Plone 2.0 to Plone >> > 2.5 and then copied over the file contents from that instance into a >> > new Plone instance. I have no idea why the new one would be >> > referencing the old one, but it seemed to always throw this error if >> > the old database was unmounted. >> > I've tried several "cookbook" fixes I've found, but the problem is >> > that the plone instance itself is throwing the KeyError. Deleting the >> > whole plone instance is not going to help me much. Any suggestions? >> > I've also tried running the fsrecovery.py, but it simply makes a >> > complete duplicate of the file. fstest.py doesn't seem to find any >> > errors. fsrefs.py finds a series of errors, but I have no idea what >> > to do with that information. It seems that it's finding that it's >> > referencing "fammed-old" and that that doesn't exist. >> > >> > -Tim >> > ___ >> > For more information about ZODB, see the ZODB Wiki: >> > http://www.zope.org/Wikis/ZODB/ >> > >> > ZODB-Dev mailing list - ZODB-Dev@zope.org >> > http://mail.zope.org/mailman/listinfo/zodb-dev >> -- >> gocept gmbh & co. kg - forsterstraße 29 - 06112 halle/saale - germany >> www.gocept.com - [EMAIL PROTECTED] - phone +49 345 122 9889 7 - >> fax +49 345 122 9889 1 - zope and plone consulting and development >> >> > ___ > For more information about ZODB, see the ZODB Wiki: > http://www.zope.org/Wikis/ZODB/ > > ZODB-Dev mailing list - ZODB-Dev@zope.org > http://mail.zope.org/mailman/listinfo/zodb-dev > ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing
Re: [ZODB-Dev] Re: KeyError / POSKeyError
When I run the fsrefs.py on the database I get the following: - oid 0x0L persistent.mapping.PersistentMapping last updated: 2007-01-02 18:59:32.016077, tid=0x36AA393889A1800L refers to invalid object: oid ('\x00\x00\x00\x00\x00\x00\x00\x01', None) missing: '' oid 0x1L OFS.Application.Application last updated: 2007-01-02 18:59:32.016077, tid=0x36AA393889A1800L refers to invalid objects: oid ('\x00\x00\x00\x00\x00\x00\x00\x06', None) missing: '' oid ('\x00\x00\x00\x00\x00\x00\x00\x02', None) missing: '' oid ('\x00\x00\x00\x00\x00\x00\x00\x02', None) missing: '' oid ('\x00\x00\x00\x00\x00\x00\x00\x03', None) missing: '' oid 0x2L AccessControl.User.UserFolder last updated: 2007-01-02 18:59:32.016077, tid=0x36AA393889A1800L refers to invalid object: oid ('\x00\x00\x00\x00\x00\x00\x00\x05', None) missing: '' oid 0x3L App.ApplicationManager.ApplicationManager last updated: 2007-01-02 18:59:32.016077, tid=0x36AA393889A1800L refers to invalid object: oid ('\x00\x00\x00\x00\x00\x00\x00\x04', None) missing: '' oid 0x6L OFS.Folder.Folder last updated: 2007-01-02 19:05:58.342331, tid=0x36AA399F8ED6222L refers to invalid object: oid ('\x00\x00\x00\x00\x00\x00\x11\xbe', None) missing: '' Traceback (most recent call last): File "/opt/Plone-2.5.2/bin/fsrefs.py", line 157, in ? main(path) File "/opt/Plone-2.5.2/bin/fsrefs.py", line 130, in main refs = get_refs(data) File "/opt/Plone-2.5.2/lib/python/ZODB/serialize.py", line 687, in get_refs data = oid_klass_loaders[reference_type](*args) KeyError: 'n' - Here's a section of the event.log with the fammed-old KeyError: - 2007-03-22T20:57:44 ERROR ZODB.Connection Couldn't load state for 0x11be Traceback (most recent call last): File "/opt/Plone-2.5.2/lib/python/ZODB/Connection.py", line 732, in setstate self._setstate(obj) File "/opt/Plone-2.5.2/lib/python/ZODB/Connection.py", line 786, in _setstate self._reader.setGhostState(obj, p) File "/opt/Plone-2.5.2/lib/python/ZODB/serialize.py", line 604, in setGhostState state = self.getState(pickle) File "/opt/Plone-2.5.2/lib/python/ZODB/serialize.py", line 597, in getState return unpickler.load() File "/opt/Plone-2.5.2/lib/python/ZODB/serialize.py", line 479, in _persistent_load return self.loaders[reference_type](self, *args) File "/opt/Plone-2.5.2/lib/python/ZODB/serialize.py", line 540, in load_multi_oid conn = self._conn.get_connection(database_name) File "/opt/Plone-2.5.2/lib/python/ZODB/Connection.py", line 305, in get_connection new_con = self._db.databases[database_name].open( KeyError: 'fammed-old' -- On 3/23/07, Laurence Rowe <[EMAIL PROTECTED]> wrote: You need to provide the full traceback so we can tell where it is coming from. My guess (though I'm surprised by the particular error) is that you have perhaps got content owned by users in a user folder outside the site that is no longer accessible when you mount the database on its own. If that is the case then you need to write a script to fix up the __ac_local_roles__ on the affected objects. Laurence Tim Tisdall wrote: > Here's the thing... I get a KeyError if that ZODB is on it's own, > but if I create a fammed-old object that's similar to what it's > looking for, it will then throw a POSKeyError. > > The Plone instance was created fresh and then only the file > contents of the old site were copied over to the new instance. The > migration of the old Plone site didn't work, but it did manage to make > it so I could access the files contained within and copy them over. I > didn't copy over any stylings, products, users, widget things... I'm > pretty sure I just copied over AT types and a few basic zope files > (like DTML files and zope page templates). > > -Tim > > On 3/23/07, Christian Theune <[EMAIL PROTECTED]> wrote: >> Hi, >> >> Can you tell whether you get a KeyError or a POSKeyError? >> >> If you get a KeyError, it's likely that the app (Plone) is broken, e.g. >> during the migration you mentioned. >> >> A POSKeyError would (very likely) not talk about a a key like >> 'fammed-old', so I suspect you don't have a corruption in your >> storage/database but your application. >> >> Christian >> >> Am Freitag, den 23.03.2007, 12:04 -0400 schrieb Tim Tisdall: >> > I've got a 1gb ZODB that contains a single plone site and I'm not >> > able to access any part of it via the ZMI. It keeps saying that it's >> > looking for key "fammed-old" which is another plone site in another >> > ZODB file. Basically I managed to partly migrate a Plone 2.0 to Plone >> > 2.5 and then copied over the file contents from that instance into a >> > new Plone instance. I have no idea why the new one would be >> > referencing the old one, but it seemed to always throw this error if >> > the old database was unmounted. >> > I've tried several "cookbook" fixes I've found, but the problem is >> > that the plone instance itself is throwing the KeyError. Deleting the >> > whole plone ins
[ZODB-Dev] Re: KeyError / POSKeyError
You need to provide the full traceback so we can tell where it is coming from. My guess (though I'm surprised by the particular error) is that you have perhaps got content owned by users in a user folder outside the site that is no longer accessible when you mount the database on its own. If that is the case then you need to write a script to fix up the __ac_local_roles__ on the affected objects. Laurence Tim Tisdall wrote: Here's the thing... I get a KeyError if that ZODB is on it's own, but if I create a fammed-old object that's similar to what it's looking for, it will then throw a POSKeyError. The Plone instance was created fresh and then only the file contents of the old site were copied over to the new instance. The migration of the old Plone site didn't work, but it did manage to make it so I could access the files contained within and copy them over. I didn't copy over any stylings, products, users, widget things... I'm pretty sure I just copied over AT types and a few basic zope files (like DTML files and zope page templates). -Tim On 3/23/07, Christian Theune <[EMAIL PROTECTED]> wrote: Hi, Can you tell whether you get a KeyError or a POSKeyError? If you get a KeyError, it's likely that the app (Plone) is broken, e.g. during the migration you mentioned. A POSKeyError would (very likely) not talk about a a key like 'fammed-old', so I suspect you don't have a corruption in your storage/database but your application. Christian Am Freitag, den 23.03.2007, 12:04 -0400 schrieb Tim Tisdall: > I've got a 1gb ZODB that contains a single plone site and I'm not > able to access any part of it via the ZMI. It keeps saying that it's > looking for key "fammed-old" which is another plone site in another > ZODB file. Basically I managed to partly migrate a Plone 2.0 to Plone > 2.5 and then copied over the file contents from that instance into a > new Plone instance. I have no idea why the new one would be > referencing the old one, but it seemed to always throw this error if > the old database was unmounted. > I've tried several "cookbook" fixes I've found, but the problem is > that the plone instance itself is throwing the KeyError. Deleting the > whole plone instance is not going to help me much. Any suggestions? > I've also tried running the fsrecovery.py, but it simply makes a > complete duplicate of the file. fstest.py doesn't seem to find any > errors. fsrefs.py finds a series of errors, but I have no idea what > to do with that information. It seems that it's finding that it's > referencing "fammed-old" and that that doesn't exist. > > -Tim > ___ > For more information about ZODB, see the ZODB Wiki: > http://www.zope.org/Wikis/ZODB/ > > ZODB-Dev mailing list - ZODB-Dev@zope.org > http://mail.zope.org/mailman/listinfo/zodb-dev -- gocept gmbh & co. kg - forsterstraße 29 - 06112 halle/saale - germany www.gocept.com - [EMAIL PROTECTED] - phone +49 345 122 9889 7 - fax +49 345 122 9889 1 - zope and plone consulting and development ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev ___ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org http://mail.zope.org/mailman/listinfo/zodb-dev