Jaap Winius
2007-Dec-28 18:12 UTC
[asterisk-users] Problems with zaptel and HFC-S PCI card
Hi list, Now that I've got my Asterisk server to recognize my HFC-PCI card, I've run into some serious problems. The first thing I noticed was this message that would show up every five seconds on the CLI: Dec 27 15:46:42 WARNING[12484]: chan_zap.c:2512 pri_find_dchan: No D-channels available! Using Primary channel 3 as D-channel anyway! == Primary D-Channel on span 1 down Second, the syslog and the kern.log were quickly filling up with messages like these: Dec 27 16:52:53 bitis kernel: zaphfc: sync lost, cpu throtteling enabled. Dec 27 16:52:53 bitis kernel: zaphfc: sync lost, pci performance too low. you might have some cpu throtteling enabled. Dec 27 16:52:53 bitis last message repeated 31 times Dec 27 16:52:53 bitis kernel: zaphfc: bchan rx fifo not enough bytes to receive! (z1=4069, z2=4062, wanted 8 got 7), probably a buffer overrun. Asterisk doesn't even have to be running for this to happen, but it can be brought to a halt by unloading the zaphfc module. I'm not aware of any CPU throttling on this system (an AMD Athon running at 1100 MHz). The OS is Debian etch running Linux kernel 2.6.18 (-5-k7). I've installed asterisk and asterisk-bristuff 1.2.13~dfsg-2etch2, as well as zaptel and zaptel-source 1.2.11.dfsg-1 to compile the necessary modules. My current configuration is as follows: cat /proc/zaptel/* Span 1: ZTHFC1 "HFC-S PCI A ISDN card 0 [TE] layer 1 ACTIVATED (F7)" AMI/CCS 1 ZTHFC1/0/1 Clear (In use) 2 ZTHFC1/0/2 Clear (In use) 3 ZTHFC1/0/3 HDLCFCS (In use) I think TE mode is fine, since I only need it to connect an outside line. Internally, I plan (hope) to use only SIP phones. /etc/asterisk/zapata.conf : [trunkgroups] [channels] language=en context=isdn-in switchtype=euroisdn pridialplan=local prilocaldialplan=unknown nationalprefix = 0 internationalprefix = 00 overlapdial=yes signalling=bri_cpe_ptmp rxwink=300 usecallerid=yes hidecallerid=no callwaiting=yes usecallingpres=yes callwaitingcallerid=yes threewaycalling=yes transfer=yes canpark=yes cancallforward=yes callreturn=yes echocancel=yes echocancelwhenbridged=yes echotraining=yes rxgain=4.5 txgain=-3 group=1 callgroup=1 pickupgroup=1 immediate=yes #include zapata-channels.conf Incidentally, this needs to work in the Netherlands. /etc/asterisk/zapata-channels.conf switchtype = euroisdn signalling = bri_net channel => 1-2 To connect to an outside line, I think "signalling" may need to be set to something else, but I'm not sure. The genzaptelconf shell script I used to produce it is buggy, so for all I know these settings may be wrong or even incomplete. /etc/asterisk/modules.conf [modules] autoload=yes noload => pbx_gtkconsole.so noload => pbx_kdeconsole.so noload => app_intercom.so noload => chan_modem.so noload => chan_modem_aopen.so noload => chan_modem_bestdata.so noload => chan_modem_i4l.so noload => chan_capi.so load => res_musiconhold.so noload => chan_alsa.so [global] I've so far made no changes to extensions.conf to use the ISDN card. The linux modules zaptel, xpp and zaphfc get loaded automatically, but I haven't figured out yet from where. I'm thinking the zaphfc module may need to be loaded with a few (extra?) parameters before it starts behaving itself. Any help would be most welcome. Thanks! Jaap
Jaap Winius
2007-Dec-29 01:46 UTC
[asterisk-users] Problems with zaptel and HFC-S PCI card
Hi list, Just thought I'd let you know that the problems outlined in my previous post apparently had to do with a bad card. After swapping it out for another one the messages went away. Of course, I still have some problems. For instance, there's this error that keeps appearing in my syslog and kern.log: zaphfc: empty HDLC frame or bad CRC received Any idea how to get rid of it? Thanks, Jaap =============================================Quoting Jaap Winius <jwinius at umrk.to>:> Hi list, > > Now that I've got my Asterisk server to recognize my HFC-PCI card, I've run > into some serious problems. The first thing I noticed was this message > that would show up every five seconds on the CLI: > > Dec 27 15:46:42 WARNING[12484]: chan_zap.c:2512 pri_find_dchan: No > D-channels available! Using Primary channel 3 as D-channel anyway! > == Primary D-Channel on span 1 down > > Second, the syslog and the kern.log were quickly filling up with messages > like these: > > Dec 27 16:52:53 bitis kernel: zaphfc: sync lost, cpu throtteling enabled. > Dec 27 16:52:53 bitis kernel: zaphfc: sync lost, pci performance too > low. you might have some cpu throtteling enabled. > Dec 27 16:52:53 bitis last message repeated 31 times > Dec 27 16:52:53 bitis kernel: zaphfc: bchan rx fifo not enough bytes > to receive! (z1=4069, z2=4062, wanted 8 got 7), probably a buffer > overrun.
Tzafrir Cohen
2007-Dec-29 19:09 UTC
[asterisk-users] Problems with zaptel and HFC-S PCI card
On Sat, Dec 29, 2007 at 07:22:35PM +0100, Jaap Winius wrote:> Quoting Tzafrir Cohen <tzafrir.cohen at xorcom.com>: > > >> ... this error that keeps appearing in my syslog and kern.log: > >> > >> zaphfc: empty HDLC frame or bad CRC received > >> > > Try using the zaptel packages from: > > > > deb http://updates.xorcom.com/rapid etch main > > This upgraded Asterisk from v1.2 to v1.4.14 and the errors have disappeared.Actually I tend to believe that this is related to a newer version of the zaphfc driver. Or the fact that the florz patch is applied. -- Tzafrir Cohen icq#16849755 jabber:tzafrir.cohen at xorcom.com +972-50-7952406 mailto:tzafrir.cohen at xorcom.com http://www.xorcom.com iax:guest at local.xorcom.com/tzafrir