[ZODB-Dev] DisconnectedError

Jim Fulton jim at zope.com
Fri May 4 10:59:28 EDT 2007


On May 4, 2007, at 10:39 AM, José Pedro Ferreira wrote:

> Hello.
> I am experiencing a problem with ZODB-3.6.0 / Python 2.5, under Linux.
> Each time I initialize a database, i get a DisconnectedError  
> exception in the client, with the following traceback:
>
> <quote>
>
>  File "/home/pferreir/workspace/indico/code/code/MaKaC/common/ 
> db.py", line 50, in __init__
>    self._db=MaKaCDB(self._storage)
>
>  File "/usr/local/lib/python2.5/site-packages/ZODB/DB.py", line  
> 238, in __init__
>    storage.load(z64,'')
>
>  File "/usr/local/lib/python2.5/site-packages/ZEO/ 
> ClientStorage.py", line 746, in load
>    return self.loadEx(oid, version)[:2]
>
>  File "/usr/local/lib/python2.5/site-packages/ZEO/ 
> ClientStorage.py", line 769, in loadEx
>    data, tid, ver = self._server.loadEx(oid, version)
>
>  File "/usr/local/lib/python2.5/site-packages/ZEO/ServerStub.py",  
> line 192, in loadEx
>    return self.rpc.call("loadEx", oid, version)
>
>  File "/usr/local/lib/python2.5/site-packages/ZEO/zrpc/ 
> connection.py", line 531, in call
>    r_flags, r_args = self.wait(msgid)
>
>  File "/usr/local/lib/python2.5/site-packages/ZEO/zrpc/ 
> connection.py", line 621, in wait
>    raise DisconnectedError()
>
> DisconnectedError
>
> </quote>
>
> In the server side, I get:
>
> <quote>
>
> 2007-05-04T16:20:36 (11926) new connection ('127.0.0.1', 38126):  
> <ManagedServerConnection ('127.0.0.1', 38126)>
> 2007-05-04T16:20:36 (127.0.0.1:38126) received handshake 'Z303'
> 2007-05-04T16:20:36 (127.0.0.1:38126) loadEx() raised exception: 0x00
> Traceback (most recent call last):
>  File "/usr/local/lib/python2.5/site-packages/ZEO/zrpc/ 
> connection.py", line 421, in handle_request
>    ret = meth(*args)
>  File "/usr/local/lib/python2.5/site-packages/ZEO/ 
> StorageServer.py", line 248, in loadEx
>    return self.storage.loadEx(oid, version)
>  File "/usr/local/lib/python2.5/site-packages/ZODB/FileStorage/ 
> FileStorage.py", line 523, in loadEx
>    pos = self._lookup_pos(oid)
>  File "/usr/local/lib/python2.5/site-packages/ZODB/FileStorage/ 
> FileStorage.py", line 514, in _lookup_pos
>    raise POSKeyError(oid)
> POSKeyError: 0x00
> 2007-05-04T16:20:36 (11926/127.0.0.1:38126) disconnected
> 2007-05-04T16:20:36 (11926) new connection ('127.0.0.1', 38127):  
> <ManagedServerConnection ('127.0.0.1', 38127)>
> 2007-05-04T16:20:36 (127.0.0.1:38127) received handshake 'Z303'
>
> </quote>
>
> What confuses me is that I though that a root object for the  
> database would be created by the client, and a DisconnectedError is  
> raised before that happens. What can be happening?

The root object is only created if it doesn't exist.  The database is  
trying to determine if it exists or not.

I don't know why the client is being disconnected.  As others have  
hinted, you should try this with Python 2.4 -- and please report back  
if that changes the outcome.

Jim

--
Jim Fulton			mailto:jim at zope.com		Python Powered!
CTO 				(540) 361-1714			http://www.python.org
Zope Corporation	http://www.zope.com		http://www.zope.org





More information about the ZODB-Dev mailing list