[Home]

Summary:ASTERISK-00068: do_monitor logs strange warning spuriously
Reporter:jayson (jayson)Labels:
Date Opened:2003-08-08 15:46:43Date Closed:2008-01-15 14:31:57.000-0600
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Core/General
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:
Description:Asterisk will emit the following warning after being restarted (say, once or twice for each Zaptel channel for a minute) then intermittently (say, once every 15-30 minutes):

WARNING[11276]: File chan_zap.c, Line 4592 (do_monitor): Write failed: Resource temporarily unavailable



****** ADDITIONAL INFORMATION ******

Upon patching chan_zap to output which channel was generating this problem, it appears to reliably be the ones hooked into our Zhone zPlex channel bank.

Is there any reason the Zaptel kernel driver should be refusing writes?  It appears to be returning EAGAIN.

A quick grep for EAGAIN in the Zaptel driver source gives only one hit in zaptel.c at line 1427 showing that this gets returned when O_NONBLOCK has been requested but the spinlock isn't released.

zt_open (in chan_zap.c) does appear to use O_NONBLOCK when opening the device.  My guess is that this is caused by contention over the device.  I don't know enough about Zaptel stuff to really tell if this is bad, can be easily fixed, or perhaps should cause the message to be suppressed.

Is this fixable?  Should it be fixed?
Comments:By: Mark Spencer (markster) 2003-08-14 15:14:26

It's actually just a curiosity more than any practical value and is tied to the message waiting indicator light.  I wrote the routine to (in principle) only write as much data as was read, but apparently i've missed that somehow.

By: Mark Spencer (markster) 2003-08-14 23:28:23

Fix in CVS, please confirm that rids us of the message.

By: jayson (jayson) 2003-08-15 11:13:18

CVS updated.  I had conflicts in a few files so I removed them and downloaded the virgin copies.

I still get errors as follows:

WARNING[11276]: File chan_zap.c, Line 4627 (do_monitor): Write failed: Resource temporarily unavailable
WARNING[11276]: File chan_zap.c, Line 4627 (do_monitor): Write failed: Resource temporarily unavailable
WARNING[11276]: File chan_zap.c, Line 4627 (do_monitor): Write failed: Resource temporarily unavailable
WARNING[11276]: File chan_zap.c, Line 4627 (do_monitor): Write failed: Resource temporarily unavailable

I hope that helps.

Let me know if there's anything you need from me.

Jayson

By: Mark Spencer (markster) 2003-08-15 13:28:41

Can you confirm that the FLUSH is a "FLUSH_BOTH"?  I can do a manual flush if it looks that way.  Just find me on IRC.

By: Mark Spencer (markster) 2003-08-15 17:25:21

Actually the fix in chan_zap was right, but zaptel didn't do the flushing right.  Might also explain some interesting artifacts we'd seen in some cases.

By: Digium Subversion (svnbot) 2008-01-15 14:31:57.000-0600

Repository: asterisk
Revision: 1338

U   trunk/apps/app_agi.c
U   trunk/apps/app_enumlookup.c
U   trunk/apps/app_festival.c
U   trunk/apps/app_queue.c
U   trunk/apps/app_voicemail2.c
U   trunk/channels/chan_sip.c
U   trunk/channels/chan_zap.c
U   trunk/codecs/ilbc/FrameClassify.c
U   trunk/codecs/ilbc/LPCdecode.c
U   trunk/codecs/ilbc/LPCencode.c
U   trunk/codecs/ilbc/StateConstructW.c
U   trunk/codecs/ilbc/StateSearchW.c
U   trunk/codecs/ilbc/anaFilter.c
U   trunk/codecs/ilbc/createCB.c
U   trunk/codecs/ilbc/doCPLC.c
U   trunk/codecs/ilbc/enhancer.c
U   trunk/codecs/ilbc/filter.c
U   trunk/codecs/ilbc/gainquant.c
U   trunk/codecs/ilbc/getCBvec.c
U   trunk/codecs/ilbc/helpfun.c
U   trunk/codecs/ilbc/hpInput.c
U   trunk/codecs/ilbc/hpOutput.c
U   trunk/codecs/ilbc/iCBConstruct.c
U   trunk/codecs/ilbc/iCBSearch.c
U   trunk/codecs/ilbc/iLBC_decode.c
U   trunk/codecs/ilbc/iLBC_encode.c
U   trunk/codecs/ilbc/lsf.c
U   trunk/codecs/ilbc/packing.c
U   trunk/codecs/ilbc/syntFilter.c
U   trunk/pbx/pbx_gtkconsole.c

------------------------------------------------------------------------
r1338 | markster | 2008-01-15 14:31:57 -0600 (Tue, 15 Jan 2008) | 8 lines

Asterisk:
ASTERISK-68 - Should eliminate probs on VMWI
ASTERISK-37 - Dynamic add survives reload
ASTERISK-69 - Make festival honor its arguments
ASTERISK-89 - Make events on FXO interfaces more logical
ASTERISK-22 - Prefer "bindaddr" to logical address for registrations
??? - Record crashes AGI

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

http://svn.digium.com/view/asterisk?view=rev&revision=1338