[ZODB-Dev] [ zodb-Bugs-536416 ] ZEO log rotation traceback

noreply@sourceforge.net noreply@sourceforge.net
Thu, 28 Mar 2002 11:23:12 -0800


Bugs item #536416, was opened at 2002-03-28 19:07
You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=115628&aid=536416&group_id=15628

Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Jeremy Hylton (jhylton)
Assigned to: Nobody/Anonymous (nobody)
Summary: ZEO log rotation traceback

Initial Comment:
Sending SIGHUP to a ZEO server is supposed to rotate
the logs.  When AJ tried it, it failed and printed the
following tracebacks.  The process exited before
rotating the logs.

[zope@yetix ZEOStorage]$ error: uncaptured python
exception, closing channel <StorageServer listening
:9001 at 8194e24> (exceptions.TypeError:unpack
non-sequence
[/home/zope/opt/Python-2.1.2/lib/python2.1/asyncore.py|poll|92]
[/home/zope/opt/Python-2.1.2/lib/python2.1/asyncore.py|handle_read_event|380]
[/home/zope/opt/Python-2.1.2/lib/python2.1/site-packages/ZEO/StorageServer.py|handle_accept|117])
error: uncaptured python exception, closing channel
<select-trigger (pipe) at 81059cc>
(exceptions.OSError:[Errno 11] Resource temporarily
unavailable
[/home/zope/opt/Python-2.1.2/lib/python2.1/asyncore.py|poll|92]
[/home/zope/opt/Python-2.1.2/lib/python2.1/asyncore.py|handle_read_event|386]
[/home/zope/opt/Python-2.1.2/lib/python2.1/site-packages/ZEO/trigger.py|handle_read|95]
[/home/zope/opt/Python-2.1.2/lib/python2.1/asyncore.py|recv|338]
[/home/zope/opt/Python-2.1.2/lib/python2.1/asyncore.py|recv|520])
Exception exceptions.OSError: (9, 'Bad file
descriptor') in <method trigger.__del__ of trigger
instance at 0x81059cc> ignored



----------------------------------------------------------------------

Comment By: Chris McDonough (chrism)
Date: 2002-03-28 19:23

Message:
Logged In: YES 
user_id=32974

I saw this problem when writing logrotation code for Zope.  
It happens when the select call is interrupted (which 
raises an EWOULDBLOCK socket error).  The select trigger 
uses a pipe, which for some reason gets broken when a 
signal is caught.  I got around it by changing the Wakeup 
(you stupid bastard ;-) code that uses a select_trigger to 
use a new pipe if it detected its original pipe was 
broken.  See 
http://cvs.zope.org/~checkout~/Zope/ZServer/PubCore/ZEvent.p
y?rev=1.7.2.1&content-
type=text/plain&only_with_tag=chrism_logrotate_branch


----------------------------------------------------------------------

You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=115628&aid=536416&group_id=15628